ecere/gfx/drivers/OpenGL: Fixed VBO/IBOs mixup
authorJerome St-Louis <jerome@ecere.com>
Thu, 26 Feb 2015 01:55:25 +0000 (20:55 -0500)
committerJerome St-Louis <jerome@ecere.com>
Tue, 22 Dec 2015 06:45:19 +0000 (01:45 -0500)
ecere/src/gfx/drivers/OpenGLDisplayDriver.ec

index 151b8f1..31bb57e 100644 (file)
@@ -1268,7 +1268,8 @@ void GLBindBuffer(int target, uint buffer)
 #endif
       glBindBufferARB(target, buffer);
 #endif
-   currentVertexBuffer = buffer;
+   if(target == GL_ARRAY_BUFFER_ARB)
+      currentVertexBuffer = buffer;
 }
 
 public void GLVertexPointer(int numCoords, int glType, int stride, void *ptr, int numVertices)