There is no check to make sure that the draw mode specified matches the given data. For example if you create a simple VAO with vertex data and try to draw with glDrawElements instead of glDrawArrays it will cause a seg fault because the index data doesn't exist.
There is no check to make sure that the draw mode specified matches the given data. For example if you create a simple VAO with vertex data and try to draw with glDrawElements instead of glDrawArrays it will cause a seg fault because the index data doesn't exist.