Skip to content

Commit

Permalink
Set gl_PointSize in primitive restart tests for GL_POINTS.
Browse files Browse the repository at this point in the history
Failing to set this was relying on currently-undefined behavior and
causing the tests to fail on Apple's M1.

Related to KhronosGroup#2818, KhronosGroup#2822 and KhronosGroup#3356.
  • Loading branch information
kenrussell committed Dec 4, 2021
1 parent 5fa0d8a commit ef45bda
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions sdk/tests/deqp/functional/gles3/es3fPrimitiveRestartTests.js
Original file line number Diff line number Diff line change
Expand Up @@ -334,10 +334,15 @@ var gluTextureUtil = framework.opengl.gluTextureUtil;
'\n' +
'void main()\n' +
' {\n' +
' gl_Position = a_position;\n' +
'}\n';
' gl_Position = a_position;\n';

if (this.m_primType == es3fPrimitiveRestartTests.PrimitiveType.PRIMITIVE_POINTS) {
vertShaderSource += ' gl_PointSize = 1.0;\n';
}

vertShaderSource += '}\n';

/** @type {string} */ var fragShaderSource =
/** @type {string} */ var fragShaderSource =
'#version 300 es\n' +
'layout(location = 0) out mediump vec4 o_color;\n' +
'\n' +
Expand Down

0 comments on commit ef45bda

Please sign in to comment.