summaryrefslogtreecommitdiff
path: root/src/mesa/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/arrayobj.c63
-rw-r--r--src/mesa/main/arrayobj.h6
-rw-r--r--src/mesa/main/attrib.c2
-rw-r--r--src/mesa/main/extensions_table.h1
-rw-r--r--src/mesa/main/get_hash_params.py4
-rw-r--r--src/mesa/main/mtypes.h9
-rw-r--r--src/mesa/main/tests/dispatch_sanity.cpp2
7 files changed, 18 insertions, 69 deletions
diff --git a/src/mesa/main/arrayobj.c b/src/mesa/main/arrayobj.c
index b901a891dc2..10502015cf0 100644
--- a/src/mesa/main/arrayobj.c
+++ b/src/mesa/main/arrayobj.c
@@ -28,9 +28,8 @@
/**
* \file arrayobj.c
*
- * Implementation of Vertex Array Objects (VAOs), from OpenGL 3.1+,
- * the GL_ARB_vertex_array_object extension, or the older
- * GL_APPLE_vertex_array_object extension.
+ * Implementation of Vertex Array Objects (VAOs), from OpenGL 3.1+ /
+ * the GL_ARB_vertex_array_object extension.
*
* \todo
* The code in this file borrows a lot from bufferobj.c. There's a certain
@@ -418,12 +417,12 @@ _mesa_all_buffers_are_unmapped(const struct gl_vertex_array_object *vao)
/**
- * Helper for _mesa_BindVertexArray() and _mesa_BindVertexArrayAPPLE().
+ * Helper for _mesa_BindVertexArray().
* \param genRequired specifies behavour when id was not generated with
* glGenVertexArrays().
*/
static void
-bind_vertex_array(struct gl_context *ctx, GLuint id, GLboolean genRequired)
+bind_vertex_array(struct gl_context *ctx, GLuint id)
{
struct gl_vertex_array_object * const oldObj = ctx->Array.VAO;
struct gl_vertex_array_object *newObj = NULL;
@@ -446,20 +445,9 @@ bind_vertex_array(struct gl_context *ctx, GLuint id, GLboolean genRequired)
/* non-default array object */
newObj = _mesa_lookup_vao(ctx, id);
if (!newObj) {
- if (genRequired) {
- _mesa_error(ctx, GL_INVALID_OPERATION,
- "glBindVertexArray(non-gen name)");
- return;
- }
-
- /* For APPLE version, generate a new array object now */
- newObj = _mesa_new_vao(ctx, id);
- if (!newObj) {
- _mesa_error(ctx, GL_OUT_OF_MEMORY, "glBindVertexArrayAPPLE");
- return;
- }
-
- save_array_object(ctx, newObj);
+ _mesa_error(ctx, GL_INVALID_OPERATION,
+ "glBindVertexArray(non-gen name)");
+ return;
}
if (!newObj->EverBound) {
@@ -469,7 +457,7 @@ bind_vertex_array(struct gl_context *ctx, GLuint id, GLboolean genRequired)
* "The first bind call, either BindVertexArray or
* BindVertexArrayAPPLE, determines the semantic of the object."
*/
- newObj->ARBsemantics = genRequired;
+ newObj->ARBsemantics = GL_TRUE;
newObj->EverBound = GL_TRUE;
}
}
@@ -496,31 +484,12 @@ bind_vertex_array(struct gl_context *ctx, GLuint id, GLboolean genRequired)
/**
* ARB version of glBindVertexArray()
- * This function behaves differently from glBindVertexArrayAPPLE() in
- * that this function requires all ids to have been previously generated
- * by glGenVertexArrays[APPLE]().
*/
void GLAPIENTRY
_mesa_BindVertexArray( GLuint id )
{
GET_CURRENT_CONTEXT(ctx);
- bind_vertex_array(ctx, id, GL_TRUE);
-}
-
-
-/**
- * Bind a new array.
- *
- * \todo
- * The binding could be done more efficiently by comparing the non-NULL
- * pointers in the old and new objects. The only arrays that are "dirty" are
- * the ones that are non-NULL in either object.
- */
-void GLAPIENTRY
-_mesa_BindVertexArrayAPPLE( GLuint id )
-{
- GET_CURRENT_CONTEXT(ctx);
- bind_vertex_array(ctx, id, GL_FALSE);
+ bind_vertex_array(ctx, id);
}
@@ -572,7 +541,7 @@ _mesa_DeleteVertexArrays(GLsizei n, const GLuint *ids)
/**
* Generate a set of unique array object IDs and store them in \c arrays.
- * Helper for _mesa_GenVertexArrays[APPLE]() and _mesa_CreateVertexArrays()
+ * Helper for _mesa_GenVertexArrays() and _mesa_CreateVertexArrays()
* below.
*
* \param n Number of IDs to generate.
@@ -631,18 +600,6 @@ _mesa_GenVertexArrays(GLsizei n, GLuint *arrays)
/**
- * APPLE version of glGenVertexArraysAPPLE()
- * Arrays may live in VBOs or ordinary memory.
- */
-void GLAPIENTRY
-_mesa_GenVertexArraysAPPLE(GLsizei n, GLuint *arrays)
-{
- GET_CURRENT_CONTEXT(ctx);
- gen_vertex_arrays(ctx, n, arrays, false, "glGenVertexArraysAPPLE");
-}
-
-
-/**
* ARB_direct_state_access
* Generates ID's and creates the array objects.
*/
diff --git a/src/mesa/main/arrayobj.h b/src/mesa/main/arrayobj.h
index 830502e23a9..17949685775 100644
--- a/src/mesa/main/arrayobj.h
+++ b/src/mesa/main/arrayobj.h
@@ -35,7 +35,7 @@ struct gl_context;
/**
* \file arrayobj.h
- * Functions for the GL_APPLE_vertex_array_object extension.
+ * Functions for the GL_ARB_vertex_array_object extension.
*
* \author Ian Romanick <idr@us.ibm.com>
* \author Brian Paul
@@ -96,14 +96,10 @@ _mesa_all_buffers_are_unmapped(const struct gl_vertex_array_object *vao);
void GLAPIENTRY _mesa_BindVertexArray( GLuint id );
-void GLAPIENTRY _mesa_BindVertexArrayAPPLE( GLuint id );
-
void GLAPIENTRY _mesa_DeleteVertexArrays(GLsizei n, const GLuint *ids);
void GLAPIENTRY _mesa_GenVertexArrays(GLsizei n, GLuint *arrays);
-void GLAPIENTRY _mesa_GenVertexArraysAPPLE(GLsizei n, GLuint *buffer);
-
void GLAPIENTRY _mesa_CreateVertexArrays(GLsizei n, GLuint *arrays);
GLboolean GLAPIENTRY _mesa_IsVertexArray( GLuint id );
diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c
index 8e738c91c8f..87d327621df 100644
--- a/src/mesa/main/attrib.c
+++ b/src/mesa/main/attrib.c
@@ -1575,7 +1575,7 @@ restore_array_attrib(struct gl_context *ctx,
if (arb_vao && !_mesa_IsVertexArray(src->VAO->Name))
return;
- _mesa_BindVertexArrayAPPLE(src->VAO->Name);
+ _mesa_BindVertexArray(src->VAO->Name);
/* Restore or recreate the buffer objects by the names ... */
if (!arb_vao
diff --git a/src/mesa/main/extensions_table.h b/src/mesa/main/extensions_table.h
index dc735c5ead9..528f7308b0e 100644
--- a/src/mesa/main/extensions_table.h
+++ b/src/mesa/main/extensions_table.h
@@ -26,7 +26,6 @@ EXT(ANGLE_texture_compression_dxt5 , ANGLE_texture_compression_dxt
EXT(APPLE_object_purgeable , APPLE_object_purgeable , GLL, GLC, x , x , 2006)
EXT(APPLE_packed_pixels , dummy_true , GLL, x , x , x , 2002)
EXT(APPLE_texture_max_level , dummy_true , x , x , ES1, ES2, 2009)
-EXT(APPLE_vertex_array_object , dummy_true , GLL, x , x , x , 2002)
EXT(ARB_ES2_compatibility , ARB_ES2_compatibility , GLL, GLC, x , x , 2009)
EXT(ARB_ES3_1_compatibility , ARB_ES3_1_compatibility , x , GLC, x , x , 2014)
diff --git a/src/mesa/main/get_hash_params.py b/src/mesa/main/get_hash_params.py
index f6ffb4c84fe..58d428df1a8 100644
--- a/src/mesa/main/get_hash_params.py
+++ b/src/mesa/main/get_hash_params.py
@@ -119,8 +119,8 @@ descriptor=[
# GLSL:
[ "MAX_CLIP_PLANES", "CONTEXT_INT(Const.MaxClipPlanes), NO_EXTRA" ],
-# GL_{APPLE,ARB,OES}_vertex_array_object
- [ "VERTEX_ARRAY_BINDING_APPLE", "ARRAY_INT(Name), NO_EXTRA" ],
+# GL_{ARB,OES}_vertex_array_object
+ [ "VERTEX_ARRAY_BINDING", "ARRAY_INT(Name), NO_EXTRA" ],
# GL_EXT_texture_filter_anisotropic
[ "MAX_TEXTURE_MAX_ANISOTROPY_EXT", "CONTEXT_FLOAT(Const.MaxTextureMaxAnisotropy), extra_EXT_texture_filter_anisotropic" ],
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index b3711ba256c..2e3a423ff57 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -1496,9 +1496,8 @@ struct gl_vertex_buffer_binding
/**
- * A representation of "Vertex Array Objects" (VAOs) from OpenGL 3.1+,
- * GL_ARB_vertex_array_object, or the original GL_APPLE_vertex_array_object
- * extension.
+ * A representation of "Vertex Array Objects" (VAOs) from OpenGL 3.1+ /
+ * the GL_ARB_vertex_array_object extension.
*/
struct gl_vertex_array_object
{
@@ -1588,7 +1587,7 @@ typedef enum
*/
struct gl_array_attrib
{
- /** Currently bound array object. See _mesa_BindVertexArrayAPPLE() */
+ /** Currently bound array object. */
struct gl_vertex_array_object *VAO;
/** The default vertex array object */
@@ -1597,7 +1596,7 @@ struct gl_array_attrib
/** The last VAO accessed by a DSA function */
struct gl_vertex_array_object *LastLookedUpVAO;
- /** Array objects (GL_ARB/APPLE_vertex_array_object) */
+ /** Array objects (GL_ARB_vertex_array_object) */
struct _mesa_HashTable *Objects;
GLint ActiveTexture; /**< Client Active Texture */
diff --git a/src/mesa/main/tests/dispatch_sanity.cpp b/src/mesa/main/tests/dispatch_sanity.cpp
index 12a9ee7bae1..b33043ed28b 100644
--- a/src/mesa/main/tests/dispatch_sanity.cpp
+++ b/src/mesa/main/tests/dispatch_sanity.cpp
@@ -969,8 +969,6 @@ const struct function common_desktop_functions_possible[] = {
};
const struct function gl_compatibility_functions_possible[] = {
- { "glBindVertexArrayAPPLE", 10, -1 },
- { "glGenVertexArraysAPPLE", 10, -1 },
{ "glBindRenderbufferEXT", 10, -1 },
{ "glBindFramebufferEXT", 10, -1 },
{ "glNewList", 10, _gloffset_NewList },