|
Public Member Functions |
| Texture (str_ptr name, int texType, int width, int height) |
| Texture (str_ptr filename, str_ptr name, bool hasRealAlpha=false, int isStencil=false) |
virtual | ~Texture () |
float * | pixelPtr (int w, int h) |
void | setPixel (int w, int h, Color c) |
Color | getPixel (int w, int h) |
void | expandToRGBA () |
void | replaceCol (Color col1, Color col2) |
void | contextInit () |
void | bindChangesToGL () |
str_ptr | name () const |
str_ptr | filename () const |
int | type () const |
int | width () const |
int | height () const |
GLuint | glName () |
GLuint | glAlphaName () |
int | hasRealAlpha () const |
int | isStencil () const |
double | aspect () const |
void | setHasRealAlpha (const int a) |
void | setStencil (const int sten) |
void | fill (Color c) |
void | print () |
void | printRow (int h) |
int | load (str_ptr filename) |
| Loads image from file, picks file format based on extension.
|
int | save (str_ptr filename) |
| Saves image to file, picks file format based on extension.
|
Protected Member Functions |
int | loadRGB (const char *fname) |
int | loadPNM (const char *fname) |
int | loadTarga (const char *fname) |
int | loadJPG (const char *fname) |
int | loadBMP (const char *fname) |
int | loadG3DFormat (const char *fname, const char *formatString) |
int | saveRGB (const char *fname) |
int | savePNM (const char *fname) |
int | saveTarga (const char *fname) |
int | saveJPG (const char *fname) |
int | saveBMP (const char *fname) |
int | saveG3DFormat (const char *fname, const char *formatString) |
Protected Attributes |
str_ptr | _name |
str_ptr | _filename |
GLfloat * | _texels |
isGlContextData< GLuint > | _glname |
isGlContextData< GLuint > | _glAlphaName |
int | _texType |
int | _width |
int | _height |
int | _hasRealAlpha |
int | _isStencil |
double | _aspect |