24 #ifdef OSSIM_ID_ENABLED 25 static const char OSSIM_ID[] =
"$Id";
28 static ossimTrace traceDebug(
"ossimOpjNitfReader:debug");
138 if (static_cast<ossim_uint8>(c) != 0xff)
143 if (static_cast<ossim_uint8>(c) != 0x4f)
157 if (static_cast<ossim_uint8>(c) == 0xff)
163 if (static_cast<ossim_uint8>(c) == 0x90)
168 else if (static_cast<ossim_uint8>(c) == 0x93)
191 <<
"\nBlock offset count wrong!" 192 <<
"\nblocks: " << total_blocks
205 <<
"\nBlock size count wrong!" 206 <<
"\nblocks: " << total_blocks
225 <<
"ossimNitfTileSource::uncompressJpegBlock DEBUG:" 226 <<
"\nblockNumber: " << blockNumber
251 <<
"ossimNitfTileSource::loadBlock Read Error!" 252 <<
"\nReturning error..." << endl;
254 delete [] compressedBuf;
267 << e.
what() << std::endl;
274 delete [] compressedBuf;
virtual void initializeReadMode()
Initializes the data member "theReadMode" from the current entry.
ossimOpjNitfReader()
default construtor
std::shared_ptr< ossim::istream > theFileStr
std::vector< ossim_uint32 > theNitfBlockSize
virtual void initializeCompressedBuf()
Initializes the data member theCompressedBuf.
static const ossimErrorCode OSSIM_ERROR
unsigned short ossim_uint16
std::vector< ossim_uint8 > theCompressedBuf
IMODE = B, IC = C3 "JPEG compressed blocks".
virtual const char * what() const
Returns the error message.
unsigned int ossim_uint32
virtual void close()
Closes file and destroys all memory allocated.
virtual bool scanForJpegBlockOffsets()
scans the file storing in offsets in "theNitfBlockOffset" and block sizes in "theNitfBlockSize".
virtual bool canUncompress(const ossimNitfImageHeader *hdr) const
const ossimNitfImageHeader * getCurrentImageHeader() const
ossimErrorCode theErrorStatus
virtual bool uncompressJpegBlock(ossim_uint32 x, ossim_uint32 y)
Uncompresses a jpeg block using the jpeg-6b library.
ossim_uint32 getBlockNumber(const ossimIpt &block_origin) const
RTTI_DEF1_INST(ossimOpjNitfReader, "ossimOpjNitfReader", ossimNitfTileSource) ossimOpjNitfReader
virtual ~ossimOpjNitfReader()
virtural destructor
unsigned char ossim_uint8
std::vector< std::streamoff > theNitfBlockOffset
OSSIMDLLEXPORT std::ostream & ossimNotify(ossimNotifyLevel level=ossimNotifyLevel_WARN)