Public Member Functions | |
Rep (const std::string &fname_) | |
Rep (std::istream &strm_) | |
void | init () |
void | readPixels8 (byte *space, int nvals) |
Read the actual pixels out of the file, for 1-byte-per-value images. | |
void | readPixels16 (uint16 *space, int nvals) |
Read the actual pixels out of the file, for 2-bytes-per-value images. | |
Image< byte > | parseBW () |
Parse a 1-bit black+white raw or ascii image file into an 8-bit image. | |
Image< byte > | parseGrayU8 () |
Parse an 8-bit grayscale image in either raw or ascii mode. | |
Image< uint16 > | parseGrayU16 () |
Parse a 16-bit grayscale image in either raw or ascii mode. | |
Image< PixRGB< byte > > | parseRgbU8 () |
Parse an 8-bit rgb image in either raw or ascii mode. | |
Image< PixRGB< uint16 > > | parseRgbU16 () |
Parse a 16-bit rgb image in either raw or ascii mode. | |
Public Attributes | |
std::string | fname |
rutz::shared_ptr< std::istream > | owned_strm |
std::istream * | strm |
int | mode |
int | w |
int | h |
int | maxGrey |
std::string | comments |
Definition at line 55 of file PnmParser.C.
Parse a 1-bit black+white raw or ascii image file into an 8-bit image.
The underlying file must be a black_white file (mode 1 or 4).
Definition at line 255 of file PnmParser.C.
References ASSERT, Image< T >::beginw(), Image< T >::endw(), and NO_INIT.
Referenced by PnmParser::getFrame().
Parse a 16-bit grayscale image in either raw or ascii mode.
The underlying file must be a grayscale file (mode 2 or 5).
Definition at line 326 of file PnmParser.C.
References ASSERT, Image< T >::getArrayPtr(), Image< T >::getSize(), NO_INIT, and readPixels16().
Referenced by PnmParser::getFrame().
Parse an 8-bit grayscale image in either raw or ascii mode.
The underlying file must be a grayscale file (mode 2 or 5).
Definition at line 316 of file PnmParser.C.
References ASSERT, Image< T >::getArrayPtr(), Image< T >::getSize(), NO_INIT, and readPixels8().
Referenced by PnmParser::getFrame().
Parse a 16-bit rgb image in either raw or ascii mode.
The underlying file must be a RGB file (mode 3 or 6).
Definition at line 346 of file PnmParser.C.
References ASSERT, Image< T >::getArrayPtr(), Image< T >::getSize(), NO_INIT, and readPixels16().
Referenced by PnmParser::getFrame().
Parse an 8-bit rgb image in either raw or ascii mode.
The underlying file must be a RGB file (mode 3 or 6).
Definition at line 336 of file PnmParser.C.
References ASSERT, Image< T >::getArrayPtr(), Image< T >::getSize(), NO_INIT, and readPixels8().
Referenced by PnmParser::getFrame().
void PnmParser::Rep::readPixels16 | ( | uint16 * | space, | |
int | nvals | |||
) |
Read the actual pixels out of the file, for 2-bytes-per-value images.
Definition at line 204 of file PnmParser.C.
References ASSERT.
Referenced by parseGrayU16(), and parseRgbU16().
void PnmParser::Rep::readPixels8 | ( | byte * | space, | |
int | nvals | |||
) |
Read the actual pixels out of the file, for 1-byte-per-value images.
Definition at line 162 of file PnmParser.C.
References ASSERT.
Referenced by parseGrayU8(), and parseRgbU8().