mesa: enable ARB_direct_state_access in compat for GL3.1+
We could enable it for lower versions of GL but this allows us to just use the existing version/extension checks that are already used by the core profile. Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
@@ -196,7 +196,16 @@ _mesa_vao_attribute_map[ATTRIBUTE_MAP_MODE_MAX][VERT_ATTRIB_MAX] =
|
||||
struct gl_vertex_array_object *
|
||||
_mesa_lookup_vao(struct gl_context *ctx, GLuint id)
|
||||
{
|
||||
/* The ARB_direct_state_access specification says:
|
||||
*
|
||||
* "<vaobj> is [compatibility profile:
|
||||
* zero, indicating the default vertex array object, or]
|
||||
* the name of the vertex array object."
|
||||
*/
|
||||
if (id == 0) {
|
||||
if (ctx->API == API_OPENGL_COMPAT)
|
||||
return ctx->Array.DefaultVAO;
|
||||
|
||||
return NULL;
|
||||
} else {
|
||||
struct gl_vertex_array_object *vao;
|
||||
|
Reference in New Issue
Block a user