Mesa (master): softpipe: Use SATURATE

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue May 26 22:57:28 UTC 2020


Module: Mesa
Branch: master
Commit: 7ea2ad0b3999a8e5d7334447af5d3c32537366fa
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=7ea2ad0b3999a8e5d7334447af5d3c32537366fa

Author: Alyssa Rosenzweig <alyssa.rosenzweig at collabora.com>
Date:   Tue May 19 11:11:25 2020 -0400

softpipe: Use SATURATE

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig at collabora.com>
Reviewed-by: Eric Engestrom <eric at engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5100>

---

 src/gallium/drivers/softpipe/sp_state_blend.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/softpipe/sp_state_blend.c b/src/gallium/drivers/softpipe/sp_state_blend.c
index 319bbccea2c..7351e09a5bb 100644
--- a/src/gallium/drivers/softpipe/sp_state_blend.c
+++ b/src/gallium/drivers/softpipe/sp_state_blend.c
@@ -79,7 +79,7 @@ softpipe_set_blend_color(struct pipe_context *pipe,
    /* save clamped color too */
    for (i = 0; i < 4; i++)
       softpipe->blend_color_clamped.color[i] =
-         CLAMP(blend_color->color[i], 0.0f, 1.0f);
+         SATURATE(blend_color->color[i]);
 
    softpipe->dirty |= SP_NEW_BLEND;
 }



More information about the mesa-commit mailing list