Mesa (master): st/bitmap: use GL_CLAMP_TO_EDGE for bitmap samplers

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Jan 26 22:14:18 UTC 2021


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

Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date:   Tue Jan 26 07:39:10 2021 -0500

st/bitmap: use GL_CLAMP_TO_EDGE for bitmap samplers

we aren't using border colors here, so this should be fine (and more compatible)

Reviewed-by: Erik Faye-Lund <erik.faye-lund at collabora.com>
Drive-by: Alyssa Rosenzweig <alyssa.rosenzweig at collabora.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Reviewed-by: Eric Anholt <eric at anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8714>

---

 src/mesa/state_tracker/st_cb_bitmap.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/mesa/state_tracker/st_cb_bitmap.c b/src/mesa/state_tracker/st_cb_bitmap.c
index 32fcd8a49df..63d8ac8dde2 100644
--- a/src/mesa/state_tracker/st_cb_bitmap.c
+++ b/src/mesa/state_tracker/st_cb_bitmap.c
@@ -559,9 +559,9 @@ init_bitmap_state(struct st_context *st)
 
    /* init sampler state once */
    memset(&st->bitmap.sampler, 0, sizeof(st->bitmap.sampler));
-   st->bitmap.sampler.wrap_s = PIPE_TEX_WRAP_CLAMP;
-   st->bitmap.sampler.wrap_t = PIPE_TEX_WRAP_CLAMP;
-   st->bitmap.sampler.wrap_r = PIPE_TEX_WRAP_CLAMP;
+   st->bitmap.sampler.wrap_s = PIPE_TEX_WRAP_CLAMP_TO_EDGE;
+   st->bitmap.sampler.wrap_t = PIPE_TEX_WRAP_CLAMP_TO_EDGE;
+   st->bitmap.sampler.wrap_r = PIPE_TEX_WRAP_CLAMP_TO_EDGE;
    st->bitmap.sampler.min_img_filter = PIPE_TEX_FILTER_NEAREST;
    st->bitmap.sampler.min_mip_filter = PIPE_TEX_MIPFILTER_NONE;
    st->bitmap.sampler.mag_img_filter = PIPE_TEX_FILTER_NEAREST;



More information about the mesa-commit mailing list