#include <ImageLoader.h>
Public Member Functions | |
ImageLoader (void) | |
~ImageLoader (void) | |
void | loadImage (const char *fileName) |
bool | hasAlphaChannel () |
int | getGLImageFormat () |
unsigned int | getImageWidth () |
unsigned int | getImageHeight () |
unsigned char * | getImage () |
ImageLoader::ImageLoader | ( | void | ) |
Constructs a image loader.
ImageLoader::~ImageLoader | ( | void | ) |
Destroys this image loader.
void ImageLoader::loadImage | ( | const char * | fileName | ) |
Loads an image from the given file.
imageFile | the path to the image file to be loaded. |
std::invalid_argument | if the given image file cannot be loaded. |
bool ImageLoader::hasAlphaChannel | ( | ) |
Returns true if the loaded image has an alpha channel.
int ImageLoader::getGLImageFormat | ( | ) |
Returns the OpenGL format of the loaded image.
unsigned int ImageLoader::getImageWidth | ( | ) |
Returns the loaded image width.
unsigned int ImageLoader::getImageHeight | ( | ) |
Returns the loaded image height.
unsigned char * ImageLoader::getImage | ( | ) |
Returns the loaded image array of pixels.