COVISE Core
|
#include <coImage.h>
Public Types | |
typedef coImageImpl * | vCtor (const char *filename) |
type for virtual constructor creating from a file name More... | |
Public Member Functions | |
coImage (const char *filename) | |
Constructor: build from filename. More... | |
coImage (coBinImage *binImage) | |
coImage () | |
Default c'tor: does nothing. More... | |
~coImage () | |
Destructor: build from filename. More... | |
void | scale (int newWidth, int newHeight) |
void | scaleExp2 () |
scale to next lower 2^x in both dimensions More... | |
int | getWidth () |
width of image More... | |
int | getHeight () |
height of image; More... | |
int | getNumChannels () |
get number of Color Channels More... | |
int | getNumFrames () |
get number of frames More... | |
const unsigned char * | getBitmap (int frameno=0) |
get pointer to internal data More... | |
bool | isBad () |
Did we have errors on reading. More... | |
const char * | errorMessage () |
Error message if problems occurred: empty if ok. More... | |
Static Public Member Functions | |
static bool | registerImageType (const char *suffixes[], vCtor *cTor) |
register a derived class for usage with the Factory More... | |
Private Attributes | |
coImageImpl * | image_ |
the real internal image More... | |
Static Private Attributes | |
static map< string, vCtor * > * | vCtorList_ = NULL |
virtual c'tors for given file endings More... | |
Base Class for all kinds of images
typedef coImageImpl* covise::coImage::vCtor(const char *filename) |
type for virtual constructor creating from a file name
coImage::coImage | ( | const char * | filename | ) |
Constructor: build from filename.
coImage::coImage | ( | coBinImage * | binImage | ) |
|
inline |
Default c'tor: does nothing.
coImage::~coImage | ( | ) |
Destructor: build from filename.
const char * coImage::errorMessage | ( | ) |
Error message if problems occurred: empty if ok.
const unsigned char * coImage::getBitmap | ( | int | frameno = 0 | ) |
get pointer to internal data
int coImage::getHeight | ( | ) |
height of image;
int coImage::getNumChannels | ( | ) |
get number of Color Channels
int coImage::getNumFrames | ( | ) |
get number of frames
int coImage::getWidth | ( | ) |
width of image
bool coImage::isBad | ( | ) |
Did we have errors on reading.
|
static |
register a derived class for usage with the Factory
void COIMAGEEXPORT coImage::scale | ( | int | newWidth, |
int | newHeight | ||
) |
create a scaled image: implemented, can be overridden by subclasses @@@ currently only shrink
To scale an image, we create a new coBinImage instead of the current image and attach it to our image_ variable
Line-by-line calculations of result image
void coImage::scaleExp2 | ( | ) |
scale to next lower 2^x in both dimensions
|
private |
the real internal image
|
staticprivate |
virtual c'tors for given file endings