improved GL texture binding api to take texture units into consideration

This commit is contained in:
Alexander Szpakowski
2012-12-21 20:35:32 -04:00
parent 5626b74b79
commit 16f925affa
5 changed files with 98 additions and 18 deletions
+10 -4
View File
@@ -30,16 +30,22 @@ namespace graphics
namespace opengl
{
// resets the stored bound texture id
void resetBoundTexture();
void initializeContext();
void uninitializeContext();
/**
* Helper for setting the active texture unit
* @param textureunit The GL texture unit to set
**/
void setActiveTextureUnit(GLenum textureunit);
/**
* Helper for binding an OpenGL texture.
* Makes sure we aren't redundantly binding textures.
* @param texture The texture to bind.
* @param override Overrides the checks to guarantee texture bind
**/
void bindTexture(GLuint texture, bool override = false);
void bindTexture(GLuint texture);
/**
* Helper for deleting an OpenGL texture.