You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Section 10.3.11 of the OpenGL 4.6 spec defines "Indirect commands in Buffer Objects", or the GL_DRAW_INDIRECT_BUFFER/GL_DISPATCH_INDIRECT_BUFFER buffer targets. It refers readers to section 10.3.9 for general properties of the mechanism. Section 10.3.9 notes behavior is undefined if buffer object zero is bound to an enabled array at draw time, but it is not clear from the language in section 10.3.11 if this property is inherited by indirect buffers. Notably, section 10.3.10 duplicates the zero-object undefined behavior property while referring to section 10.3.9 for general behavior, while section 10.3.11 does not, perhaps implying it is well-defined and supported for indirect commands to use client memory for their indirect command memory. Further, no error case is defined for this situation in the DrawIndirect commands. The only clarifying point that indicates to the contrary is that the compatibility profile spec contains additional language:
"If zero is bound to DRAW_INDIRECT_BUFFER, the corresponding DrawIndirect commands instead source their arguments directly from the indirect pointer in client memory"
Which clearly defines the behavior only in the compatibility profile, implying it is intended to be undefined in the core profile.
To clarify this in the core profile spec, I think an explicit error case should be added to the DrawIndirect commands (probably in DrawArraysIndirect, so it will be inherited by all of them), and the "undefined behavior" language from section 10.3.9/10.3.10 should be duplicated into section 10.3.11 as well.
The text was updated successfully, but these errors were encountered:
Section 10.3.11 of the OpenGL 4.6 spec defines "Indirect commands in Buffer Objects", or the GL_DRAW_INDIRECT_BUFFER/GL_DISPATCH_INDIRECT_BUFFER buffer targets. It refers readers to section 10.3.9 for general properties of the mechanism. Section 10.3.9 notes behavior is undefined if buffer object zero is bound to an enabled array at draw time, but it is not clear from the language in section 10.3.11 if this property is inherited by indirect buffers. Notably, section 10.3.10 duplicates the zero-object undefined behavior property while referring to section 10.3.9 for general behavior, while section 10.3.11 does not, perhaps implying it is well-defined and supported for indirect commands to use client memory for their indirect command memory. Further, no error case is defined for this situation in the DrawIndirect commands. The only clarifying point that indicates to the contrary is that the compatibility profile spec contains additional language:
"If zero is bound to DRAW_INDIRECT_BUFFER, the corresponding DrawIndirect commands instead source their arguments directly from the indirect pointer in client memory"
Which clearly defines the behavior only in the compatibility profile, implying it is intended to be undefined in the core profile.
To clarify this in the core profile spec, I think an explicit error case should be added to the DrawIndirect commands (probably in DrawArraysIndirect, so it will be inherited by all of them), and the "undefined behavior" language from section 10.3.9/10.3.10 should be duplicated into section 10.3.11 as well.
The text was updated successfully, but these errors were encountered: