Texture Class Reference
[Basic]
OpenGL texture node.
More...
#include <Texture.hpp>
List of all members.
Detailed Description
OpenGL texture node.
Abstract base class for textures of various dimensions. Provides some basic texture capability, including finding an open texture unit and binding the texture to that unit. There are also two static methods, pause() and restart() that disable and reenable all active texture units.
- Note:
- Add unit to
GL_TEXTURE0
when passing directly to OpenGL.
- See also:
- Texture2D
-
Texture3D
Constructor & Destructor Documentation
Creates a new texture from an XML tag.
- Parameters:
-
[in] | type | 1D, 2D, or 3D. |
[in] | tag | XML tag with "type", "name", and "filename" attributes. |
Member Function Documentation
void associate |
( |
|
) |
[virtual] |
Finds out which texture unit to use by looking for texture ancestors.
Reimplemented from Node.
Reimplemented in Octree, and Texture2D.
string getFilename |
( |
|
) |
const [inline, virtual] |
- Returns:
- Path to the file this texture was loaded from.
GLint getFootprint |
( |
|
) |
const [virtual] |
- Returns:
- How much memory the texture uses.
GLuint getHandle |
( |
|
) |
const [inline, virtual] |
- Returns:
- OpenGL's unique identifier for this texture.
string getName |
( |
|
) |
const [inline, virtual] |
- Returns:
- User's unique identifier for this texture.
int getNumberOfActiveUnits |
( |
|
) |
[inline, static] |
- Returns:
- Number of texture units being used.
GLenum getType |
( |
|
) |
const [inline, virtual] |
- Returns:
- GL_TEXTURE_1D, GL_TEXTURE_2D, or GL_TEXTURE_3D.
int getUnit |
( |
|
) |
const [inline, virtual] |
- Returns:
- Texture unit holding the data.
bool isCompressed |
( |
|
) |
const [virtual] |
Checks if the texture was successfully compressed.
Temporarily disables texturing on all active units.
void remove |
( |
|
) |
[virtual] |
void restart |
( |
|
) |
[static] |
Renables texturing on all active units.
Discover all texture nodes under a node.
string toString |
( |
|
) |
const [virtual] |
The documentation for this class was generated from the following files: