mirror of
https://github.com/love2d/love.git
synced 2026-08-17 02:58:31 +02:00
made ShaderEffects individully handle texture units for sent images/canvases, added GL helper function for quickly binding a texture to a specific texture unit, hopefully made ShaderEffects load and unload volatile better
This commit is contained in:
@@ -47,6 +47,14 @@ void setActiveTextureUnit(GLenum textureunit);
|
||||
**/
|
||||
void bindTexture(GLuint texture);
|
||||
|
||||
/**
|
||||
* Helper for binding a texture to a specific texture unit
|
||||
* @param texture The texture to bind
|
||||
* @param textureunit The texture unit to switch to
|
||||
* @param resoreprev Restore previous texture unit when done
|
||||
**/
|
||||
void bindTextureToUnit(GLuint texture, GLenum textureunit, bool restoreprev);
|
||||
|
||||
/**
|
||||
* Helper for deleting an OpenGL texture.
|
||||
* Cleans up if the texture is currently bound.
|
||||
|
||||
Reference in New Issue
Block a user