diff options
Diffstat (limited to 'src/mesa/swrast')
-rw-r--r-- | src/mesa/swrast/s_texfilter.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/swrast/s_texfilter.c b/src/mesa/swrast/s_texfilter.c index 478fb1557f6..997c2f4bb79 100644 --- a/src/mesa/swrast/s_texfilter.c +++ b/src/mesa/swrast/s_texfilter.c @@ -480,7 +480,7 @@ clamp_rect_coord_linear(GLenum wrapMode, GLfloat coord, GLint max, static INLINE GLint tex_array_slice(GLfloat coord, GLsizei size) { - GLint slice = IFLOOR(coord); + GLint slice = IFLOOR(coord + 0.5f); slice = CLAMP(slice, 0, size - 1); return slice; } |