Prevent leaking VBOs on shutdown also.

This commit is contained in:
Unknown W. Brackets 2015-12-23 18:17:22 -08:00
parent f2410e2110
commit c3a0c14f39

View File

@ -193,6 +193,7 @@ void TransformDrawEngine::InitDeviceObjects() {
}
void TransformDrawEngine::DestroyDeviceObjects() {
ClearTrackedVertexArrays();
if (!bufferNameCache_.empty()) {
glstate.arrayBuffer.unbind();
glstate.elementArrayBuffer.unbind();
@ -205,7 +206,6 @@ void TransformDrawEngine::DestroyDeviceObjects() {
glDeleteVertexArrays(1, &sharedVao_);
}
}
ClearTrackedVertexArrays();
}
void TransformDrawEngine::GLLost() {