|  | 
| 
 Public Member Functions | 
|  | ZImage () | 
|  | Default Constructor. 
 
 | 
|  | ZImage (const ZImage &rhs) | 
|  | Copy constructor for ZImage. 
 
 | 
|  | ZImage (std::string filename) | 
|  | Constructor to Construct from File. 
 
 | 
|  | ZImage (SDL_Surface *surface) | 
|  | Constructor to Construct from SDL_Surface*. 
 
 | 
|  | ZImage (SDL_Surface *img, Sint16 x, Sint16 y, Sint16 w, Sint16 h) | 
|  | Constructor to Construct from part of an SDL_Surface*. 
 
 | 
|  | ZImage (const ZImage &img, Sint16 x, Sint16 y, Sint16 w, Sint16 h) | 
|  | Constructor to Construct from part of another ZImage. 
 
 | 
| virtual | ~ZImage () | 
|  | Destructor, frees memory. 
 
 | 
| void | Open (std::string filename) | 
|  | Opens a file. 
 
 | 
| void | OpenFromImage (SDL_Surface *img, Sint16 x, Sint16 y, Sint16 w, Sint16 h) | 
|  | Cuts part of an existing image to create a new image. 
 
 | 
| void | OpenFromImage (const ZImage &img, Sint16 x, Sint16 y, Sint16 w, Sint16 h) | 
|  | Cuts part of an existing ZImage to create a new image. 
 
 | 
| void | Attach (SDL_Surface *surface) | 
|  | Attach an existing surface to class. 
 
 | 
| void | Reload () | 
|  | Reattach a preloaded texture that has been lost. 
 
 | 
| void | Release () | 
|  | Releases image. 
 
 | 
| void | SetAlpha (Uint8 alpha) | 
|  | Set alpha value (translucency) of image. 
 
 | 
| void | SetColorKey (Uint8 red, Uint8 green, Uint8 blue) | 
|  | Set Color Key (transparent color) of image. 
 
 | 
| void | Flip (bool horizontal, bool vertical) | 
|  | Flip image over one or both axes. 
 
 | 
| void | Stretch (float xFactor, float yFactor) | 
|  | Stretch the image by a certain X and Y factor. 
 
 | 
| void | Resize (unsigned int width, unsigned int height) | 
|  | Resizes an image, stretching to new size. 
 
 | 
| void | Bind () const | 
|  | OpenGL related bind call. 
 
 | 
| void | Draw (int x, int y, Uint8 zIndex=0) const | 
|  | Draw Image to Screen. 
 
 | 
| void | Draw (float x, float y, Uint8 zIndex=0) const | 
|  | Draw Image to Screen. 
 
 | 
| void | DrawRotated (int x, int y, float angle, Uint8 zIndex=0) const | 
|  | Draw Image rotated to screen. 
 
 | 
| void | DrawRotated (float x, float y, float angle, Uint8 zIndex=0) const | 
|  | Draw Image rotated to screen. 
 
 | 
| bool | IsLoaded () const | 
|  | Check if file is loaded. 
 
 | 
| SDL_Surface * | Surface () const | 
|  | Get SDL_Surface. Get SDL_Surface pointer to actual image data. 
 
 | 
| int | Width () const | 
|  | Get Width. 
 
 | 
| int | Height () const | 
|  | Get Height. 
 
 | 
| Uint8 | Alpha () const | 
|  | Get Alpha component. 
 
 | 
| 
 Protected Attributes | 
| ZEngine * | rEngine | 
|  | Pointer to ZEngine Object. 
 
 | 
| GLfloat | rTexMinX | 
|  | Texture lower X, used internally for flip. 
 
 | 
| GLfloat | rTexMinY | 
|  | Texture lower Y, used internally for flip. 
 
 | 
| GLfloat | rTexMaxX | 
|  | Texture X width ratio, used internally by OpenGL. 
 
 | 
| GLfloat | rTexMaxY | 
|  | Texture Y width ratio, used internally by OpenGL. 
 
 | 
| SDL_Surface * | rImage | 
|  | Stored texture for future use. 
 
 | 
| unsigned int | rTexID | 
|  | Texture ID for OpenGL. 
 
 | 
| unsigned int | rWidth | 
|  | Current draw width of Texture. 
 
 | 
| unsigned int | rHeight | 
|  | Current draw height of Texture. 
 
 | 
| Uint8 | rAlpha | 
|  | Stored alpha value for drawing texture. 
 
 |