OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
ossimRpfCompressionSectionSubheader Class Reference

#include <ossimRpfCompressionSectionSubheader.h>

Public Member Functions

 ossimRpfCompressionSectionSubheader ()
 
virtual ~ossimRpfCompressionSectionSubheader ()
 
ossimErrorCode parseStream (ossim::istream &in, ossimByteOrder byteOrder)
 
unsigned long getStartOffset () const
 
unsigned long getEndOffset () const
 
unsigned short getCompressionAlgorithmId () const
 
unsigned short getNumberOfCompressionLookupOffsetRecords () const
 
unsigned short getNumberOfCompressionParameterOffsetRecords () const
 
void print (std::ostream &out) const
 

Private Member Functions

void clearFields ()
 

Private Attributes

unsigned long theStartOffset
 
unsigned long theEndOffset
 
unsigned short theCompressionAlgorithmId
 
unsigned short theNumberOfCompressionLookupOffsetRecords
 
unsigned short theNumberOfCompressionParameterOffsetRecords
 

Friends

std::ostream & operator<< (std::ostream &out, const ossimRpfCompressionSectionSubheader &data)
 

Detailed Description

Definition at line 8 of file ossimRpfCompressionSectionSubheader.h.

Constructor & Destructor Documentation

◆ ossimRpfCompressionSectionSubheader()

ossimRpfCompressionSectionSubheader::ossimRpfCompressionSectionSubheader ( )

◆ ~ossimRpfCompressionSectionSubheader()

virtual ossimRpfCompressionSectionSubheader::~ossimRpfCompressionSectionSubheader ( )
inlinevirtual

Definition at line 14 of file ossimRpfCompressionSectionSubheader.h.

14 {}

Member Function Documentation

◆ clearFields()

void ossimRpfCompressionSectionSubheader::clearFields ( )
private

◆ getCompressionAlgorithmId()

unsigned short ossimRpfCompressionSectionSubheader::getCompressionAlgorithmId ( ) const
inline

◆ getEndOffset()

unsigned long ossimRpfCompressionSectionSubheader::getEndOffset ( ) const
inline

◆ getNumberOfCompressionLookupOffsetRecords()

unsigned short ossimRpfCompressionSectionSubheader::getNumberOfCompressionLookupOffsetRecords ( ) const
inline

◆ getNumberOfCompressionParameterOffsetRecords()

unsigned short ossimRpfCompressionSectionSubheader::getNumberOfCompressionParameterOffsetRecords ( ) const
inline

◆ getStartOffset()

unsigned long ossimRpfCompressionSectionSubheader::getStartOffset ( ) const
inline

◆ parseStream()

ossimErrorCode ossimRpfCompressionSectionSubheader::parseStream ( ossim::istream in,
ossimByteOrder  byteOrder 
)

Definition at line 19 of file ossimRpfCompressionSectionSubheader.cpp.

References ossim::byteOrder(), ossimEndian::getSystemEndianType(), ossimErrorCodes::OSSIM_ERROR, ossimErrorCodes::OSSIM_OK, ossimEndian::swap(), theCompressionAlgorithmId, theEndOffset, theNumberOfCompressionLookupOffsetRecords, theNumberOfCompressionParameterOffsetRecords, and theStartOffset.

Referenced by ossimRpfHeader::getNewCompressionSectionSubheader(), and ossimRpfCompressionSection::parseStream().

21 {
22  if(in)
23  {
24  theStartOffset = in.tellg();
25 
26  in.read((char*)&theCompressionAlgorithmId, 2);
29 
30  theEndOffset = in.tellg();
31 
32  ossimEndian anEndian;
33 
34  if(anEndian.getSystemEndianType() != byteOrder)
35  {
39  }
40  }
41  else
42  {
44  }
45 
47 }
static const ossimErrorCode OSSIM_OK
OSSIM_DLL ossimByteOrder byteOrder()
Definition: ossimCommon.cpp:54
static const ossimErrorCode OSSIM_ERROR
ossimByteOrder getSystemEndianType() const
Definition: ossimEndian.h:78
void swap(ossim_sint8 &)
Definition: ossimEndian.h:26

◆ print()

void ossimRpfCompressionSectionSubheader::print ( std::ostream &  out) const

Definition at line 49 of file ossimRpfCompressionSectionSubheader.cpp.

References theCompressionAlgorithmId, theNumberOfCompressionLookupOffsetRecords, and theNumberOfCompressionParameterOffsetRecords.

Referenced by operator<<().

50 {
51  out << "theCompressionAlgorithmId: " << theCompressionAlgorithmId
52  << "\ntheNumberOfCompressionLookupOffsetRecords: " << theNumberOfCompressionLookupOffsetRecords
53  << "\ntheNumberOfCompressionParameterOffsetRecords: " << theNumberOfCompressionParameterOffsetRecords;
54 }

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  out,
const ossimRpfCompressionSectionSubheader data 
)
friend

Definition at line 11 of file ossimRpfCompressionSectionSubheader.cpp.

13 {
14  data.print(out);
15 
16  return out;
17 }

Member Data Documentation

◆ theCompressionAlgorithmId

unsigned short ossimRpfCompressionSectionSubheader::theCompressionAlgorithmId
private

Current ids are:

1 VQ 2 Jpeg Lossless

Definition at line 54 of file ossimRpfCompressionSectionSubheader.h.

Referenced by clearFields(), getCompressionAlgorithmId(), parseStream(), and print().

◆ theEndOffset

unsigned long ossimRpfCompressionSectionSubheader::theEndOffset
private

helper varible that holds the starting absolute offset to the end of the this data.

Definition at line 47 of file ossimRpfCompressionSectionSubheader.h.

Referenced by clearFields(), getEndOffset(), and parseStream().

◆ theNumberOfCompressionLookupOffsetRecords

unsigned short ossimRpfCompressionSectionSubheader::theNumberOfCompressionLookupOffsetRecords
private

◆ theNumberOfCompressionParameterOffsetRecords

unsigned short ossimRpfCompressionSectionSubheader::theNumberOfCompressionParameterOffsetRecords
private

◆ theStartOffset

unsigned long ossimRpfCompressionSectionSubheader::theStartOffset
private

helper varible that holds the starting absolute offset to the start of the this data.

Definition at line 41 of file ossimRpfCompressionSectionSubheader.h.

Referenced by clearFields(), getStartOffset(), and parseStream().


The documentation for this class was generated from the following files: