Jump to content

  • Log In with Google      Sign In   
  • Create Account

VAO and similar in OpenGLES2.0 on android


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
No replies to this topic

#1 oggs91   Members   -  Reputation: 268

Like
0Likes
Like

Posted 04 September 2012 - 12:55 AM

hi

first a question to VAO in general, far as i know the vao stores some client states ... all client states?
it stores the currently bound buffers enabledvertexattribpointers right?

Code to generate a VAO (from http://www.swiftless.com/tutorials/opengl4/4-opengl-4-vao.html)
glGenVertexArrays(1, &vaoID[0]); // Create our Vertex Array Object 
glBindVertexArray(vaoID[0]); // Bind our Vertex Array Object so we can use it 
 
glGenBuffers(1, vboID); // Generate our Vertex Buffer Object 
glBindBuffer(GL_ARRAY_BUFFER, vboID[0]); // Bind our Vertex Buffer Object 
glBufferData(GL_ARRAY_BUFFER, 18 * sizeof(GLfloat), vertices, GL_STATIC_DRAW); // Set the size and data of our VBO and set it to STATIC_DRAW 
 
glVertexAttribPointer((GLuint)0, 3, GL_FLOAT, GL_FALSE, 0, 0); // Set up our vertex attributes pointer 
 
glEnableVertexAttribArray(0); // Disable our Vertex Array Object 
glBindVertexArray(0); // Disable our Vertex Buffer Object 

in this example.. isn't there a glEnableVertexAttrib(0); missing ? ..to enable the vertexattribpointer


does anything similar to vao's exist on OpengGlES2.0 (Android) ?
... or what would be a good alternative ?

Sponsor:



Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS