Module: Mesa Branch: master Commit: 077e3de98977ca0046d4f09eb7936f6006719739 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=077e3de98977ca0046d4f09eb7936f6006719739
Author: Brian Paul <[email protected]> Date: Mon Sep 21 08:32:43 2009 -0600 swrast: fix cube face selection If arx and ary are equal, we still want to choose from one of them, and not arz. This is the same as Michal's softpipe fix. --- src/mesa/swrast/s_texfilter.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mesa/swrast/s_texfilter.c b/src/mesa/swrast/s_texfilter.c index dd59314..ea749c0 100644 --- a/src/mesa/swrast/s_texfilter.c +++ b/src/mesa/swrast/s_texfilter.c @@ -1863,7 +1863,7 @@ choose_cube_face(const struct gl_texture_object *texObj, GLuint face; GLfloat sc, tc, ma; - if (arx > ary && arx > arz) { + if (arx >= ary && arx >= arz) { if (rx >= 0.0F) { face = FACE_POS_X; sc = -rz; @@ -1877,7 +1877,7 @@ choose_cube_face(const struct gl_texture_object *texObj, ma = arx; } } - else if (ary > arx && ary > arz) { + else if (ary >= arx && ary >= arz) { if (ry >= 0.0F) { face = FACE_POS_Y; sc = rx; _______________________________________________ mesa-commit mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/mesa-commit
