[Mesa-dev] [PATCH 3/3] mesa: Update comments at Const.MaxVertexAttribStride.

Mathias.Froehlich at gmx.net Mathias.Froehlich at gmx.net
Sat Jun 2 06:51:38 UTC 2018


From: Mathias Fröhlich <mathias.froehlich at web.de>

Mention how this is supposed to work where the constant is declared.

Signed-off-by: Mathias Fröhlich <Mathias.Froehlich at web.de>
---
 src/mesa/main/mtypes.h | 19 ++++++++++++++++++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 482c42a4b2..4ecdf39c2b 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -3782,7 +3782,24 @@ struct gl_constants
    /** OpenGL version 3.2 */
    GLbitfield ProfileMask;   /**< Mask of CONTEXT_x_PROFILE_BIT */
 
-   /** OpenGL version 4.4 */
+   /** OpenGL version 4.4
+    *
+    * Maximum value supported for strides in vertex arrays.
+    *
+    * Note that the value is also used internally when building up VAOs
+    * for immediate mode draws.
+    *
+    * This must be at least 2048 according to the spec which is the default.
+    * Note that a value of 0 means for mesa not to check for this limit
+    * internally. This is used from virgl that may end up in the situation
+    * that OpenGL applications had any time before OpenGL 4.4. That is, there
+    * is no way to query the underlying OpenGL stack for this driver limit and
+    * applictions just assume that kind of small offsets are still ok.
+    * But still, mesa shall not return meaningful but may be wrong values
+    * when being asked for GL_MAX_VERTEX_ATTRIB_STRIDE.
+    *
+    * \sa _mesa_init_constants
+    */
    GLuint MaxVertexAttribStride;
 
    /** GL_EXT_transform_feedback */
-- 
2.17.1



More information about the mesa-dev mailing list