Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

Image Class Reference

#include <Image.h>

List of all members.

Public Member Functions

 Image ()
virtual ~Image ()
bool loadImage (const char *filename)
void clear ()
int getHeight () const
int getWidth () const
int getFormat () const
unsigned chargetData () const
bool toNormalMap (const bool useRGBA=true, const bool keepHeight=false)
bool toGrayScale (const bool isRGBA=true, const bool reallocate=true)
bool alphaFade ()

Public Attributes

unsigned chardata
int width
int height
unsigned int format

Protected Member Functions

bool loadBMP (const char *filename)


Detailed Description

Image.h

Author: Petter Alstermark, petter@alstermark.com

Definition at line 18 of file Image.h.


Constructor & Destructor Documentation

Image::Image  ) 
 

Image.cpp

Author: Petter Alstermark, petter@alstermark.com

Definition at line 12 of file Image.cpp.

References clear(), and data.

Here is the call graph for this function:

Image::~Image  )  [virtual]
 

Definition at line 20 of file Image.cpp.

References clear().

Here is the call graph for this function:


Member Function Documentation

bool Image::alphaFade  ) 
 

Definition at line 117 of file Image.cpp.

void Image::clear  ) 
 

Definition at line 27 of file Image.cpp.

References data, format, height, and width.

Referenced by Image(), Renderer::insertTexture(), loadImage(), and ~Image().

unsigned char * Image::getData  )  const
 

Definition at line 103 of file Image.cpp.

References data.

Referenced by OpenGLRenderer::createTexture().

int Image::getFormat  )  const
 

Definition at line 96 of file Image.cpp.

References format.

Referenced by Renderer::addCubemap(), Renderer::addTexture(), and OpenGLRenderer::createTexture().

int Image::getHeight  )  const
 

Definition at line 82 of file Image.cpp.

References height.

Referenced by Renderer::addCubemap(), Renderer::addTexture(), and OpenGLRenderer::createTexture().

int Image::getWidth  )  const
 

Definition at line 89 of file Image.cpp.

References width.

Referenced by Renderer::addCubemap(), Renderer::addTexture(), and OpenGLRenderer::createTexture().

bool Image::loadBMP const char filename  )  [protected]
 

Definition at line 55 of file Image.cpp.

References data, format, height, LOG_ERROR, LOG_SUCCESS, and width.

Referenced by loadImage().

bool Image::loadImage const char filename  ) 
 

Definition at line 37 of file Image.cpp.

References clear(), loadBMP(), and LOG_ERROR.

Referenced by Renderer::addTexture(), lava(), pink(), save(), save1(), saveCrystal1(), saveElectronic1(), and saveRadioactive1().

Here is the call graph for this function:

bool Image::toGrayScale const bool  isRGBA = true,
const bool  reallocate = true
 

Definition at line 113 of file Image.cpp.

Referenced by Renderer::addTexture().

bool Image::toNormalMap const bool  useRGBA = true,
const bool  keepHeight = false
 

Definition at line 108 of file Image.cpp.

Referenced by Renderer::addTexture().


Member Data Documentation

unsigned char* Image::data
 

Definition at line 38 of file Image.h.

Referenced by clear(), getData(), Image(), lava(), loadBMP(), pink(), save(), save1(), saveCrystal1(), saveElectronic1(), and saveRadioactive1().

unsigned int Image::format
 

Definition at line 40 of file Image.h.

Referenced by clear(), getFormat(), and loadBMP().

int Image::height
 

Definition at line 39 of file Image.h.

Referenced by clear(), getHeight(), lava(), loadBMP(), pink(), save(), save1(), saveCrystal1(), saveElectronic1(), and saveRadioactive1().

int Image::width
 

Definition at line 39 of file Image.h.

Referenced by clear(), getWidth(), lava(), loadBMP(), pink(), save(), save1(), saveCrystal1(), saveElectronic1(), and saveRadioactive1().


Generated on Sun Jun 5 15:49:48 2005 for Defacto by  doxygen 1.4.3