[cogl vertex buffers] Adds fallbacks for drivers without VBO support

Buffer objects aren't currently available for glx indirect contexts, so we
now have a fallback that simply allocates fake client side vbos to store the
attributes.
This commit is contained in:
Robert Bragg
2009-04-15 19:25:55 +01:00
parent ac21e7b182
commit 46c20f1523
3 changed files with 121 additions and 35 deletions

View File

@ -125,7 +125,10 @@ typedef enum _CoglVertexBufferVBOFlags
typedef struct _CoglVertexBufferVBO
{
CoglVertexBufferVBOFlags flags;
GLuint vbo_name; /*!< The name of the corresponding buffer object */
/* Note: this is a pointer to handle fallbacks, and normally holds
* a GLuint value */
gpointer vbo_name; /*!< The name of the corresponding buffer object */
gsize vbo_bytes; /*!< The lengh of the allocated buffer object in bytes */
GList *attributes;
} CoglVertexBufferVBO;