This class represents a Texture object in GPU memory. More...
#include <Luminous/TextureGL.hpp>
Public Member Functions | |
| void | bind (int textureUnit) |
| Bind the texture to the given texture unit. More... | |
| QRegion & | dirtyRegion2D () |
| Get the dirty region of the texture. More... | |
| LUMINOUS_API TextureGL & | operator= (TextureGL &&t) |
| Move assignment operator. More... | |
| LUMINOUS_API void | setTexParameters () const |
| Apply the texture parameters to OpenGL state. | |
| LUMINOUS_API | TextureGL (StateGL &state) |
| Constructor. More... | |
| LUMINOUS_API | TextureGL (TextureGL &&t) |
| Move constructor. More... | |
| LUMINOUS_API void | upload (const Texture &texture, int textureUnit, bool forceBind) |
| Upload texture data from CPU object. More... | |
| LUMINOUS_API | ~TextureGL () |
| Destructor. | |
Public Member Functions inherited from Luminous::ResourceHandleGL | |
| bool | expired () const |
| Check if the resource has expired. More... | |
| GLuint | handle () const |
| Get the raw OpenGL handle for the resource. More... | |
| ResourceHandleGL & | operator= (ResourceHandleGL &&r) |
| Move assignment operator. More... | |
| ResourceHandleGL (StateGL &state) | |
| Constructor. More... | |
| ResourceHandleGL (ResourceHandleGL &&r) | |
| Move constructor. More... | |
| void | setExpirationSeconds (unsigned int secs) |
| Set the expiration time in seconds for the resource. More... | |
| void | touch () |
| Update the last used timestamp to current frame-time. More... | |
Additional Inherited Members | |
Protected Attributes inherited from Luminous::ResourceHandleGL | |
| GLuint | m_handle |
| Raw OpenGL handle of the resource. | |
| StateGL & | m_state |
| OpenGL state owned by the graphics driver. | |
This class represents a Texture object in GPU memory.
| LUMINOUS_API Luminous::TextureGL::TextureGL | ( | StateGL & | state | ) |
Constructor.
| state | OpenGL state |
| LUMINOUS_API Luminous::TextureGL::TextureGL | ( | TextureGL && | t | ) |
Move constructor.
| t | texture object to move |
|
inline |
Bind the texture to the given texture unit.
| textureUnit | texture unit to bind to |
|
inline |
Get the dirty region of the texture.
The dirty region keeps track of regions in the texture that must be re-uploaded.
Move assignment operator.
| t | texture object to move |