Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes

ofImage Class Reference

#include <ofImage.h>

Inheritance diagram for ofImage:
ofBaseDraws ofBaseHasTexture ofBaseHasPixels

List of all members.

Public Member Functions

 ofImage ()
virtual ~ofImage ()
void allocate (int w, int h, int type)
void clear ()
 ofImage (const ofImage &mom)
ofImageoperator= (const ofImage &mom)
void clone (const ofImage &mom)
void setUseTexture (bool bUse)
ofTexturegetTextureReference ()
bool loadImage (string fileName)
void saveImage (string fileName)
unsigned char * getPixels ()
void setFromPixels (unsigned char *pixels, int w, int h, int newType, bool bOrderIsRGB=true)
void setImageType (int type)
void resize (int newWidth, int newHeight)
void grabScreen (int x, int y, int w, int h)
void update ()
void setAnchorPercent (float xPct, float yPct)
void setAnchorPoint (int x, int y)
void resetAnchor ()
void draw (float x, float y, float w, float h)
void draw (float x, float y)
float getHeight ()
float getWidth ()

Public Attributes

int width
int height
int bpp
int type

Protected Member Functions

bool loadImageIntoPixels (string fileName, ofPixels &pix)
void saveImageFromPixels (string fileName, ofPixels &pix)
void changeTypeOfPixels (ofPixels &pix, int newType)
void resizePixels (ofPixels &pix, int newWidth, int newHeight)
FIBITMAP * getBmpFromPixels (ofPixels &pix)
void putBmpIntoPixels (FIBITMAP *bmp, ofPixels &pix)
void allocatePixels (ofPixels &pix, int width, int height, int bpp)
void swapRgb (ofPixels &pix)

Protected Attributes

ofPixels myPixels
bool bUseTexture
ofTexture tex

Constructor & Destructor Documentation

ofImage::ofImage (  )
ofImage::~ofImage (  ) [virtual]
ofImage::ofImage ( const ofImage mom )

Member Function Documentation

void ofImage::allocate ( int  w,
int  h,
int  type 
)
void ofImage::allocatePixels ( ofPixels pix,
int  width,
int  height,
int  bpp 
) [inline, protected]
void ofImage::changeTypeOfPixels ( ofPixels pix,
int  newType 
) [protected]
void ofImage::clear (  )
void ofImage::clone ( const ofImage mom )
void ofImage::draw ( float  x,
float  y,
float  w,
float  h 
) [virtual]

Implements ofBaseDraws.

void ofImage::draw ( float  x,
float  y 
) [virtual]

Implements ofBaseDraws.

FIBITMAP * ofImage::getBmpFromPixels ( ofPixels pix ) [protected]
float ofImage::getHeight (  ) [virtual]

Implements ofBaseDraws.

unsigned char * ofImage::getPixels (  ) [virtual]

Implements ofBaseHasPixels.

ofTexture & ofImage::getTextureReference (  ) [virtual]

Implements ofBaseHasTexture.

float ofImage::getWidth (  ) [virtual]

Implements ofBaseDraws.

void ofImage::grabScreen ( int  x,
int  y,
int  w,
int  h 
)
bool ofImage::loadImage ( string  fileName )
bool ofImage::loadImageIntoPixels ( string  fileName,
ofPixels pix 
) [protected]
ofImage & ofImage::operator= ( const ofImage mom )
void ofImage::putBmpIntoPixels ( FIBITMAP *  bmp,
ofPixels pix 
) [protected]
void ofImage::resetAnchor (  ) [virtual]

Reimplemented from ofBaseDraws.

void ofImage::resize ( int  newWidth,
int  newHeight 
)
void ofImage::resizePixels ( ofPixels pix,
int  newWidth,
int  newHeight 
) [protected]
void ofImage::saveImage ( string  fileName )
void ofImage::saveImageFromPixels ( string  fileName,
ofPixels pix 
) [protected]
void ofImage::setAnchorPercent ( float  xPct,
float  yPct 
) [virtual]

Reimplemented from ofBaseDraws.

void ofImage::setAnchorPoint ( int  x,
int  y 
) [virtual]

Reimplemented from ofBaseDraws.

void ofImage::setFromPixels ( unsigned char *  pixels,
int  w,
int  h,
int  newType,
bool  bOrderIsRGB = true 
)
void ofImage::setImageType ( int  type )
void ofImage::setUseTexture ( bool  bUse )
void ofImage::swapRgb ( ofPixels pix ) [inline, protected]
void ofImage::update (  )

Member Data Documentation

bool ofImage::bUseTexture [protected]
ofTexture ofImage::tex [protected]

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines