On 06/23/2016 11:15 AM, Matt Turner wrote: > From: Colin McDonald <cjmmail10...@yahoo.co.uk> > > At the same time, replace opcode numbers with names in > __indirect_glVertexAttribPointer. > > Reviewed-by: Matt Turner <matts...@gmail.com> > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=61907 > --- > src/glx/indirect_vertex_array.c | 19 ++++++++++++++----- > 1 file changed, 14 insertions(+), 5 deletions(-) > > diff --git a/src/glx/indirect_vertex_array.c b/src/glx/indirect_vertex_array.c > index 2bf2ff1..01fab33 100644 > --- a/src/glx/indirect_vertex_array.c > +++ b/src/glx/indirect_vertex_array.c > @@ -1386,7 +1386,7 @@ __indirect_glTexCoordPointer(GLint size, GLenum type, > GLsizei stride, > X_GLrop_TexCoord4iv > }; > static const uint16_t float_ops[5] = { > - 0, X_GLrop_TexCoord1dv, X_GLrop_TexCoord2fv, X_GLrop_TexCoord3fv, > + 0, X_GLrop_TexCoord1fv, X_GLrop_TexCoord2fv, X_GLrop_TexCoord3fv,
Holy crap. That typo bug has existed since commit fdb07636f2e6324c5250cd5ee97778b7f5933bea Author: Ian Romanick <i...@us.ibm.com> Date: Tue Feb 22 22:36:31 2005 +0000 Added __glExtensionBiIsEnabled and __GLXcontext::gl_extension_bits. This enables libGL to query which extension are exported to applications. Refactored array-query functionality (from glGet*v) in src/glx/x11/single2.c. Massive re-write of indirect vertex array support. The most noticable effect is that glDrawElements now generates DrawArrays protocol. The side-effects (and the main reasons for the re-work) are that it is much easier to add support for new arrays (e.g., GL_VERTEX_ATTRIB_ARRAY, GL_WEIGHT_ARRAY_ARB, etc.) and it is much easier to add support for the new DrawArrays protocol (required to support ARB_vertex_buffer_object). These changes were primarilly tested with progs/demos/isosurf. Colin wins. This patch is Reviewed-by: Ian Romanick <ian.d.roman...@intel.com> I think this patch can get as much stable tagging as Emil will apply. :) > X_GLrop_TexCoord4fv > }; > static const uint16_t double_ops[5] = { > @@ -1403,7 +1403,7 @@ __indirect_glTexCoordPointer(GLint size, GLenum type, > GLsizei stride, > X_GLrop_MultiTexCoord3ivARB, X_GLrop_MultiTexCoord4ivARB > }; > static const uint16_t mfloat_ops[5] = { > - 0, X_GLrop_MultiTexCoord1dvARB, X_GLrop_MultiTexCoord2fvARB, > + 0, X_GLrop_MultiTexCoord1fvARB, X_GLrop_MultiTexCoord2fvARB, > X_GLrop_MultiTexCoord3fvARB, X_GLrop_MultiTexCoord4fvARB > }; > static const uint16_t mdouble_ops[5] = { > @@ -1587,9 +1587,18 @@ __indirect_glVertexAttribPointer(GLuint index, GLint > size, > GLenum type, GLboolean normalized, > GLsizei stride, const GLvoid * pointer) > { > - static const uint16_t short_ops[5] = { 0, 4189, 4190, 4191, 4192 }; > - static const uint16_t float_ops[5] = { 0, 4193, 4194, 4195, 4196 }; > - static const uint16_t double_ops[5] = { 0, 4197, 4198, 4199, 4200 }; > + static const uint16_t short_ops[5] = { > + 0, X_GLrop_VertexAttrib1svARB, X_GLrop_VertexAttrib2svARB, > + X_GLrop_VertexAttrib3svARB, X_GLrop_VertexAttrib4svARB > + }; > + static const uint16_t float_ops[5] = { > + 0, X_GLrop_VertexAttrib1fvARB, X_GLrop_VertexAttrib2fvARB, > + X_GLrop_VertexAttrib3fvARB, X_GLrop_VertexAttrib4fvARB > + }; > + static const uint16_t double_ops[5] = { > + 0, X_GLrop_VertexAttrib1dvARB, X_GLrop_VertexAttrib2dvARB, > + X_GLrop_VertexAttrib3dvARB, X_GLrop_VertexAttrib4dvARB > + }; > > uint16_t opcode; > struct glx_context *gc = __glXGetCurrentContext(); > _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev