From 3e7c62700eb925850ca8c9224b224024a63ea40e Mon Sep 17 00:00:00 2001 From: Alexey Knyazev <3479527+lexaknyazev@users.noreply.github.com> Date: Thu, 4 Nov 2021 23:19:29 +0400 Subject: [PATCH 1/2] Disallow point rendering with undefined point size --- specs/latest/1.0/index.html | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/specs/latest/1.0/index.html b/specs/latest/1.0/index.html index 9c77dd32c9..69a7f480f7 100644 --- a/specs/latest/1.0/index.html +++ b/specs/latest/1.0/index.html @@ -3286,6 +3286,8 @@

Writing to the drawing buffer If first is negative, an INVALID_VALUE error will be generated. If the CURRENT_PROGRAM is null, an INVALID_OPERATION error will be generated. + If the mode is POINTS and the current program does not set + gl_PointSize value, an INVALID_OPERATION error will be generated.
void drawElements(GLenum mode, GLsizei count, GLenum type, GLintptr offset) (OpenGL ES 2.0 §2.8, man page)
@@ -3297,6 +3299,8 @@

Writing to the drawing bufferWebGLBuffer must be bound to the ELEMENT_ARRAY_BUFFER binding point or an INVALID_OPERATION error will be generated.

If the CURRENT_PROGRAM is null, an INVALID_OPERATION error will be generated. + If the mode is POINTS and the current program does not set + gl_PointSize value, an INVALID_OPERATION error will be generated. WebGL performs additional error checking beyond that specified in OpenGL ES 2.0 during calls to drawArrays @@ -4455,6 +4459,17 @@

Wide point primitive clipping

+

Undefined Point Size

+

+ Draw calls with POINTS primitives are rejected when the bound program does not set + gl_PointSize. +

+
+

+ Point rendering with undefined point size is undefined in GLES and may be unsupported in other APIs. +

+
+

References

From 487352ef0de887c91bd0354d7c2c5375047e6070 Mon Sep 17 00:00:00 2001 From: Alexey Knyazev <3479527+lexaknyazev@users.noreply.github.com> Date: Thu, 2 Dec 2021 21:35:43 +0400 Subject: [PATCH 2/2] Address feedback --- specs/latest/1.0/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/specs/latest/1.0/index.html b/specs/latest/1.0/index.html index 69a7f480f7..d5e163ceab 100644 --- a/specs/latest/1.0/index.html +++ b/specs/latest/1.0/index.html @@ -3287,7 +3287,7 @@

Writing to the drawing bufferfirst is negative, an INVALID_VALUE error will be generated. If the CURRENT_PROGRAM is null, an INVALID_OPERATION error will be generated. If the mode is POINTS and the current program does not set - gl_PointSize value, an INVALID_OPERATION error will be generated. + gl_PointSize variable, an INVALID_OPERATION error will be generated.
void drawElements(GLenum mode, GLsizei count, GLenum type, GLintptr offset) (OpenGL ES 2.0 §2.8, man page)
@@ -3300,7 +3300,7 @@

Writing to the drawing bufferINVALID_OPERATION error will be generated.

If the CURRENT_PROGRAM is null, an INVALID_OPERATION error will be generated. If the mode is POINTS and the current program does not set - gl_PointSize value, an INVALID_OPERATION error will be generated. + gl_PointSize variable, an INVALID_OPERATION error will be generated. WebGL performs additional error checking beyond that specified in OpenGL ES 2.0 during calls to drawArrays