Ensure texture buffer is bound before uploading to it

This commit is contained in:
Kovid Goyal 2017-02-24 14:35:02 +05:30
parent 3af501b715
commit 421ae6d289

View File

@ -157,6 +157,7 @@ class Sprites:
return glGenBuffers(1)
def set_sprite_map(self, buf_id, data, usage=GL_STREAM_DRAW):
self.bind_sprite_map(buf_id)
glNamedBufferData(buf_id, sizeof(data), addressof(data), usage)
def bind_sprite_map(self, buf_id):