Hi there,
I'm computing tangent space and setting it to my shader as an attribute like so:
shader.begin();
int location = shader.getAttributeLocation("tangent");
earth.getVbo().setAttributeData(location, &tangents[0], 3, tangents.size(), GL_DYNAMIC_DRAW, sizeof(ofVec3f));
shader.end();
What happens is, it randomly (maybe 1 out in 5) returns a bad access exception, from this function:
glBufferData(this->data->lastTarget, bytes, data, usage);
I've no ideia why, or how to solve this. But when it successfully builds, everything works as expected.
I've tried in master and 0.9. I'm using Mac OS 10.11, but it was also happening in 10.10.