diff options
author | Ian Romanick <[email protected]> | 2012-01-31 09:00:48 -0700 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2012-02-02 10:07:14 -0700 |
commit | e06b1c65bc576a9b239841cbe3a8a8c2d6a8d09f (patch) | |
tree | db89e329cf875a343adbb4b6e538874c80a93243 /src/mesa/main/arrayobj.c | |
parent | af1477b088448aeca762f515410c80054cb225b9 (diff) |
mesa: Set the gl_array_object::ARBsemantics flag at the right time
With 0963990 the flag was only set when Bind created the object. In
all cases where ::ARBsemantics could be true, this path never
happened. Instead, add a _Used flag to track whether a VAO has ever
been bound. On the first Bind, set the _Used flag, and set the
ARBsemantics flag to the correct value.
NOTE: This is a candidate for release branches.
Signed-off-by: Ian Romanick <[email protected]>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=45423
Diffstat (limited to 'src/mesa/main/arrayobj.c')
-rw-r--r-- | src/mesa/main/arrayobj.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/main/arrayobj.c b/src/mesa/main/arrayobj.c index d9ae187bbbd..c7584d903db 100644 --- a/src/mesa/main/arrayobj.c +++ b/src/mesa/main/arrayobj.c @@ -373,6 +373,10 @@ bind_vertex_array(struct gl_context *ctx, GLuint id, GLboolean genRequired) return; } + save_array_object(ctx, newObj); + } + + if (!newObj->_Used) { /* The "Interactions with APPLE_vertex_array_object" section of the * GL_ARB_vertex_array_object spec says: * @@ -380,7 +384,7 @@ bind_vertex_array(struct gl_context *ctx, GLuint id, GLboolean genRequired) * BindVertexArrayAPPLE, determines the semantic of the object." */ newObj->ARBsemantics = genRequired; - save_array_object(ctx, newObj); + newObj->_Used = GL_TRUE; } } |