diff options
author | Eric Anholt <eric@anholt.net> | 2017-05-04 10:58:34 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2017-06-30 12:07:31 -0700 |
commit | 851cd414ef40e6bcadd4f78d40b1f05910ef629c (patch) | |
tree | 6e2ebaf93c2c45700014e756bcd19fe1735599ce | |
parent | d5d5450c92034b4a19ed12a092364ec64be96a36 (diff) |
util: Avoid asking GL to transpose the ortho_uniform matrix.
From the GLES2 spec:
If the transpose parameter to any of the UniformMatrix* commands
is not FALSE, an INVALID_VALUE error is generated, and no uniform
values are changed.
Fixes spurious failures in draw-vertices-half-float_gles2.
Reviewed-by: Brian Paul <brianp@vmware.com>
-rw-r--r-- | tests/util/piglit-util-gl.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/util/piglit-util-gl.c b/tests/util/piglit-util-gl.c index 5ff13fedc..5dc1bbc7d 100644 --- a/tests/util/piglit-util-gl.c +++ b/tests/util/piglit-util-gl.c @@ -603,12 +603,12 @@ piglit_gen_ortho_uniform(GLint location, double l, double r, double b, double t, double n, double f) { const GLfloat values[4][4] = { - { 2/(r-l), 0, 0, -(r+l)/(r-l) }, - { 0, 2/(t-b), 0, -(t+b)/(t-b) }, - { 0, 0, -2/(f-n), -(f+n)/(f-n) }, - { 0, 0, 0, 1 } + { 2/(r-l), 0, 0, 0 }, + { 0, 2/(t-b), 0, 0 }, + { 0, 0, -2/(f-n), 0 }, + { -(r+l)/(r-l), -(t+b)/(t-b), -(f+n)/(f-n), 1 } }; - glUniformMatrix4fv(location, 1, GL_TRUE, (const GLfloat *)values); + glUniformMatrix4fv(location, 1, GL_FALSE, (const GLfloat *)values); } |