My VAO/VBO/IBO work fine on iPad and other devices on Android excepted two (A Samsung galaxy S4 and a Sony Xperia S).

A problem is present when I start my application on this devices, every elements move everywhere and start to blink on each frame, the problem is present on every element updated during the simulation.

I have a SpriteRenderer who share a VBO, so I need to update this VBO on each frame for each sprite (change color, uvs, …).

The visual glitch is not present on static element (like text).

So my question his:

  • Did I have to do something with my VAO on each frame?

Here is what I've got:

Init part:

 - bind vao
     -> Bind vbo
     -> Bind ibo
 - unbind vao

Rendering part:

for( sprites )
     // Update (Need to bind VAO here?)
     bind vbo (lock)
     update vbo data
     unbind vbo (unlock + bind)

     // Draw.
     bind vao
     unbind vao


  • \$\begingroup\$ I don't know the answer, but there is nothing wrong with binding the vao before the vbo in your for loop, so try that and see if it helps? It's fairly obvious that it's some glitch/feature on those devices that creates the issue, so try and see if changing the order of things fixes it. Also, you probably want to bind/unbind your vao outside the for loop anyways, only change the binding if you need to bind something else to reduce the number of opengl calls. \$\endgroup\$ Mar 6 '15 at 15:32
  • \$\begingroup\$ Sadly it didn't help. I've made a "pseudo" exemple here, in reality it's more complicated in my engine, sprites are batched, and elements are sorted by Material and Depth. Thanks for the response! \$\endgroup\$
    – user30088
    Mar 7 '15 at 21:57

A Vertex Array Object (VAO) is an object which contains one or more Vertex Buffer Objects and is designed to store the information for a complete rendered object.

You can think of it as being just a sort of parent to you VBO's, which are what store the real data. Binding a VAO just makes it easy for you, otherwise you would have to bind the buffers associated with that VAO separately. A VAO's job is to just remember which VBO's are to be bound when it itself is bound.

In your case, I don't think not binding the VAO is causing any problems. The problem might be you continuously locking and unlocking the buffer. Consider that.

  • \$\begingroup\$ Thanks, I've tried without lock/unlock code too, same problem. I figured out that it's a driver bug sadly (here).The only solution found is to disable VAO on Android :/ \$\endgroup\$
    – user30088
    Mar 6 '15 at 15:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.