|
CMSDK 2.0.1
Cross-platform C++ base library and SDK for the Psyclone AIOS platform
|
32-bit RGBA raster image with drawing, compositing, scaling, BMP I/O and update-region tracking. More...
#include <Bitmap.h>
Public Member Functions | |
| Bitmap () | |
| Empty 0x0 bitmap. | |
| Bitmap (uint32 w, uint32 h) | |
| Allocate a w x h bitmap (uninitialized pixels). | |
| Bitmap (char *imgData, uint32 w, uint32 h, bool takeData=false) | |
| Wrap or copy existing RGBA data. | |
| Bitmap (const char *imgData, uint32 size, uint32 w, uint32 h, uint32 linestep) | |
Copy from a buffer with per-row stride linestep bytes. | |
| Bitmap (const char *imgData, uint32 size, uint32 w, uint32 h, const char *encoding) | |
| Convert from another pixel encoding (e.g. | |
| Bitmap (const char *imgData, uint32 size, uint32 w, uint32 h, const char *encoding, uint32 linestep) | |
| Convert from another encoding with explicit stride. | |
| Bitmap (const char *filename) | |
| Load from a BMP file. | |
| Bitmap (BitmapUpdate *update) | |
| Reconstruct from a (full) BitmapUpdate. | |
| Bitmap (DataMessage *msg) | |
| Deserialize from a DataMessage produced by toMessage(). | |
| virtual | ~Bitmap () |
| bool | init (uint32 w, uint32 h) |
| (Re)allocate as w x h. | |
| bool | init (const char *imgData, uint32 size, uint32 w, uint32 h, const char *encoding, uint32 linestep) |
| (Re)initialize from encoded data. | |
| DataMessage * | toMessage () |
| Serialize into a new DataMessage (caller owns). | |
| BitmapUpdate * | operator- (const Bitmap &bitmap) const |
Difference update transforming bitmap into this image. | |
| bool | updateBitmap (BitmapUpdate *update, bool takeData) |
| Apply a full/RLE/diff update. | |
| BitmapUpdate * | runLengthEncode () const |
| RLE-compress the full image. | |
| BitmapUpdate * | runLengthDestructiveEncode () const |
| RLE-compress, allowed to modify this image's buffer for speed. | |
| bool | reset () |
| Release pixel data and return to the empty state. | |
| bool | mirror (bool horizontal, bool vertical) |
| Flip in place along the requested axes. | |
| bool | setPixel (uint32 x, uint32 y, uint8 red, uint8 green, uint8 blue, uint8 alpha=0) |
| Set the pixel at (x,y). | |
| bool | setPixel (uint32 pos, uint8 red, uint8 green, uint8 blue, uint8 alpha=0) |
Set the pixel at linear index pos. | |
| bool | setPixelXOR (uint32 x, uint32 y, uint8 red, uint8 green, uint8 blue, uint8 alpha=0) |
| XOR the color into the pixel at (x,y) (reversible marker drawing). | |
| bool | setPixelXOR (uint32 pos, uint8 red, uint8 green, uint8 blue, uint8 alpha=0) |
XOR the color into the pixel at linear index pos. | |
| Pixel | getPixel (uint32 x, uint32 y) |
| Get a Pixel referencing (x,y); value pointer is NULL when out of bounds. | |
| bool | getPixel (Pixel *pixel) |
Fill pixel->value from its x/y coordinates. | |
| uint32 | getPos (uint32 x, uint32 y) |
| Linear pixel index of (x,y) = y*width+x. | |
| double | getDPos (double x, double y) |
| Fractional linear index for sub-pixel coordinates. | |
| Pixel | getXY (uint32 pos) |
| Inverse of getPos(): coordinates for a linear index. | |
| Color | getPixelColor (uint32 x, uint32 y) |
| Pixel color at (x,y) as a Color value (black when out of bounds). | |
| bool | eraseBitmap () |
| Fill with black/zero. | |
| bool | eraseBitmap (uint8 r, uint8 g, uint8 b, uint8 a=0) |
| Fill with the given RGBA color. | |
| bool | eraseBitmap (const Color &color) |
Fill with color. | |
| bool | replaceColor (const Color &oldColor, const Color &newColor) |
Replace every exact occurrence of oldColor with newColor. | |
| bool | fillBox (const Box &box, const Color &color) |
| Fill a rectangle (clipped to the image). | |
| bool | fillBox (uint32 x, uint32 y, uint32 w, uint32 h, const Color &color) |
| Fill a rectangle given by scalars. | |
| bool | putTransPixel (uint32 x, uint32 y, const Color &color, double weight) |
Alpha-blend color onto the pixel with fraction weight [0,1] (anti-aliasing helper). | |
| bool | drawLine (const Line &line, const Color &color) |
| Draw a (possibly anti-aliased) line segment. | |
| bool | drawLine (const PolyLine &polyline, const Color &color) |
| Draw every segment of a polyline. | |
| bool | drawBox (const Box &box, const Color &color) |
| Draw a rectangle outline. | |
| bool | drawCircle (uint32 xCenter, uint32 yCenter, uint32 radius, const Color &color, double weight, double lineWidth, bool filled=false) |
| Draw a circle. | |
| bool | putQuadPixel (uint32 xCenter, uint32 yCenter, uint32 x, uint32 y, const Color &color, double weight) |
| Plot the 4 symmetric points of a circle octant (internal helper for drawCircle()). | |
| bool | drawBitmap (Bitmap *bitmap, uint32 x, uint32 y) |
Blit bitmap with its upper-left corner at (x,y). | |
| bool | drawBitmap (Bitmap *bitmap, uint32 x, uint32 y, uint32 w, uint32 h) |
Blit bitmap scaled/clipped into a w x h area at (x,y). | |
| bool | drawBitmap (Bitmap *bitmap, const Point &p) |
| Blit at a Point. | |
| bool | drawBitmap (Bitmap *bitmap, const Box &box) |
| Blit into a Box area. | |
| bool | drawBitmap (Bitmap *bitmap, uint32 srcx, uint32 srcy, uint32 dstx, uint32 dsty, uint32 w, uint32 h) |
Blit a w x h sub-region from (srcx,srcy) of bitmap to (dstx,dsty). | |
| Bitmap * | getCopy (const Box &box) |
| Extract a sub-image (caller owns). | |
| bool | canBeResizedTo (uint32 width, uint32 height) |
| Check whether the integer-ratio resizer supports this target size. | |
| Bitmap * | getResizedCopy (uint32 w, uint32 h, bool proportional) |
| Resized copy (caller owns). | |
| Bitmap * | getResizedCopy (double scale) |
Resized copy by uniform factor scale. | |
| bool | resizeTo (uint32 w, uint32 h, bool proportional) |
| Resize in place. | |
| bool | copyDataFromBitmap (Bitmap *bitmap, bool shouldResize=false) |
Copy pixels from bitmap; optionally resize this image to fit. | |
| bool | takeDataFromBitmap (Bitmap *bitmap) |
Steal the pixel buffer from bitmap (which becomes empty); no copy. | |
| double | getBestResizeFactor (double factor) |
Snap factor to the nearest factor achievable by the fast integer resizers. | |
| double | getBestResizeFactors (double factor, int &scaleUp, int &scaleDown, int &scale66) |
Decompose factor into up/down/66% passes used by createResizedData(). | |
| char * | createResizedData (uint32 newWidth, uint32 newHeight, int32 scaleUp, int32 scaleDown, int32 scale66) |
| Produce a resized pixel buffer using the given pass counts (caller frees). | |
| bool | readFromMemory (const char *data, uint32 size) |
| Parse a BMP file image from memory. | |
| bool | readFromFile (const char *filename) |
| Load a BMP file. | |
| bool | saveToFile (const char *filename) |
| Save as a BMP file. | |
| BitmapUpdate * | getCompressedUpdate (bool destructive) const |
| Full-frame update, RLE compressed. | |
| char * | getGrayScaleDataCopy (uint32 &len) |
| 8-bit grayscale copy of the image. | |
| bool | copyGrayScaleData (char *src, uint32 len) |
| Fill this RGBA image from an 8-bit grayscale buffer of matching size. | |
| bool | resetBitmapUpdates () |
| Clear the dirty-region tracking. | |
| bool | setBitmapUpdated () |
| Mark the whole image as changed. | |
| bool | addBitmapUpdateRegion (const Box &updateBox) |
Grow the dirty region to include updateBox. | |
| bool | hasBitmapBeenUpdated () |
| bool | hasBitmapBeenTotallyChanged () |
| int32 | round (double d) |
| Round to nearest integer (helper for pixel math). | |
| char * | toBitmapFileFormat (uint32 &len) |
| Serialize this image as a complete BMP file in memory. | |
Static Public Member Functions | |
| static bool | convertBitmapFileData (const char *src, uint32 width, uint32 height, uint32 depth, char *dst, uint32 dstlen) |
| Convert raw BMP pixel rows (bottom-up, padded) into the internal top-down RGBA layout. | |
| static char * | convertBitmapFileDataRunLength (const char *src, uint32 width, uint32 height, uint32 depth, uint32 &dstlen) |
| As convertBitmapFileData() but RLE-compressing on the fly. | |
| static char * | differenceBitmapFileData (char *orig, char *src, uint32 width, uint32 height, uint32 depth, uint32 &dstlen) |
| Encode the difference between two frames. | |
| static char * | differenceBitmapFileDataRunLength (char *orig, char *src, uint32 width, uint32 height, uint32 depth, uint32 &dstlen) |
| Difference encoding + RLE compression. | |
| static char * | DataToBitmapFileFormat (const char *data, uint32 size, uint32 width, uint32 height, uint32 &len) |
| Convert raw RGBA data into a BMP file image in memory. | |
| static char * | DataToBitmapFileFormat (const char *data, uint32 size, uint32 width, uint32 height, uint32 linestep, uint32 &len) |
As above, with an explicit source row stride linestep in bytes. | |
| static char * | DataToBitmapFileFormat (const char *data, uint32 size, uint32 width, uint32 height, const char *encoding, uint32 &len) |
| Convert pixel data in another encoding (e.g. | |
| static char * | DataToBitmapFileFormat (const char *data, uint32 size, uint32 width, uint32 height, const char *encoding, uint32 linestep, uint32 &len) |
| Encoded-source variant with an explicit row stride. | |
| static char * | DataToEncodingFormat (const char *data, uint32 size, uint32 width, uint32 height, const char *srcEncoding, uint32 linestep, const char *targetEncoding, uint32 &len) |
| General pixel-format converter between named encodings. | |
| static bool | UnitTest () |
| Self test for Bitmap and BitmapUpdate. | |
Public Attributes | |
| uint32 | width |
| Width in pixels. | |
| uint32 | height |
| Height in pixels. | |
| uint32 | size |
| Data buffer size in bytes (width*height*4). | |
| char * | data |
| Pixel data, 32-bit RGBA, row-major top-down. | |
| Box | updateRegion |
| Accumulated dirty region since the last resetBitmapUpdates(). | |
32-bit RGBA raster image with drawing, compositing, scaling, BMP I/O and update-region tracking.
Pixel layout: data holds width*height packed 32-bit pixels (size = width*height*4 bytes), row-major starting at the top-left corner with no per-row padding (stride is always width*4; constructors that take a linestep repack padded source rows during the copy). Within a pixel, byte order is R, G, B, A in increasing addresses, i.e. on a little-endian machine a pixel read as uint32 has R in the least significant byte — this is what the GET_*_FROM_RGBA macros assume. Note this is the opposite vertical order to a BMP file (bottom-up); the file routines flip rows on load/save via convertBitmapFileData().
Ownership: the Bitmap owns data and frees it in the destructor and in reset()/init(). The constructor taking takeData=true adopts the caller's malloc'd buffer instead of copying — the caller must not free it afterwards. takeDataFromBitmap() similarly transfers the buffer between Bitmap objects, leaving the source empty. Methods documented as returning "caller owns" allocate fresh buffers/objects the caller must delete/free.
Thread-safety: none — there is no internal locking; guard shared Bitmaps externally.
Most drawing methods clip against the image bounds and return false on invalid input. The updateRegion box accumulates dirty areas between resetBitmapUpdates() calls so consumers can send incremental refreshes.
| cmlabs::Bitmap::Bitmap | ( | ) |
Empty 0x0 bitmap.
Definition at line 18 of file Bitmap.cpp.
References init().
Referenced by copyDataFromBitmap(), drawBitmap(), drawBitmap(), drawBitmap(), drawBitmap(), drawBitmap(), getCopy(), getResizedCopy(), getResizedCopy(), operator-(), resizeTo(), takeDataFromBitmap(), and UnitTest().
| cmlabs::Bitmap::Bitmap | ( | uint32 | w, |
| uint32 | h ) |
Allocate a w x h bitmap (uninitialized pixels).
Definition at line 29 of file Bitmap.cpp.
References init().
| cmlabs::Bitmap::Bitmap | ( | char * | imgData, |
| uint32 | w, | ||
| uint32 | h, | ||
| bool | takeData = false ) |
Wrap or copy existing RGBA data.
| imgData | RGBA pixel buffer. |
| w,h | Dimensions in pixels. |
| takeData | Take ownership instead of copying. |
Definition at line 33 of file Bitmap.cpp.
References data, height, init(), setBitmapUpdated(), size, and width.
| cmlabs::Bitmap::Bitmap | ( | const char * | imgData, |
| uint32 | size, | ||
| uint32 | w, | ||
| uint32 | h, | ||
| uint32 | linestep ) |
Copy from a buffer with per-row stride linestep bytes.
Definition at line 48 of file Bitmap.cpp.
| cmlabs::Bitmap::Bitmap | ( | const char * | imgData, |
| uint32 | size, | ||
| uint32 | w, | ||
| uint32 | h, | ||
| const char * | encoding ) |
Convert from another pixel encoding (e.g.
"RGB", "GRAY", "YUV") into RGBA.
Definition at line 51 of file Bitmap.cpp.
| cmlabs::Bitmap::Bitmap | ( | const char * | imgData, |
| uint32 | size, | ||
| uint32 | w, | ||
| uint32 | h, | ||
| const char * | encoding, | ||
| uint32 | linestep ) |
Convert from another encoding with explicit stride.
Definition at line 54 of file Bitmap.cpp.
| cmlabs::Bitmap::Bitmap | ( | const char * | filename | ) |
Load from a BMP file.
Definition at line 22 of file Bitmap.cpp.
References init(), and readFromFile().
| cmlabs::Bitmap::Bitmap | ( | BitmapUpdate * | update | ) |
Reconstruct from a (full) BitmapUpdate.
Definition at line 260 of file Bitmap.cpp.
References fillBox(), cmlabs::BitmapUpdate::FULL, height, cmlabs::BitmapUpdate::height, init(), cmlabs::BitmapUpdate::type, updateBitmap(), width, and cmlabs::BitmapUpdate::width.
| cmlabs::Bitmap::Bitmap | ( | DataMessage * | msg | ) |
Deserialize from a DataMessage produced by toMessage().
Definition at line 283 of file Bitmap.cpp.
References data, cmlabs::DataMessage::getDataCopy(), cmlabs::DataMessage::getInt(), height, reset(), setBitmapUpdated(), size, and width.
|
virtual |
Definition at line 256 of file Bitmap.cpp.
References reset().
| bool cmlabs::Bitmap::addBitmapUpdateRegion | ( | const Box & | updateBox | ) |
Grow the dirty region to include updateBox.
Definition at line 336 of file Bitmap.cpp.
References cmlabs::Box::getLeftX(), cmlabs::Box::getUpperY(), hasBitmapBeenTotallyChanged(), and updateRegion.
Referenced by drawBitmap(), drawBitmap(), drawBox(), and fillBox().
| bool cmlabs::Bitmap::canBeResizedTo | ( | uint32 | width, |
| uint32 | height ) |
Check whether the integer-ratio resizer supports this target size.
Definition at line 984 of file Bitmap.cpp.
References getBestResizeFactor(), height, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1canBeResizedTo().
|
static |
Convert raw BMP pixel rows (bottom-up, padded) into the internal top-down RGBA layout.
Definition at line 2850 of file Bitmap.cpp.
Referenced by _wrap_Bitmap_convertBitmapFileData(), _wrap_Bitmap_convertBitmapFileData(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1convertBitmapFileData(), cmlabs::BitmapUpdate::readFromFile(), and readFromMemory().
|
static |
As convertBitmapFileData() but RLE-compressing on the fly.
Definition at line 2874 of file Bitmap.cpp.
References DATACTRL, height, RLECTRL, and width.
Referenced by _wrap_Bitmap_convertBitmapFileDataRunLength(), _wrap_Bitmap_convertBitmapFileDataRunLength(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1convertBitmapFileDataRunLength(), and cmlabs::BitmapUpdate::readFromFileRLE().
| bool cmlabs::Bitmap::copyDataFromBitmap | ( | Bitmap * | bitmap, |
| bool | shouldResize = false ) |
Copy pixels from bitmap; optionally resize this image to fit.
Definition at line 1193 of file Bitmap.cpp.
References Bitmap(), data, getResizedCopy(), height, size, takeDataFromBitmap(), and width.
Referenced by _wrap_Bitmap_copyDataFromBitmap__SWIG_1(), _wrap_Bitmap_copyDataFromBitmap__SWIG_1(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1copyDataFromBitmap_1_1SWIG_10(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1copyDataFromBitmap_1_1SWIG_11().
| bool cmlabs::Bitmap::copyGrayScaleData | ( | char * | src, |
| uint32 | len ) |
Fill this RGBA image from an 8-bit grayscale buffer of matching size.
Definition at line 418 of file Bitmap.cpp.
References data, GET_RGB_FROM_GRAY, height, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1copyGrayScaleData().
| char * cmlabs::Bitmap::createResizedData | ( | uint32 | newWidth, |
| uint32 | newHeight, | ||
| int32 | scaleUp, | ||
| int32 | scaleDown, | ||
| int32 | scale66 ) |
Produce a resized pixel buffer using the given pass counts (caller frees).
Definition at line 1137 of file Bitmap.cpp.
References data, height, cmlabs::ImageResizeDown(), cmlabs::ImageResizeDown66(), cmlabs::ImageResizeUp(), cmlabs::ImageResizeUp66(), and width.
Referenced by getResizedCopy(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1createResizedData().
|
static |
Convert pixel data in another encoding (e.g.
"RGB", "GRAY", "YUV") to a BMP file image.
Definition at line 2131 of file Bitmap.cpp.
References data, DataToBitmapFileFormat(), height, size, and width.
|
static |
Encoded-source variant with an explicit row stride.
Definition at line 2135 of file Bitmap.cpp.
References cmlabs::tagBITMAPFILEHEADER_CM::bfOffBits, cmlabs::tagBITMAPFILEHEADER_CM::bfReserved1, cmlabs::tagBITMAPFILEHEADER_CM::bfReserved2, cmlabs::tagBITMAPFILEHEADER_CM::bfSize, cmlabs::tagBITMAPFILEHEADER_CM::bfType, cmlabs::tagBITMAPINFOHEADER_CM::biBitCount, cmlabs::tagBITMAPINFOHEADER_CM::biClrImportant, cmlabs::tagBITMAPINFOHEADER_CM::biClrUsed, cmlabs::tagBITMAPINFOHEADER_CM::biCompression, cmlabs::tagBITMAPINFOHEADER_CM::biHeight, cmlabs::tagBITMAPINFOHEADER_CM::biPlanes, cmlabs::tagBITMAPINFOHEADER_CM::biSize, cmlabs::tagBITMAPINFOHEADER_CM::biSizeImage, cmlabs::tagBITMAPINFOHEADER_CM::biWidth, cmlabs::tagBITMAPINFOHEADER_CM::biXPelsPerMeter, cmlabs::tagBITMAPINFOHEADER_CM::biYPelsPerMeter, data, height, size, stricmp, and width.
|
static |
Convert raw RGBA data into a BMP file image in memory.
| data | Source pixels. | |
| size | Source size in bytes. | |
| width,height | Dimensions in pixels. | |
| [out] | len | File size. |
Definition at line 2113 of file Bitmap.cpp.
References data, DataToBitmapFileFormat(), height, size, and width.
Referenced by _wrap_Bitmap_DataToBitmapFileFormat__SWIG_0(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_0(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_1(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_1(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_2(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_2(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_3(), _wrap_Bitmap_DataToBitmapFileFormat__SWIG_3(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1DataToBitmapFileFormat_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1DataToBitmapFileFormat_1_1SWIG_11(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1DataToBitmapFileFormat_1_1SWIG_12(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1DataToBitmapFileFormat_1_1SWIG_13(), and toBitmapFileFormat().
|
static |
As above, with an explicit source row stride linestep in bytes.
Definition at line 2117 of file Bitmap.cpp.
References data, DataToBitmapFileFormat(), height, size, and width.
|
static |
General pixel-format converter between named encodings.
| data | Source pixels. | |
| size | Source size in bytes. | |
| width,height | Dimensions. | |
| srcEncoding | Source format name. | |
| linestep | Source row stride in bytes. | |
| targetEncoding | Destination format name. | |
| [out] | len | Destination size. |
Definition at line 2409 of file Bitmap.cpp.
References data, height, size, stricmp, and width.
Referenced by _wrap_Bitmap_DataToEncodingFormat(), _wrap_Bitmap_DataToEncodingFormat(), init(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1DataToEncodingFormat().
|
static |
Encode the difference between two frames.
Definition at line 3022 of file Bitmap.cpp.
References DATACTRL, DIFCTRL, height, and width.
Referenced by _wrap_Bitmap_differenceBitmapFileData(), _wrap_Bitmap_differenceBitmapFileData(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1differenceBitmapFileData(), and cmlabs::BitmapUpdate::readFromFileDiff().
|
static |
Difference encoding + RLE compression.
Definition at line 3153 of file Bitmap.cpp.
References DATACTRL, DIFCTRL, height, RLECTRL, and width.
Referenced by _wrap_Bitmap_differenceBitmapFileDataRunLength(), _wrap_Bitmap_differenceBitmapFileDataRunLength(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1differenceBitmapFileDataRunLength(), and cmlabs::BitmapUpdate::readFromFileRLEDiff().
Blit into a Box area.
Definition at line 1606 of file Bitmap.cpp.
References Bitmap(), drawBitmap(), cmlabs::Box::getHeight(), cmlabs::Box::getLeftX(), cmlabs::Box::getUpperY(), and cmlabs::Box::getWidth().
Blit at a Point.
Definition at line 1602 of file Bitmap.cpp.
References Bitmap(), drawBitmap(), cmlabs::Point::x, and cmlabs::Point::y.
| bool cmlabs::Bitmap::drawBitmap | ( | Bitmap * | bitmap, |
| uint32 | srcx, | ||
| uint32 | srcy, | ||
| uint32 | dstx, | ||
| uint32 | dsty, | ||
| uint32 | w, | ||
| uint32 | h ) |
Blit a w x h sub-region from (srcx,srcy) of bitmap to (dstx,dsty).
Definition at line 1497 of file Bitmap.cpp.
References addBitmapUpdateRegion(), Bitmap(), data, height, and width.
| bool cmlabs::Bitmap::drawBitmap | ( | Bitmap * | bitmap, |
| uint32 | x, | ||
| uint32 | y ) |
Blit bitmap with its upper-left corner at (x,y).
Definition at line 1550 of file Bitmap.cpp.
References addBitmapUpdateRegion(), Bitmap(), drawBitmap(), height, and width.
Referenced by drawBitmap(), drawBitmap(), drawBitmap(), drawBitmap(), getCopy(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1drawBitmap_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1drawBitmap_1_1SWIG_11(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1drawBitmap_1_1SWIG_14().
| bool cmlabs::Bitmap::drawBitmap | ( | Bitmap * | bitmap, |
| uint32 | x, | ||
| uint32 | y, | ||
| uint32 | w, | ||
| uint32 | h ) |
Blit bitmap scaled/clipped into a w x h area at (x,y).
Definition at line 1557 of file Bitmap.cpp.
References Bitmap(), data, and drawBitmap().
Draw a rectangle outline.
Definition at line 1345 of file Bitmap.cpp.
References addBitmapUpdateRegion(), drawLine(), cmlabs::Box::getLineWidth(), cmlabs::Box::getLowerLeft(), cmlabs::Box::getLowerRight(), cmlabs::Box::getUpperLeft(), and cmlabs::Box::getUpperRight().
| bool cmlabs::Bitmap::drawCircle | ( | uint32 | xCenter, |
| uint32 | yCenter, | ||
| uint32 | radius, | ||
| const Color & | color, | ||
| double | weight, | ||
| double | lineWidth, | ||
| bool | filled = false ) |
Draw a circle.
| xCenter,yCenter | Center in pixels. |
| radius | Radius in pixels. |
| color | Stroke/fill color. |
| weight | Blend fraction. |
| lineWidth | Stroke width. |
| filled | Fill the disc when true. |
Definition at line 1373 of file Bitmap.cpp.
References D, drawCircle(), putQuadPixel(), and round().
Referenced by drawCircle().
Draw a (possibly anti-aliased) line segment.
Definition at line 886 of file Bitmap.cpp.
References clPI, cmlabs::Line::endPoint, cmlabs::Line::lineWidth, putTransPixel(), cmlabs::Line::startPoint, cmlabs::PointFloat::x, and cmlabs::PointFloat::y.
Referenced by drawBox(), and drawLine().
Draw every segment of a polyline.
Definition at line 1337 of file Bitmap.cpp.
References drawLine(), cmlabs::PolyLine::getLine(), cmlabs::PolyLine::getLineCount(), and setBitmapUpdated().
| bool cmlabs::Bitmap::eraseBitmap | ( | ) |
Fill with black/zero.
Definition at line 759 of file Bitmap.cpp.
References eraseBitmap().
Referenced by _wrap_Bitmap_eraseBitmap__SWIG_0(), _wrap_Bitmap_eraseBitmap__SWIG_0(), eraseBitmap(), eraseBitmap(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1eraseBitmap_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1eraseBitmap_1_1SWIG_11(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1eraseBitmap_1_1SWIG_12(), and UnitTest().
| bool cmlabs::Bitmap::eraseBitmap | ( | const Color & | color | ) |
Fill with color.
Definition at line 794 of file Bitmap.cpp.
References cmlabs::Color::b, eraseBitmap(), cmlabs::Color::g, and cmlabs::Color::r.
| bool cmlabs::Bitmap::eraseBitmap | ( | uint8 | r, |
| uint8 | g, | ||
| uint8 | b, | ||
| uint8 | a = 0 ) |
Fill with the given RGBA color.
Definition at line 763 of file Bitmap.cpp.
References data, setBitmapUpdated(), size, and width.
Fill a rectangle (clipped to the image).
Definition at line 817 of file Bitmap.cpp.
References fillBox(), cmlabs::Box::getHeight(), cmlabs::Box::getLeftX(), cmlabs::Box::getUpperY(), and cmlabs::Box::getWidth().
Referenced by Bitmap(), fillBox(), and UnitTest().
| bool cmlabs::Bitmap::fillBox | ( | uint32 | x, |
| uint32 | y, | ||
| uint32 | w, | ||
| uint32 | h, | ||
| const Color & | color ) |
Fill a rectangle given by scalars.
Definition at line 821 of file Bitmap.cpp.
References addBitmapUpdateRegion(), cmlabs::Color::b, data, cmlabs::Color::g, height, cmlabs::Color::r, and width.
| double cmlabs::Bitmap::getBestResizeFactor | ( | double | factor | ) |
Snap factor to the nearest factor achievable by the fast integer resizers.
Definition at line 1126 of file Bitmap.cpp.
References getBestResizeFactors().
Referenced by canBeResizedTo(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getBestResizeFactor().
| double cmlabs::Bitmap::getBestResizeFactors | ( | double | factor, |
| int & | scaleUp, | ||
| int & | scaleDown, | ||
| int & | scale66 ) |
Decompose factor into up/down/66% passes used by createResizedData().
Definition at line 1074 of file Bitmap.cpp.
Referenced by getBestResizeFactor(), getResizedCopy(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getBestResizeFactors().
| BitmapUpdate * cmlabs::Bitmap::getCompressedUpdate | ( | bool | destructive | ) | const |
Full-frame update, RLE compressed.
| destructive | Allow modifying this bitmap's buffer for speed. |
Definition at line 3271 of file Bitmap.cpp.
References runLengthDestructiveEncode(), and runLengthEncode().
Referenced by operator-().
Extract a sub-image (caller owns).
Definition at line 381 of file Bitmap.cpp.
References Bitmap(), drawBitmap(), cmlabs::Size::h, cmlabs::Box::size, cmlabs::Box::upperLeft, cmlabs::Size::w, cmlabs::PointFloat::x, and cmlabs::PointFloat::y.
Referenced by _wrap_Bitmap_getCopy(), _wrap_Bitmap_getCopy(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getCopy(), and UnitTest().
| double cmlabs::Bitmap::getDPos | ( | double | x, |
| double | y ) |
Fractional linear index for sub-pixel coordinates.
Definition at line 733 of file Bitmap.cpp.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getDPos().
| char * cmlabs::Bitmap::getGrayScaleDataCopy | ( | uint32 & | len | ) |
8-bit grayscale copy of the image.
| [out] | len | Buffer size. |
Definition at line 403 of file Bitmap.cpp.
References data, GET_GRAY_FROM_RGB, height, size, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getGrayScaleDataCopy().
| bool cmlabs::Bitmap::getPixel | ( | Pixel * | pixel | ) |
Fill pixel->value from its x/y coordinates.
Definition at line 717 of file Bitmap.cpp.
References data, height, cmlabs::Pixel::value, width, cmlabs::Pixel::x, and cmlabs::Pixel::y.
| Pixel cmlabs::Bitmap::getPixel | ( | uint32 | x, |
| uint32 | y ) |
Get a Pixel referencing (x,y); value pointer is NULL when out of bounds.
Definition at line 708 of file Bitmap.cpp.
References getPixel(), cmlabs::Pixel::value, cmlabs::Pixel::x, and cmlabs::Pixel::y.
Referenced by getPixel().
| Color cmlabs::Bitmap::getPixelColor | ( | uint32 | x, |
| uint32 | y ) |
Pixel color at (x,y) as a Color value (black when out of bounds).
Definition at line 862 of file Bitmap.cpp.
References cmlabs::Color::b, data, cmlabs::Color::g, getPos(), height, cmlabs::Color::r, and width.
Referenced by UnitTest().
| uint32 cmlabs::Bitmap::getPos | ( | uint32 | x, |
| uint32 | y ) |
Linear pixel index of (x,y) = y*width+x.
Definition at line 727 of file Bitmap.cpp.
Referenced by getPixelColor(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getPos(), and UnitTest().
| Bitmap * cmlabs::Bitmap::getResizedCopy | ( | double | scale | ) |
Resized copy by uniform factor scale.
Definition at line 1024 of file Bitmap.cpp.
References Bitmap(), createResizedData(), getBestResizeFactors(), height, and width.
| Bitmap * cmlabs::Bitmap::getResizedCopy | ( | uint32 | w, |
| uint32 | h, | ||
| bool | proportional ) |
Resized copy (caller owns).
| w,h | Target dimensions in pixels. |
| proportional | Preserve aspect ratio (letterboxing target size). |
Definition at line 1053 of file Bitmap.cpp.
References Bitmap(), getResizedCopy(), height, and width.
Referenced by _wrap_Bitmap_getResizedCopy__SWIG_0(), _wrap_Bitmap_getResizedCopy__SWIG_0(), _wrap_Bitmap_getResizedCopy__SWIG_1(), _wrap_Bitmap_getResizedCopy__SWIG_1(), copyDataFromBitmap(), getResizedCopy(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getResizedCopy_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1getResizedCopy_1_1SWIG_11(), and resizeTo().
| Pixel cmlabs::Bitmap::getXY | ( | uint32 | pos | ) |
Inverse of getPos(): coordinates for a linear index.
Definition at line 739 of file Bitmap.cpp.
References data, cmlabs::Pixel::value, width, cmlabs::Pixel::x, and cmlabs::Pixel::y.
| bool cmlabs::Bitmap::hasBitmapBeenTotallyChanged | ( | ) |
Definition at line 368 of file Bitmap.cpp.
References updateRegion.
Referenced by _wrap_Bitmap_hasBitmapBeenTotallyChanged(), _wrap_Bitmap_hasBitmapBeenTotallyChanged(), addBitmapUpdateRegion(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1hasBitmapBeenTotallyChanged().
| bool cmlabs::Bitmap::hasBitmapBeenUpdated | ( | ) |
Definition at line 364 of file Bitmap.cpp.
References updateRegion.
Referenced by _wrap_Bitmap_hasBitmapBeenUpdated(), _wrap_Bitmap_hasBitmapBeenUpdated(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1hasBitmapBeenUpdated().
| bool cmlabs::Bitmap::init | ( | const char * | imgData, |
| uint32 | size, | ||
| uint32 | w, | ||
| uint32 | h, | ||
| const char * | encoding, | ||
| uint32 | linestep ) |
(Re)initialize from encoded data.
Definition at line 58 of file Bitmap.cpp.
References data, DataToEncodingFormat(), height, init(), setBitmapUpdated(), size, stricmp, and width.
| bool cmlabs::Bitmap::init | ( | uint32 | w, |
| uint32 | h ) |
(Re)allocate as w x h.
Definition at line 305 of file Bitmap.cpp.
References data, height, setBitmapUpdated(), size, and width.
Referenced by Bitmap(), Bitmap(), Bitmap(), Bitmap(), Bitmap(), Bitmap(), Bitmap(), Bitmap(), init(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1init_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1init_1_1SWIG_11(), readFromMemory(), and updateBitmap().
| bool cmlabs::Bitmap::mirror | ( | bool | horizontal, |
| bool | vertical ) |
Flip in place along the requested axes.
Definition at line 1447 of file Bitmap.cpp.
References data, height, size, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1mirror().
| BitmapUpdate * cmlabs::Bitmap::operator- | ( | const Bitmap & | bitmap | ) | const |
Difference update transforming bitmap into this image.
Definition at line 3279 of file Bitmap.cpp.
References Bitmap(), data, cmlabs::BitmapUpdate::data, DATACTRL, DIFCTRL, cmlabs::BitmapUpdate::DIFRUNLENGTH, getCompressedUpdate(), height, RLECTRL, cmlabs::BitmapUpdate::setUpdateType(), cmlabs::BitmapUpdate::size, and width.
| bool cmlabs::Bitmap::putQuadPixel | ( | uint32 | xCenter, |
| uint32 | yCenter, | ||
| uint32 | x, | ||
| uint32 | y, | ||
| const Color & | color, | ||
| double | weight ) |
Plot the 4 symmetric points of a circle octant (internal helper for drawCircle()).
Definition at line 1360 of file Bitmap.cpp.
References putTransPixel().
Referenced by drawCircle().
| bool cmlabs::Bitmap::putTransPixel | ( | uint32 | x, |
| uint32 | y, | ||
| const Color & | color, | ||
| double | weight ) |
Alpha-blend color onto the pixel with fraction weight [0,1] (anti-aliasing helper).
Definition at line 876 of file Bitmap.cpp.
References cmlabs::Color::b, data, cmlabs::Color::g, height, cmlabs::Color::r, and width.
Referenced by drawLine(), and putQuadPixel().
| bool cmlabs::Bitmap::readFromFile | ( | const char * | filename | ) |
Load a BMP file.
Definition at line 1989 of file Bitmap.cpp.
References cmlabs::utils::ReadAFile(), and readFromMemory().
Referenced by Bitmap(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1readFromFile().
| bool cmlabs::Bitmap::readFromMemory | ( | const char * | data, |
| uint32 | size ) |
Parse a BMP file image from memory.
Definition at line 1898 of file Bitmap.cpp.
References cmlabs::tagBITMAPFILEHEADER_CM::bfOffBits, cmlabs::tagBITMAPFILEHEADER_CM::bfSize, cmlabs::tagBITMAPINFOHEADER_CM::biBitCount, cmlabs::tagBITMAPINFOHEADER_CM::biCompression, cmlabs::tagBITMAPINFOHEADER_CM::biHeight, cmlabs::tagBITMAPINFOHEADER_CM::biPlanes, cmlabs::tagBITMAPINFOHEADER_CM::biSizeImage, cmlabs::tagBITMAPINFOHEADER_CM::biWidth, convertBitmapFileData(), data, height, init(), setBitmapUpdated(), size, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1readFromMemory(), and readFromFile().
Replace every exact occurrence of oldColor with newColor.
Definition at line 798 of file Bitmap.cpp.
References cmlabs::Color::b, data, cmlabs::Color::g, height, cmlabs::Color::r, and width.
Referenced by UnitTest().
| bool cmlabs::Bitmap::reset | ( | ) |
Release pixel data and return to the empty state.
Definition at line 375 of file Bitmap.cpp.
References data.
Referenced by _wrap_Bitmap_reset(), _wrap_Bitmap_reset(), Bitmap(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1reset(), updateBitmap(), and ~Bitmap().
| bool cmlabs::Bitmap::resetBitmapUpdates | ( | ) |
Clear the dirty-region tracking.
Definition at line 354 of file Bitmap.cpp.
References updateRegion.
Referenced by _wrap_Bitmap_resetBitmapUpdates(), _wrap_Bitmap_resetBitmapUpdates(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1resetBitmapUpdates().
| bool cmlabs::Bitmap::resizeTo | ( | uint32 | w, |
| uint32 | h, | ||
| bool | proportional ) |
Resize in place.
Definition at line 1065 of file Bitmap.cpp.
References Bitmap(), getResizedCopy(), and takeDataFromBitmap().
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1resizeTo().
| int cmlabs::Bitmap::round | ( | double | d | ) |
Round to nearest integer (helper for pixel math).
Definition at line 2775 of file Bitmap.cpp.
Referenced by drawCircle(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1round().
| BitmapUpdate * cmlabs::Bitmap::runLengthDestructiveEncode | ( | ) | const |
RLE-compress, allowed to modify this image's buffer for speed.
Definition at line 3494 of file Bitmap.cpp.
References data, cmlabs::BitmapUpdate::data, DATACTRL, GET_DRGB_FROM_2RGBS, height, cmlabs::BitmapUpdate::RL16, RLECTRL, cmlabs::BitmapUpdate::setUpdateType(), cmlabs::BitmapUpdate::size, and width.
Referenced by getCompressedUpdate().
| BitmapUpdate * cmlabs::Bitmap::runLengthEncode | ( | ) | const |
RLE-compress the full image.
Definition at line 3413 of file Bitmap.cpp.
References data, cmlabs::BitmapUpdate::data, DATACTRL, height, RLECTRL, cmlabs::BitmapUpdate::RUNLENGTH, cmlabs::BitmapUpdate::setUpdateType(), cmlabs::BitmapUpdate::size, and width.
Referenced by getCompressedUpdate().
| bool cmlabs::Bitmap::saveToFile | ( | const char * | filename | ) |
Save as a BMP file.
Definition at line 2003 of file Bitmap.cpp.
References toBitmapFileFormat(), and cmlabs::utils::WriteAFile().
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1saveToFile().
| bool cmlabs::Bitmap::setBitmapUpdated | ( | ) |
Mark the whole image as changed.
Definition at line 359 of file Bitmap.cpp.
References height, updateRegion, and width.
Referenced by _wrap_Bitmap_setBitmapUpdated(), _wrap_Bitmap_setBitmapUpdated(), Bitmap(), Bitmap(), drawLine(), eraseBitmap(), init(), init(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setBitmapUpdated(), readFromMemory(), setPixel(), setPixelXOR(), and updateBitmap().
| bool cmlabs::Bitmap::setPixel | ( | uint32 | pos, |
| uint8 | red, | ||
| uint8 | green, | ||
| uint8 | blue, | ||
| uint8 | alpha = 0 ) |
Set the pixel at linear index pos.
Definition at line 670 of file Bitmap.cpp.
References data, setBitmapUpdated(), and size.
| bool cmlabs::Bitmap::setPixel | ( | uint32 | x, |
| uint32 | y, | ||
| uint8 | red, | ||
| uint8 | green, | ||
| uint8 | blue, | ||
| uint8 | alpha = 0 ) |
Set the pixel at (x,y).
Definition at line 658 of file Bitmap.cpp.
References data, height, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixel_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixel_1_1SWIG_11(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixel_1_1SWIG_12(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixel_1_1SWIG_13(), and UnitTest().
| bool cmlabs::Bitmap::setPixelXOR | ( | uint32 | pos, |
| uint8 | red, | ||
| uint8 | green, | ||
| uint8 | blue, | ||
| uint8 | alpha = 0 ) |
XOR the color into the pixel at linear index pos.
Definition at line 695 of file Bitmap.cpp.
References data, setBitmapUpdated(), and size.
| bool cmlabs::Bitmap::setPixelXOR | ( | uint32 | x, |
| uint32 | y, | ||
| uint8 | red, | ||
| uint8 | green, | ||
| uint8 | blue, | ||
| uint8 | alpha = 0 ) |
XOR the color into the pixel at (x,y) (reversible marker drawing).
Definition at line 683 of file Bitmap.cpp.
References data, height, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixelXOR_1_1SWIG_10(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixelXOR_1_1SWIG_11(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixelXOR_1_1SWIG_12(), and Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1setPixelXOR_1_1SWIG_13().
| bool cmlabs::Bitmap::takeDataFromBitmap | ( | Bitmap * | bitmap | ) |
Steal the pixel buffer from bitmap (which becomes empty); no copy.
Definition at line 1225 of file Bitmap.cpp.
References Bitmap(), data, height, size, and width.
Referenced by _wrap_Bitmap_takeDataFromBitmap(), _wrap_Bitmap_takeDataFromBitmap(), copyDataFromBitmap(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1takeDataFromBitmap(), and resizeTo().
| char * cmlabs::Bitmap::toBitmapFileFormat | ( | uint32 & | len | ) |
Serialize this image as a complete BMP file in memory.
| [out] | len | File size. |
Definition at line 2109 of file Bitmap.cpp.
References data, DataToBitmapFileFormat(), height, size, and width.
Referenced by Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1toBitmapFileFormat(), and saveToFile().
| DataMessage * cmlabs::Bitmap::toMessage | ( | ) |
Serialize into a new DataMessage (caller owns).
Definition at line 294 of file Bitmap.cpp.
References data, height, cmlabs::DataMessage::setData(), cmlabs::DataMessage::setInt(), size, and width.
Referenced by UnitTest().
|
static |
Self test for Bitmap and BitmapUpdate.
Definition at line 4500 of file Bitmap.cpp.
References cmlabs::Color::b, Bitmap(), data, cmlabs::unittest::detail(), eraseBitmap(), cmlabs::unittest::fail(), fillBox(), cmlabs::Color::g, getCopy(), getPixelColor(), getPos(), cmlabs::GetTimeNow(), height, cmlabs::unittest::metric(), cmlabs::unittest::progress(), cmlabs::Color::r, replaceColor(), setPixel(), size, toMessage(), and width.
Referenced by _wrap_Bitmap_UnitTest(), and cmlabs::Register_Bitmap_Tests().
| bool cmlabs::Bitmap::updateBitmap | ( | BitmapUpdate * | update, |
| bool | takeData ) |
Apply a full/RLE/diff update.
| update | The update to apply. |
| takeData | Steal the update's buffer when possible. |
Definition at line 430 of file Bitmap.cpp.
References data, cmlabs::BitmapUpdate::data, DATACTRL, cmlabs::BitmapUpdate::DIF, DIFCTRL, cmlabs::BitmapUpdate::DIFRUNLENGTH, cmlabs::BitmapUpdate::FULL, GET_FIRSTRGB_FROM_DRGB, GET_SECONDRGB_FROM_DRGB, height, cmlabs::BitmapUpdate::height, init(), reset(), cmlabs::BitmapUpdate::RL16, RLECTRL, cmlabs::BitmapUpdate::RUNLENGTH, setBitmapUpdated(), size, cmlabs::BitmapUpdate::size, cmlabs::BitmapUpdate::type, width, and cmlabs::BitmapUpdate::width.
Referenced by Bitmap().
| char* cmlabs::Bitmap::data |
Pixel data, 32-bit RGBA, row-major top-down.
Definition at line 251 of file Bitmap.h.
Referenced by _wrap_Bitmap_data_set(), _wrap_Bitmap_data_set(), Bitmap(), Bitmap(), copyDataFromBitmap(), copyGrayScaleData(), createResizedData(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToEncodingFormat(), drawBitmap(), drawBitmap(), eraseBitmap(), fillBox(), getGrayScaleDataCopy(), getPixel(), getPixelColor(), getXY(), init(), init(), cmlabs::Internal_BitmapPoster(), Java_com_cmlabs_cmsdk_cmsdkJNI_Bitmap_1data_1set(), mirror(), operator-(), putTransPixel(), cmlabs::BitmapUpdate::readFromFileDiff(), cmlabs::BitmapUpdate::readFromFileRLEDiff(), readFromMemory(), replaceColor(), reset(), runLengthDestructiveEncode(), runLengthEncode(), cmlabs::BitmapUpdate::setFullUpdate(), setPixel(), setPixel(), setPixelXOR(), setPixelXOR(), takeDataFromBitmap(), toBitmapFileFormat(), toMessage(), UnitTest(), and updateBitmap().
| uint32 cmlabs::Bitmap::height |
Height in pixels.
Definition at line 249 of file Bitmap.h.
Referenced by Bitmap(), Bitmap(), Bitmap(), canBeResizedTo(), convertBitmapFileData(), convertBitmapFileDataRunLength(), copyDataFromBitmap(), copyGrayScaleData(), createResizedData(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToEncodingFormat(), differenceBitmapFileData(), differenceBitmapFileDataRunLength(), drawBitmap(), drawBitmap(), fillBox(), getDPos(), getGrayScaleDataCopy(), getPixel(), getPixelColor(), getPos(), getResizedCopy(), getResizedCopy(), init(), init(), cmlabs::Internal_BitmapPoster(), mirror(), operator-(), putTransPixel(), readFromMemory(), replaceColor(), runLengthDestructiveEncode(), runLengthEncode(), setBitmapUpdated(), cmlabs::BitmapUpdate::setFullUpdate(), setPixel(), setPixelXOR(), takeDataFromBitmap(), toBitmapFileFormat(), toMessage(), UnitTest(), and updateBitmap().
| uint32 cmlabs::Bitmap::size |
Data buffer size in bytes (width*height*4).
Definition at line 250 of file Bitmap.h.
Referenced by Bitmap(), Bitmap(), Bitmap(), Bitmap(), Bitmap(), copyDataFromBitmap(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToEncodingFormat(), eraseBitmap(), getGrayScaleDataCopy(), init(), init(), cmlabs::Internal_BitmapPoster(), mirror(), readFromMemory(), cmlabs::BitmapUpdate::setFullUpdate(), setPixel(), setPixelXOR(), takeDataFromBitmap(), toBitmapFileFormat(), toMessage(), UnitTest(), and updateBitmap().
| Box cmlabs::Bitmap::updateRegion |
Accumulated dirty region since the last resetBitmapUpdates().
Definition at line 252 of file Bitmap.h.
Referenced by addBitmapUpdateRegion(), hasBitmapBeenTotallyChanged(), hasBitmapBeenUpdated(), resetBitmapUpdates(), and setBitmapUpdated().
| uint32 cmlabs::Bitmap::width |
Width in pixels.
Definition at line 248 of file Bitmap.h.
Referenced by Bitmap(), Bitmap(), Bitmap(), canBeResizedTo(), convertBitmapFileData(), convertBitmapFileDataRunLength(), copyDataFromBitmap(), copyGrayScaleData(), createResizedData(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToBitmapFileFormat(), DataToEncodingFormat(), differenceBitmapFileData(), differenceBitmapFileDataRunLength(), drawBitmap(), drawBitmap(), eraseBitmap(), fillBox(), getDPos(), getGrayScaleDataCopy(), getPixel(), getPixelColor(), getPos(), getResizedCopy(), getResizedCopy(), getXY(), init(), init(), cmlabs::Internal_BitmapPoster(), mirror(), operator-(), putTransPixel(), readFromMemory(), replaceColor(), runLengthDestructiveEncode(), runLengthEncode(), setBitmapUpdated(), cmlabs::BitmapUpdate::setFullUpdate(), setPixel(), setPixelXOR(), takeDataFromBitmap(), toBitmapFileFormat(), toMessage(), UnitTest(), and updateBitmap().