#include <BmpFile.h>
Inheritance diagram for BmpFile:
Public Member Functions | |
BmpFile (void) | |
BmpFile (BinaryIO *io) | |
~BmpFile (void) | |
void | read (BinaryIO *io) |
void | write (void) |
std::list< CvrStgFile::Property > | getProperties (void) const |
std::vector< MatchingAlgorithm * > | getMatchingAlgorithms (Graph *g, Matching *m) const |
unsigned long | getNumSamples (void) const |
void | replaceSample (const SamplePos pos, const SampleValue *s) |
SampleValue * | getSampleValue (SamplePos pos) const |
std::vector< SampleValueAdjacencyList * > | calcSVAdjacencyLists (const std::vector< SampleValue * > &svs) const |
unsigned short | getBitCount (void) const |
unsigned long | getWidth (void) const |
unsigned long | getHeight (void) const |
ColorPalette * | getPalette (void) const |
Protected Types | |
typedef BmpFile::struct_BITMAPFILEHEADER | BITMAPFILEHEADER |
typedef BmpFile::struct_BITMAPINFOHEADER | BITMAPINFOHEADER |
typedef BmpFile::struct_BITMAPCOREHEADER | BITMAPCOREHEADER |
Private Types | |
enum | SUBFORMAT { WIN, OS2 } |
Private Member Functions | |
void | readheaders () |
void | bmpwin_readheaders () |
void | bmpos2_readheaders () |
void | writeheaders () |
void | bmpwin_writeheaders () |
void | bmpos2_writeheaders () |
void | readdata () |
void | writedata () |
void | calcIndex (SamplePos pos, unsigned long *index, unsigned short *firstbit) const |
unsigned long | calcLinelength () |
SUBFORMAT | getSubformat (void) const |
Private Attributes | |
SUBFORMAT | subformat |
BITMAPFILEHEADER | bmfh |
BITMAPINFOHEADER | bmih |
BITMAPCOREHEADER | bmch |
ColorPalette * | Palette |
std::vector< std::vector< unsigned char > > | bitmap |
std::vector< BYTE > | BitmapData |
std::vector< BYTE > | atend |
contains bytes that are appended at the end of the bitmap data (some image editors apparently do this) | |
Static Private Attributes | |
const unsigned int | IdBm = 19778 |
const unsigned short | SizeBMFILEHEADER = 14 |
const unsigned short | SizeBMINFOHEADER = 40 |
const unsigned short | SizeBMCOREHEADER = 12 |
const unsigned int | COMPRESSION_BI_RGB = 0 |
const unsigned short | SamplesPerVertex_SmallPalette = 2 |
const unsigned short | SamplesPerVertex_LargePalette = 3 |
const unsigned short | SamplesPerVertex_RGB = 2 |
const UWORD32 | Radius_Palette = 400 |
the default radius for palette images (400 = 20^2) | |
const UWORD32 | Radius_RGB = 100 |
the default radius for RGB images (100 = 10^2) | |
const EmbValue | EmbValueModulus_SmallPalette = 2 |
const EmbValue | EmbValueModulus_LargePalette = 4 |
const EmbValue | EmbValueModulus_RGB = 4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
translate a sample position into a <index,firstbit> pair "pointing" into the BitmapData array
|
|
|
|
calculate a vector a SampleValueAdjacencyLists
May be overridden in derived class to provide a faster version. Reimplemented from CvrStgFile. |
|
|
|
|
|
get recommended list of matching algorithms
Reimplemented from CvrStgFile. |
|
get the number of samples in this CvrStgObject Implements CvrStgObject. |
|
|
|
Implements CvrStgFile. |
|
get the sample at position pos
Implements CvrStgObject. |
|
|
|
|
|
Reimplemented from CvrStgFile. |
|
|
|
|
|
replace a sample thus (possibly) altering the value of the bit returned by SampleValue->getBit()
Implements CvrStgObject. |
|
Reimplemented from CvrStgFile. |
|
|
|
|
|
|
|
contains the bitmap in the following format bitmap[i] is the pixel data of the i-th row of the bitmap bitmap[i][j] is the j-th byte of the pixel data of the i-th row of the bitmap if bitcount is < 8 then bitmap[i][j] contains the pixels as read in from the file (i.e. in the "wrong" direction) this is taken care of in the calcRCB function |
|
contains the bitmap data in the same order as read from file (but without padding bytes) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|