28 #ifndef _CEGUIOpenGLTexture_h_
29 #define _CEGUIOpenGLTexture_h_
31 #include "../../CEGUIBase.h"
32 #include "../../CEGUIRenderer.h"
33 #include "../../CEGUITexture.h"
34 #include "CEGUIOpenGLRenderer.h"
48 void setOpenGLTexture(GLuint tex,
const Size& size);
57 GLuint getOpenGLTexture()
const;
79 void setTextureSize(
const Size& sz);
95 void restoreTexture();
98 const Size& getSize()
const;
99 const Size& getOriginalDataSize()
const;
100 const Vector2& getTexelScaling()
const;
101 void loadFromFile(
const String& filename,
const String& resourceGroup);
102 void loadFromMemory(
const void* buffer,
const Size& buffer_size,
104 void saveToMemory(
void* buffer);
127 void generateOpenGLTexture();
130 void updateCachedScaleValues();
133 void cleanupOpenGLTexture();
152 #endif // end of guard _CEGUIOpenGLTexture_h_
Class used as a two dimensional vector (aka a Point)
Definition: CEGUIVector.h:45
PixelFormat
Enumerated type containing the supported pixel formats that can be passed to loadFromMemory.
Definition: CEGUITexture.h:58
uint8 * d_grabBuffer
cached image data for restoring the texture.
Definition: CEGUIOpenGLTexture.h:140
Size d_dataSize
original pixel of size data loaded into texture
Definition: CEGUIOpenGLTexture.h:142
Class that holds the size (width & height) of something.
Definition: CEGUISize.h:43
GLuint d_ogltexture
The OpenGL texture we're wrapping.
Definition: CEGUIOpenGLTexture.h:136
Texture & createTexture()
Create a 'null' Texture object.
Vector2 d_texelScaling
cached pixel to texel mapping scale values.
Definition: CEGUIOpenGLTexture.h:144
Abstract base class specifying the required interface for Texture objects.
Definition: CEGUITexture.h:50
Size d_size
Size of the texture.
Definition: CEGUIOpenGLTexture.h:138
void destroyTexture(Texture &texture)
Destroy a Texture object that was previously created by calling the createTexture functions...
Renderer class to interface with OpenGL.
Definition: CEGUIOpenGLRenderer.h:66
OpenGLRenderer & d_owner
OpenGLRenderer that created and owns this OpenGLTexture.
Definition: CEGUIOpenGLTexture.h:146
Texture implementation for the OpenGLRenderer.
Definition: CEGUIOpenGLTexture.h:40
String class used within the GUI system.
Definition: CEGUIString.h:57