medfall

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 840590e10e0f8c4eb94d8dc4c1b40176d6063cc6
parent 892d10035c1d5d35d0e0d2f3cbd6a318fb387563
Author: Michael Savage <mikejsavage@gmail.com>
Date:   Wed Nov 23 23:04:14 +0200

Cast UB/TB to GLuint

Diffstat:
renderer.cc | 6++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/renderer.cc b/renderer.cc @@ -131,12 +131,14 @@ TB renderer_new_tb( TextureFormat format, const void * data, size_t len, BufferU } void renderer_ub_data( UB ub, const void * data, size_t len ) { - glBindBuffer( GL_UNIFORM_BUFFER, ub ); + GLuint ubo = checked_cast< GLuint >( ub ); + glBindBuffer( GL_UNIFORM_BUFFER, ubo ); glBufferData( GL_UNIFORM_BUFFER, len, data, GL_DYNAMIC_DRAW ); } void renderer_tb_data( TB tb, const void * data, size_t len, BufferUsage usage ) { - glBindBuffer( GL_TEXTURE_BUFFER, tb.tb ); + GLuint tbo = checked_cast< GLuint >( tb.tb ); + glBindBuffer( GL_TEXTURE_BUFFER, tbo ); glBufferData( GL_TEXTURE_BUFFER, len, data, bufferusage_to_glenum( usage ) ); }