class for reading RAW files
More...
#include <lti_rawImageReader.h>
|
LT_STATUS | initialize (LTIOStreamInf *stream, const LTIPixel &pixelProps, lt_uint32 width, lt_uint32 height, bool useWorldFile=true) |
| initialize (stream) More...
|
|
LT_STATUS | initialize (const LTFileSpec &fileSpec, const LTIPixel &pixelProps, lt_uint32 width, lt_uint32 height, bool useWorldFile=true) |
| initialize (FileSpec) More...
|
|
LT_STATUS | initialize (const char *file, const LTIPixel &pixelProps, lt_uint32 width, lt_uint32 height, bool useWorldFile=true) |
| initialize (char*) More...
|
|
|
These must be called prior to calling initialize(), unlike most other SDK objects.
|
void | setStreamOwnership (bool takeOwnership) |
| set stream ownership More...
|
|
void | setRowBytes (lt_uint32 rowBytes) |
| sets the number of bytes in each row More...
|
|
void | setLayout (LTILayout layout) |
| sets the layout or organization of the raw data More...
|
|
void | setSkipBytes (lt_int64 leadingBytes, lt_int64 trailingBytes=0) |
| sets the number of bytes to skip at the beginning and end of the file More...
|
|
void | setByteOrder (LTIEndian byteOrder) |
| sets endianness of input file More...
|
|
LT_STATUS | getDimsAtMag (double mag, lt_uint32 &width, lt_uint32 &height) const |
|
virtual LTIMaskSource * | getMask () const |
|
virtual bool | getPipelineInfo (LTIPipelineInfo info) const |
|
lt_int64 | getEncodingCost (const LTIScene &scene) const |
|
bool | getReaderScene (const LTIScene &decodeScene, LTIScene &readerScene) const |
|
virtual lt_uint32 | getModifications (const LTIScene &scene) const |
|
LT_STATUS | readBegin (const LTIPixel &pixelProps, const LTIScene &fullScene) |
|
LT_STATUS | readStrip (LTISceneBuffer &buffer, const LTIScene &stripScene) |
|
LT_STATUS | readEnd (void) |
|
This class reads a RAW image.
The RAW format used is simple packed BIP form.
- Examples:
- Pipeline.cpp.
Definition at line 30 of file lti_rawImageReader.h.
LTIRawImageReader::LTIRawImageReader |
( |
void |
| ) |
|
|
protected |
virtual LTIRawImageReader::~LTIRawImageReader |
( |
void |
| ) |
|
|
protectedvirtual |
LT_STATUS LTIRawImageReader::decodeEnd |
( |
void |
| ) |
|
|
protected |
const char* LTIRawImageReader::getSourceName |
( |
void |
| ) |
const |
|
protectedvirtual |
This function constructs an LTIImageReader using the data in the stream with the image properties specified. The input taken from a stream.
- Parameters
-
stream | stream containing the RAW image data (may not be NULL) |
pixelProps | the pixel properties of the image (colorspace, datatype, etc) |
width | the width of the image |
height | the height of the image |
useWorldFile | use world file information if available |
- Examples:
- Pipeline.cpp.
This function constructs an LTIImageReader using the data in the stream with the image properties specified. The input taken from a stream, and the background and nodata pixels may be specified.
- Parameters
-
fileSpec | file containing the RAW image data |
pixelProps | the pixel properties of the image (colorspace, datatype, etc) |
width | the width of the image |
height | the height of the image |
useWorldFile | use world file information if available |
This function constructs an LTIImageReader using the data in the stream with the image properties specified. The input taken from a stream, and the background and nodata pixels may be specified.
- Parameters
-
file | file containing the RAW image data (may not be NULL) |
pixelProps | the pixel properties of the image (colorspace, datatype, etc) |
width | the width of the image |
height | the height of the image |
useWorldFile | use world file information if available |
void LTIRawImageReader::setByteOrder |
( |
LTIEndian |
byteOrder | ) |
|
Sets the byte order or endianness of the input file.
- Note
- This must be called prior to calling initialize().
- Parameters
-
byteOrder | the endian setting to use |
void LTIRawImageReader::setLayout |
( |
LTILayout |
layout | ) |
|
Sets the layout or organization of the raw data.
If not set, the default is BIP format.
- Note
- This must be called prior to calling initialize().
- Parameters
-
layout | the layout of the raw data |
void LTIRawImageReader::setRowBytes |
( |
lt_uint32 |
rowBytes | ) |
|
Sets the number of bytes in each row.
If not set, the bytes per row is simply the number of data items per row times the size of a data item. (Note that a "data item" in this case may be either a pixel or a sample, depending on the layout being used.)
- Note
- This must be called prior to calling initialize().
- Parameters
-
rowBytes | the number of bytes per row |
void LTIRawImageReader::setSkipBytes |
( |
lt_int64 |
leadingBytes, |
|
|
lt_int64 |
trailingBytes = 0 |
|
) |
| |
Sets the number of bytes to skip at the beginning of the file and the end of the file. (The "ending skip bytes" property is sometimes required because LTIRawImageReader::initialize() does a sanity check to make sure the number of data bytes in the file is equal to the number of bytes needed for the given width, height, etc.
- Note
- This must be called prior to calling initialize().
- Parameters
-
leadingBytes | the number of bytes to skip at the top |
trailingBytes | the number of bytes to skip at the bottom |
void LTIRawImageReader::setStreamOwnership |
( |
bool |
takeOwnership | ) |
|
Sets the ownership of the stream, to indicate responsibility for deleting the stream when done. This only pertains to objects which were passed a stream in the ctor.
If not set, the default is for the object to not take ownership of the stream.
- Note
- This must be called prior to calling initialize().
- Parameters
-
takeOwnership | set to true to have the reader delete the stream |
The documentation for this class was generated from the following file: