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

for an srtm file. More...

#include <ossimGeneralRasterElevHandler.h>

Inheritance diagram for ossimGeneralRasterElevHandler:
ossimElevCellHandler ossimElevSource ossimSource ossimConnectableObject ossimErrorStatusInterface ossimObject ossimListenerManager ossimPropertyInterface ossimReferenced

Classes

class  GeneralRasterInfo
 

Public Member Functions

 ossimGeneralRasterElevHandler (const ossimFilename &file="")
 
 ossimGeneralRasterElevHandler (const ossimGeneralRasterElevHandler::GeneralRasterInfo &generalRasterInfo)
 
 ossimGeneralRasterElevHandler (const ossimGeneralRasterElevHandler &rhs)
 
virtual ~ossimGeneralRasterElevHandler ()
 destructor More...
 
virtual ossimObjectdup () const
 
virtual double getHeightAboveMSL (const ossimGpt &)
 METHOD: getHeightAboveMSL Height access methods. More...
 
virtual ossimIpt getSizeOfElevCell () const
 METHOD: getSizeOfElevCell Returns the number of post in the cell. More...
 
virtual double getPostValue (const ossimIpt &gridPt) const
 METHOD: getPostValue Returns the value at a given grid point as a double. More...
 
virtual bool isOpen () const
 
bool open (const ossimFilename &file, bool memoryMapFlag=false)
 Opens a stream to the srtm cell. More...
 
virtual void close ()
 Closes the stream to the file. More...
 
ossimDrect getBoundingRect () const
 This method does not really fit the handler since this handle a directory not a cell that could have holes in it. More...
 
virtual bool pointHasCoverage (const ossimGpt &gpt) const
 Loops through ossimGeneralRasterElevHandler::BoundingRectListType and checks for coverage. More...
 
const ossimGeneralRasterElevHandler::GeneralRasterInfogeneralRasterInfo () const
 
- Public Member Functions inherited from ossimElevCellHandler
 ossimElevCellHandler (const char *elev_filename)
 Constructors: More...
 
 ossimElevCellHandler (const ossimElevCellHandler &src)
 
virtual const ossimFilenamegetFilename () const
 
virtual double getMeanSpacingMeters () const
 METHOD: meanSpacingMeters() Implements pure virtual for. More...
 
virtual bool getAccuracyInfo (ossimElevationAccuracyInfo &info, const ossimGpt &gpt) const
 
bool canConnectMyInputTo (ossim_int32 inputIndex, const ossimConnectableObject *object) const
 METHODS: accuracyLE90(), accuracyCE90() Returns the vertical and horizontal accuracy (90% confidence): More...
 
virtual std::ostream & print (std::ostream &out) const
 Outputs theErrorStatus as an ossimErrorCode and an ossimString. More...
 
- Public Member Functions inherited from ossimElevSource
virtual double getHeightAboveEllipsoid (const ossimGpt &)
 
bool intersectRay (const ossimEcefRay &ray, ossimGpt &gpt, double defaultElevValue=0.0)
 METHOD: intersectRay() More...
 
virtual double getMinHeightAboveMSL () const
 Access methods for the bounding elevations: More...
 
virtual double getMaxHeightAboveMSL () const
 
double getNullHeightValue () const
 Special numeric quantities as defined by this source: More...
 
double getSeaLevelValue () const
 
virtual const ossimGrectgetBoundingGndRect () const
 METHODS: accuracyLE90(), accuracyCE90() Returns the vertical and horizontal accuracy (90% confidence) in the region of gpt: More...
 
virtual void initialize ()
 Implement ossimSource base-class pure virtuals: More...
 
virtual bool getComputeStatisticsFlag () const
 Opens a stream to an elevation cell. More...
 
virtual void setComputeStatisticsFlag (bool flag)
 Sets the flag which controls whether or not statistics will be computed upon opening a cell and not finding a corresponding statistics file. More...
 
- Public Member Functions inherited from ossimSource
 ossimSource (ossimObject *owner=0)
 
 ossimSource (ossimObject *owner, ossim_uint32 inputListSize, ossim_uint32 outputListSize, bool inputListIsFixedFlag=true, bool outputListIsFixedFlag=true)
 
virtual ~ossimSource ()
 
virtual bool isSourceEnabled () const
 
virtual void enableSource ()
 
virtual void disableSource ()
 
virtual bool getEnableFlag () const
 
virtual void setEnableFlag (bool flag)
 
virtual bool isInitialized () const
 
virtual void setInitializedFlag (bool flag)
 
virtual void setProperty (ossimRefPtr< ossimProperty > property)
 
virtual ossimRefPtr< ossimPropertygetProperty (const ossimString &name) const
 
virtual void getPropertyNames (std::vector< ossimString > &propertyNames) const
 
virtual bool saveState (ossimKeywordlist &kwl, const char *prefix=0) const
 
virtual bool loadState (const ossimKeywordlist &kwl, const char *prefix=0)
 
- Public Member Functions inherited from ossimConnectableObject
 ossimConnectableObject (ossimObject *owner=0)
 Base constructor of this object. More...
 
 ossimConnectableObject (ossimObject *owner, ossim_int32 inputListSize, ossim_int32 outputListSize, bool inputListIsFixedFlag=true, bool outputListIsFixedFlag=true)
 
virtual ~ossimConnectableObject ()
 
void setId (const ossimId &id)
 All connectable objects will have id's. More...
 
const ossimIdgetId () const
 Will allow us to get this object's id. More...
 
const ossimObjectgetOwner () const
 Fetches the current owner, most likely a container but not limited to one. More...
 
virtual void changeOwner (ossimObject *owner)
 Permits changing the object's owner. More...
 
virtual void setDescription (const ossimString &description)
 
virtual ossimString getDescription () const
 
virtual bool isConnected (ossimConnectableObjectDirectionType direction=CONNECTABLE_DIRECTION_INPUT) const
 will check the direction specified to see if all slots are full. More...
 
 OSSIM_DEPRECATE_METHOD (virtual ossimConnectableObject *findConnectableObject(const ossimId &id))
 
 OSSIM_DEPRECATE_METHOD (virtual ossimConnectableObject *findObjectOfType(RTTItypeid typeId, ossimConnectableObjectDirectionType directionType, bool recurse=true))
 
 OSSIM_DEPRECATE_METHOD (virtual ossimConnectableObject *findObjectOfType(const ossimString &obj, ossimConnectableObjectDirectionType directionType, bool recurse=true))
 
 OSSIM_DEPRECATE_METHOD (virtual ossimConnectableObject *findInputObjectOfType(const ossimString &className))
 
virtual ossim_int32 findInputIndex (const ossimConnectableObject *object)
 Return a valid index of the input list if the passed in object is found else return -1. More...
 
virtual ossim_int32 findInputIndex (const ossimId &id)
 Return a valid index of the input list if the passed id is found else return -1. More...
 
virtual ossim_int32 findOutputIndex (const ossimConnectableObject *object)
 Return a valid index of the output list if the passed in object is found else return -1. More...
 
virtual ossim_int32 findOutputIndex (const ossimId &id)
 Return a valid index of the output list if the passed in object is found else return -1. More...
 
virtual ossim_int32 getMyInputIndexToConnectTo (ossimConnectableObject *object) const
 Should return the first available index to connect to. More...
 
virtual ossim_int32 getMyOutputIndexToConnectTo (ossimConnectableObject *object) const
 Should return the first available index to connect to. More...
 
virtual bool canConnectMyOutputTo (ossim_int32 myOutputIndex, const ossimConnectableObject *object) const
 default implementation is to allow anyone to connect to us. More...
 
virtual void disconnect (ossimConnectableObject *object=0)
 Will disconnect the object passed in. More...
 
virtual void disconnect (const ossimId &id)
 Will disconnect the object passed in. More...
 
virtual ossimRefPtr< ossimConnectableObjectdisconnectMyInput (ossim_int32 inputIndex, bool disconnectOutputFlag=true, bool createEventFlag=true)
 Will disconnect the object at the given input index and generate a connection event. More...
 
virtual void disconnectMyInput (ossimConnectableObject *input, bool disconnectOutputFlag=true, bool createEventFlag=true)
 Finds the index of the passed in input and calls disconnectMyInput(inputIndex, disconnectOutputFlag, createEventFlag);. More...
 
virtual void disconnectMyInputs (ConnectableObjectList &inputList, bool disconnectOutputFlag=true, bool createEventFlag=true)
 
virtual ossimRefPtr< ossimConnectableObjectdisconnectMyOutput (ossim_int32 outputIndex, bool disconnectInputFlag=true, bool createEventFlag=true)
 Will disconnect the object at the given output index and generate a connection event. More...
 
virtual void disconnectMyOutput (ossimConnectableObject *output, bool disconnectInputFlag=true, bool createEventFlag=true)
 Will disconnect the output object. More...
 
virtual void disconnectMyOutputs (ConnectableObjectList &outputList, bool disconnectOutputFlag=true, bool createEventFlag=true)
 
virtual void disconnectAllInputs ()
 Will disconnect all of the input objects. More...
 
virtual void disconnectAllOutputs ()
 Will disconnect all of the output objects. More...
 
virtual ossim_int32 connectMyInputTo (ossimConnectableObject *inputObject, bool makeOutputConnection=true, bool createEventFlag=true)
 Will try to connect this objects input to the passed in object. More...
 
virtual ossim_int32 connectMyInputTo (ossim_int32 inputIndex, ossimConnectableObject *inputObject, bool makeOutputConnection=true, bool createEventFlag=true)
 Will connect the specified input to the passed in object. More...
 
virtual bool connectMyInputTo (ConnectableObjectList &inputList, bool makeOutputConnection=true, bool createEventFlag=true)
 
virtual ossim_int32 connectMyOutputTo (ossimConnectableObject *outputObject, bool makeInputConnection=true, bool createEventFlag=true)
 Will try to connect this objects output to the passed in object. More...
 
virtual bool connectMyOutputTo (ConnectableObjectList &outputList, bool makeInputConnection=true, bool createEventFlag=true)
 
virtual bool connectInputList (ConnectableObjectList &inputList)
 Will disconnect itself from all inputs and reset to the passed in input list. More...
 
virtual bool connectOutputList (ConnectableObjectList &outputList)
 Will disconnect itself from all outputs and reset to the passed in output list. More...
 
virtual ossim_uint32 getNumberOfInputs () const
 Returns the number of input objects. More...
 
virtual ossim_uint32 getNumberOfOutputs () const
 Return the number of output objects. More...
 
ossimConnectableObjectgetInput (ossim_uint32 index=0)
 returns the object at the specified index. More...
 
const ossimConnectableObjectgetInput (ossim_uint32 index=0) const
 returns the object at the specified index. More...
 
ossimConnectableObjectgetOutput (ossim_uint32 index=0)
 returns the object at the specified index. More...
 
const ossimConnectableObjectgetOutput (ossim_uint32 index=0) const
 returns the object at the specified index. More...
 
virtual void setNumberOfInputs (ossim_int32 numberOfInputs)
 Will set the number of inputs. More...
 
virtual bool getInputListIsFixedFlag () const
 
virtual bool getOutputListIsFixedFlag () const
 
virtual void setNumberOfOutputs (ossim_int32 numberOfInputs)
 Will set the number of outputs. More...
 
const ConnectableObjectListgetInputList () const
 
const ConnectableObjectListgetOutputList () const
 
ConnectableObjectListgetInputList ()
 
ConnectableObjectListgetOutputList ()
 
 OSSIM_DEPRECATE_METHOD (virtual void findAllObjectsOfType(ConnectableObjectList &result, const RTTItypeid &typeInfo, bool recurse=true))
 
 OSSIM_DEPRECATE_METHOD (virtual void findAllObjectsOfType(ConnectableObjectList &result, const ossimString &className, bool recurse=true))
 
virtual void propagateEventToOutputs (ossimEvent &event)
 
virtual void propagateEventToInputs (ossimEvent &event)
 
virtual void setProperty (const ossimString &name, const ossimString &value)
 
virtual ossim_uint32 saveStateOfAllInputs (ossimKeywordlist &kwl, bool saveThisStateFlag=true, ossim_uint32 objectIndex=1, const char *prefix=0) const
 Save the state of all inputs to a keyword list. More...
 
virtual bool fillContainer (ossimConnectableContainer &container)
 Inserts this object and all of its children and inputs into the container provided. More...
 
bool moveInputUp (const ossimId &id)
 Moves the input connection matching id up one in the connection list. More...
 
bool moveInputDown (const ossimId &id)
 Moves the input connection matching id down one in the connection list. More...
 
bool moveInputToTop (const ossimId &id)
 Moves the input connection matching id to the top of the connection list. More...
 
bool moveInputToBottom (const ossimId &id)
 Moves the input connection matching id to the bottom of the connection list. More...
 
virtual void accept (ossimVisitor &visitor)
 We will add a visitor interface for all connectable objects. More...
 
- Public Member Functions inherited from ossimObject
 ossimObject ()
 
virtual ~ossimObject ()
 
virtual ossimString getShortName () const
 
virtual ossimString getLongName () const
 
virtual ossimString getClassName () const
 
virtual RTTItypeid getType () const
 
virtual bool canCastTo (ossimObject *obj) const
 
virtual bool canCastTo (const RTTItypeid &id) const
 
virtual bool canCastTo (const ossimString &parentClassName) const
 
virtual bool isEqualTo (const ossimObject &obj, ossimCompareType compareType=OSSIM_COMPARE_FULL) const
 
- Public Member Functions inherited from ossimReferenced
 ossimReferenced ()
 
 ossimReferenced (const ossimReferenced &)
 
ossimReferencedoperator= (const ossimReferenced &)
 
void ref () const
 increment the reference count by one, indicating that this object has another pointer which is referencing it. More...
 
void unref () const
 decrement the reference count by one, indicating that a pointer to this object is referencing it. More...
 
void unref_nodelete () const
 decrement the reference count by one, indicating that a pointer to this object is referencing it. More...
 
int referenceCount () const
 
- Public Member Functions inherited from ossimListenerManager
 ossimListenerManager ()
 
virtual ~ossimListenerManager ()
 
virtual void fireEvent (ossimEvent &event)
 
virtual bool addListener (ossimListener *listener)
 
virtual bool removeListener (ossimListener *listener)
 
virtual bool findListener (ossimListener *listener)
 
- Public Member Functions inherited from ossimPropertyInterface
 ossimPropertyInterface ()
 
virtual ~ossimPropertyInterface ()
 
virtual ossimString getPropertyValueAsString (const ossimString &name) const
 
void getPropertyList (std::vector< ossimRefPtr< ossimProperty > > &propertyList) const
 
void setProperties (std::vector< ossimRefPtr< ossimProperty > > &propertyList)
 
- Public Member Functions inherited from ossimErrorStatusInterface
 ossimErrorStatusInterface ()
 
virtual ~ossimErrorStatusInterface ()
 
virtual ossimErrorCode getErrorStatus () const
 
virtual ossimString getErrorStatusString () const
 
virtual void setErrorStatus (ossimErrorCode error_status) const
 
virtual void setErrorStatus () const
 
virtual void clearErrorStatus () const
 
bool hasError () const
 

Private Member Functions

template<class T >
double getHeightAboveMSLFileTemplate (T dummy, const ossimGeneralRasterElevHandler::GeneralRasterInfo &info, const ossimGpt &gpt)
 
template<class T >
double getHeightAboveMSLMemoryTemplate (T dummy, const ossimGeneralRasterElevHandler::GeneralRasterInfo &info, const ossimGpt &gpt)
 
virtual bool setFilename (const ossimFilename &file)
 

Private Attributes

ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo
 
std::mutex m_inputStreamMutex
 
std::ifstream m_inputStream
 
bool m_streamOpen
 true if stream is open. More...
 
std::vector< char > m_memoryMap
 

Additional Inherited Members

- Public Types inherited from ossimConnectableObject
enum  ossimConnectableObjectDirectionType { CONNECTABLE_DIRECTION_NONE = 0, CONNECTABLE_DIRECTION_INPUT = 1, CONNECTABLE_DIRECTION_OUTPUT = 2 }
 
typedef std::vector< ossimRefPtr< ossimConnectableObject > > ConnectableObjectList
 
- Protected Member Functions inherited from ossimElevCellHandler
 ossimElevCellHandler ()
 
virtual ~ossimElevCellHandler ()
 
- Protected Member Functions inherited from ossimElevSource
virtual ~ossimElevSource ()
 
 ossimElevSource ()
 Constructors/Destructors: More...
 
 ossimElevSource (const ossimElevSource &src)
 
- Protected Member Functions inherited from ossimSource
 ossimSource (const ossimSource &rhs)
 
const ossimSourceoperator= (const ossimSource &rhs)
 
- Protected Member Functions inherited from ossimConnectableObject
ossimConnectableObjectfindObjectOfType (ConnectableObjectList *connectableList, ossimVisitor &visitor)
 
- Protected Member Functions inherited from ossimReferenced
virtual ~ossimReferenced ()
 
- Protected Member Functions inherited from ossimListenerManager
 ossimListenerManager (const ossimListenerManager &rhs)
 
- Protected Attributes inherited from ossimElevCellHandler
ossimFilename theFilename
 Virtual method for reading. More...
 
double theMeanSpacing
 
double theAbsLE90
 
double theAbsCE90
 
- Protected Attributes inherited from ossimElevSource
double theMinHeightAboveMSL
 Data members: More...
 
double theMaxHeightAboveMSL
 
double theNullHeightValue
 
double theSeaLevelValue
 
ossimGrect theGroundRect
 
bool theComputeStatsFlag
 
- Protected Attributes inherited from ossimSource
bool theEnableFlag
 
bool theInitializedFlag
 
- Protected Attributes inherited from ossimConnectableObject
ossimId theId
 
ossimString theDescription
 
ossimObjecttheOwner
 
bool theInputListIsFixedFlag
 Indicates whether the theInputObjectList is fixed. More...
 
bool theOutputListIsFixedFlag
 Indicates whether the theOutputObjectList is fixed. More...
 
ConnectableObjectList theInputObjectList
 Holds a list of input objects. More...
 
ConnectableObjectList theOutputObjectList
 Holds a list of output objects. More...
 
- Protected Attributes inherited from ossimListenerManager
std::list< ossimListener * > theListenerList
 
bool theEnabledFlag
 
std::list< ossimListener * > theDelayedAdd
 
std::list< ossimListener * > theDelayedRemove
 
bool theFireEventFlag
 
- Protected Attributes inherited from ossimErrorStatusInterface
ossimErrorCode theErrorStatus
 

Detailed Description

for an srtm file.

Definition at line 37 of file ossimGeneralRasterElevHandler.h.

Constructor & Destructor Documentation

◆ ossimGeneralRasterElevHandler() [1/3]

ossimGeneralRasterElevHandler::ossimGeneralRasterElevHandler ( const ossimFilename file = "")

Definition at line 18 of file ossimGeneralRasterElevHandler.cpp.

References open(), and ossimErrorStatusInterface::setErrorStatus().

19  :ossimElevCellHandler(file.c_str()),
20  m_streamOpen(false)
21 {
22  if(!open(file))
23  {
25  }
26 }
bool open(const ossimFilename &file, bool memoryMapFlag=false)
Opens a stream to the srtm cell.
bool m_streamOpen
true if stream is open.
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396

◆ ossimGeneralRasterElevHandler() [2/3]

ossimGeneralRasterElevHandler::ossimGeneralRasterElevHandler ( const ossimGeneralRasterElevHandler::GeneralRasterInfo generalRasterInfo)

Definition at line 36 of file ossimGeneralRasterElevHandler.cpp.

References close(), generalRasterInfo(), open(), ossimErrorCodes::OSSIM_ERROR, ossimErrorStatusInterface::theErrorStatus, ossimGeneralRasterElevHandler::GeneralRasterInfo::theFilename, and theGeneralRasterInfo.

37  : m_streamOpen(false)
38 {
39 
40  close();
43  {
45  }
46 }
bool open(const ossimFilename &file, bool memoryMapFlag=false)
Opens a stream to the srtm cell.
static const ossimErrorCode OSSIM_ERROR
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo
bool m_streamOpen
true if stream is open.
const ossimGeneralRasterElevHandler::GeneralRasterInfo & generalRasterInfo() const
virtual void close()
Closes the stream to the file.

◆ ossimGeneralRasterElevHandler() [3/3]

ossimGeneralRasterElevHandler::ossimGeneralRasterElevHandler ( const ossimGeneralRasterElevHandler rhs)

Definition at line 28 of file ossimGeneralRasterElevHandler.cpp.

30  theGeneralRasterInfo(src.theGeneralRasterInfo),
31  m_streamOpen(false), // ????
32  m_memoryMap(src.m_memoryMap)
33 {
34 }
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo
bool m_streamOpen
true if stream is open.

◆ ~ossimGeneralRasterElevHandler()

ossimGeneralRasterElevHandler::~ossimGeneralRasterElevHandler ( )
virtual

destructor

Definition at line 48 of file ossimGeneralRasterElevHandler.cpp.

49 {
50 }

Member Function Documentation

◆ close()

void ossimGeneralRasterElevHandler::close ( )
virtual

Closes the stream to the file.

Reimplemented from ossimElevCellHandler.

Definition at line 245 of file ossimGeneralRasterElevHandler.cpp.

References m_inputStream, m_memoryMap, and m_streamOpen.

Referenced by open(), and ossimGeneralRasterElevHandler().

246 {
247  m_inputStream.close();
248  m_memoryMap.clear();
249  m_streamOpen = false;
250 }
bool m_streamOpen
true if stream is open.

◆ dup()

virtual ossimObject* ossimGeneralRasterElevHandler::dup ( ) const
inlinevirtual

Implements ossimElevSource.

Definition at line 90 of file ossimGeneralRasterElevHandler.h.

90 { return new ossimGeneralRasterElevHandler(this->theFilename); }
ossimFilename theFilename
Virtual method for reading.
ossimGeneralRasterElevHandler(const ossimFilename &file="")

◆ generalRasterInfo()

const ossimGeneralRasterElevHandler::GeneralRasterInfo & ossimGeneralRasterElevHandler::generalRasterInfo ( ) const

Definition at line 721 of file ossimGeneralRasterElevHandler.cpp.

References theGeneralRasterInfo.

Referenced by ossimGeneralRasterElevHandler(), and ossimGeneralRasterElevFactory::setDirectory().

722 {
723  return theGeneralRasterInfo;
724 }
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo

◆ getBoundingRect()

ossimDrect ossimGeneralRasterElevHandler::getBoundingRect ( ) const

This method does not really fit the handler since this handle a directory not a cell that could have holes in it.

So users looking for valid coverage should call "pointHasCoverage".

Definition at line 700 of file ossimGeneralRasterElevHandler.cpp.

References theGeneralRasterInfo, and ossimGeneralRasterElevHandler::GeneralRasterInfo::theWgs84GroundRect.

701 {
703 }
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo

◆ getHeightAboveMSL()

double ossimGeneralRasterElevHandler::getHeightAboveMSL ( const ossimGpt gpt)
virtual

METHOD: getHeightAboveMSL Height access methods.

Implements ossimElevSource.

Definition at line 52 of file ossimGeneralRasterElevHandler.cpp.

References getHeightAboveMSLFileTemplate(), getHeightAboveMSLMemoryTemplate(), m_memoryMap, OSSIM_FLOAT32, OSSIM_FLOAT64, OSSIM_SINT16, OSSIM_SINT32, OSSIM_SINT8, OSSIM_UINT16, OSSIM_UINT32, OSSIM_UINT8, theGeneralRasterInfo, ossimGeneralRasterElevHandler::GeneralRasterInfo::theNullHeightValue, and ossimGeneralRasterElevHandler::GeneralRasterInfo::theScalarType.

53 {
55 
56  if(m_memoryMap.empty())
57  {
59  {
60  case OSSIM_SINT8:
61  {
64  gpt);
65  break;
66  }
67  case OSSIM_UINT8:
68  {
71  gpt);
72  break;
73  }
74  case OSSIM_SINT16:
75  {
78  gpt);
79  break;
80  }
81  case OSSIM_UINT16:
82  {
85  gpt);
86  break;
87  }
88  case OSSIM_SINT32:
89  {
92  gpt);
93  break;
94  }
95  case OSSIM_UINT32:
96  {
99  gpt);
100  break;
101  }
102  case OSSIM_FLOAT32:
103  {
106  gpt);
107  break;
108  }
109  case OSSIM_FLOAT64:
110  {
113  gpt);
114  break;
115  }
116  default:
117  {
118  break;
119  }
120  }
121  }
122  else
123  {
125  {
126  case OSSIM_SINT8:
127  {
130  gpt);
131  break;
132  }
133  case OSSIM_UINT8:
134  {
137  gpt);
138  break;
139  }
140  case OSSIM_SINT16:
141  {
144  gpt);
145  break;
146  }
147  case OSSIM_UINT16:
148  {
151  gpt);
152  break;
153  }
154  case OSSIM_SINT32:
155  {
158  gpt);
159  break;
160  }
161  case OSSIM_UINT32:
162  {
165  gpt);
166  break;
167  }
168  case OSSIM_FLOAT32:
169  {
172  gpt);
173  break;
174  }
175  case OSSIM_FLOAT64:
176  {
179  gpt);
180  break;
181  }
182  default:
183  {
184  break;
185  }
186  }
187 
188  }
189 
190  return result;
191 }
double getHeightAboveMSLFileTemplate(T dummy, const ossimGeneralRasterElevHandler::GeneralRasterInfo &info, const ossimGpt &gpt)
8 bit signed integer
64 bit floating point
16 bit unsigned integer
float ossim_float32
16 bit signed integer
signed char ossim_sint8
32 bit floating point
unsigned short ossim_uint16
32 bit unsigned integer
double getHeightAboveMSLMemoryTemplate(T dummy, const ossimGeneralRasterElevHandler::GeneralRasterInfo &info, const ossimGpt &gpt)
double ossim_float64
signed short ossim_sint16
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo
32 bit signed integer
unsigned int ossim_uint32
signed int ossim_sint32
8 bit unsigned integer
unsigned char ossim_uint8

◆ getHeightAboveMSLFileTemplate()

template<class T >
double ossimGeneralRasterElevHandler::getHeightAboveMSLFileTemplate ( dummy,
const ossimGeneralRasterElevHandler::GeneralRasterInfo info,
const ossimGpt gpt 
)
private

Definition at line 427 of file ossimGeneralRasterElevHandler.cpp.

References ossimGpt::changeDatum(), ossimEndian::getSystemEndianType(), m_inputStream, m_inputStreamMutex, ossim::nan(), ossimDrect::pointWithin(), ossimEndian::swap(), ossimGeneralRasterElevHandler::GeneralRasterInfo::theByteOrder, ossimGeneralRasterElevHandler::GeneralRasterInfo::theBytesPerRawLine, ossimGeneralRasterElevHandler::GeneralRasterInfo::theDatum, ossimGeneralRasterElevHandler::GeneralRasterInfo::theGeometry, ossimGeneralRasterElevHandler::GeneralRasterInfo::theHeight, ossimGeneralRasterElevHandler::GeneralRasterInfo::theNullHeightValue, ossimGeneralRasterElevHandler::GeneralRasterInfo::theUl, ossimGeneralRasterElevHandler::GeneralRasterInfo::theWgs84GroundRect, ossimGeneralRasterElevHandler::GeneralRasterInfo::theWidth, ossimImageGeometry::worldToLocal(), ossimIpt::x, ossimDpt::x, ossimIpt::y, and ossimDpt::y.

Referenced by getHeightAboveMSL().

431 {
432  ossimEndian endian;
433 
434  ossimGpt shiftedPoint = gpt;
435  shiftedPoint.changeDatum(info.theDatum);
436  if(!info.theWgs84GroundRect.pointWithin(shiftedPoint))
437  {
438  return ossim::nan();
439  }
440 
441  ossimDpt pt;
442  info.theGeometry->worldToLocal(shiftedPoint,pt);
443  double xi = pt.x;
444  double yi = pt.y;
445 
446  xi -= info.theUl.x;
447  yi -= info.theUl.y;
448 
449  //modifed by simbla 2008 7.17
450  //double xi = (shiftedPoint.lond() - info.theUlGpt.lond())/info.thePostSpacing.x;
451  //double yi = (info.theUlGpt.latd() -
452  // shiftedPoint.latd())/info.thePostSpacing.y;
453 
454 
455  ossim_sint64 x0 = static_cast<ossim_sint64>(xi);
456  ossim_sint64 y0 = static_cast<ossim_sint64>(yi);
457 
458  double xt0 = xi - x0;
459  double yt0 = yi - y0;
460  double xt1 = 1-xt0;
461  double yt1 = 1-yt0;
462 
463  double w00 = xt1*yt1;
464  double w01 = xt0*yt1;
465  double w10 = xt1*yt0;
466  double w11 = xt0*yt0;
467 
468 
469  if ( xi < 0 || yi < 0 ||
470  x0 > (info.theWidth - 1.0) ||
471  y0 > (info.theHeight - 1.0) )
472  {
473  return ossim::nan();
474  }
475 
476  if(x0 == (info.theWidth - 1.0))
477  {
478  --x0;
479  }
480  if(y0 == (info.theHeight - 1.0))
481  {
482  --y0;
483  }
484  T p[4];
485 
486  ossim_uint64 bytesPerLine = info.theBytesPerRawLine;
487 
488  std::streampos offset = y0*bytesPerLine + x0*sizeof(T);
489 
490  {
491  std::lock_guard<std::mutex> lock(m_inputStreamMutex);
492  if(m_inputStream.fail())
493  {
494  m_inputStream.clear();
495  }
496  m_inputStream.seekg(offset, ios::beg);
497  m_inputStream.read((char*)p, sizeof(T));
498 
499  // Get the second post.
500  m_inputStream.read((char*)(p+1), sizeof(T));
501 
502  // offset += (bytesPerLine-2*sizeof(T));
503 
504  m_inputStream.ignore(bytesPerLine-2*sizeof(T));
505  // Get the third post.
506  m_inputStream.read((char*)(p+2), sizeof(T));
507 
508  // Get the fourth post.
509  m_inputStream.read((char*)(p+3), sizeof(T));
510 
511  if(m_inputStream.fail())
512  {
513  m_inputStream.clear();
514  return ossim::nan();
515  }
516  }
517  if(endian.getSystemEndianType() != info.theByteOrder)
518  {
519  endian.swap((T*)p, (ossim_uint32)4);
520  }
521  double p00 = p[0];
522  double p01 = p[1];
523  double p10 = p[2];
524  double p11 = p[3];
525 
526  if (p00 == info.theNullHeightValue)
527  w00 = 0.0;
528  if (p01 == info.theNullHeightValue)
529  w01 = 0.0;
530  if (p10 == info.theNullHeightValue)
531  w10 = 0.0;
532  if (p11 == info.theNullHeightValue)
533  w11 = 0.0;
534 
535 #if 0 /* Serious debug only... */
536  cout << "\np00: " << p00
537  << "\np01: " << p01
538  << "\np10: " << p10
539  << "\np11: " << p11
540  << "\nw00: " << w00
541  << "\nw01: " << w01
542  << "\nw10: " << w10
543  << "\nw11: " << w11
544  << endl;
545 #endif
546 
547  double sum_weights = w00 + w01 + w10 + w11;
548 
549  if (sum_weights)
550  {
551  return (p00*w00 + p01*w01 + p10*w10 + p11*w11) / sum_weights;
552  }
553 
554  return ossim::nan();
555 }
bool pointWithin(const ossimDpt &pt, double epsilon=0.0) const
Definition: ossimDrect.h:781
double nan()
Method to return ieee floating point double precision NAN.
Definition: ossimCommon.h:135
double y
Definition: ossimDpt.h:165
void changeDatum(const ossimDatum *datum)
This will actually perform a shift.
Definition: ossimGpt.cpp:316
unsigned long long ossim_uint64
unsigned int ossim_uint32
ossimByteOrder getSystemEndianType() const
Definition: ossimEndian.h:78
ossim_int32 y
Definition: ossimIpt.h:142
double x
Definition: ossimDpt.h:164
bool worldToLocal(const ossimGpt &world_pt, ossimDpt &local_pt) const
Exposes the 3D world-to-local image coordinate reverse projection.
ossim_int32 x
Definition: ossimIpt.h:141
void swap(ossim_sint8 &)
Definition: ossimEndian.h:26
signed long long ossim_sint64

◆ getHeightAboveMSLMemoryTemplate()

template<class T >
double ossimGeneralRasterElevHandler::getHeightAboveMSLMemoryTemplate ( dummy,
const ossimGeneralRasterElevHandler::GeneralRasterInfo info,
const ossimGpt gpt 
)
private

Definition at line 558 of file ossimGeneralRasterElevHandler.cpp.

References ossimGpt::changeDatum(), ossimEndian::getSystemEndianType(), m_memoryMap, ossim::nan(), ossimDrect::pointWithin(), ossimEndian::swap(), ossimGeneralRasterElevHandler::GeneralRasterInfo::theByteOrder, ossimGeneralRasterElevHandler::GeneralRasterInfo::theBytesPerRawLine, ossimGeneralRasterElevHandler::GeneralRasterInfo::theDatum, ossimGeneralRasterElevHandler::GeneralRasterInfo::theGeometry, ossimGeneralRasterElevHandler::GeneralRasterInfo::theHeight, ossimGeneralRasterElevHandler::GeneralRasterInfo::theNullHeightValue, ossimGeneralRasterElevHandler::GeneralRasterInfo::theUl, ossimGeneralRasterElevHandler::GeneralRasterInfo::theWgs84GroundRect, ossimGeneralRasterElevHandler::GeneralRasterInfo::theWidth, ossimImageGeometry::worldToLocal(), ossimIpt::x, ossimDpt::x, ossimIpt::y, and ossimDpt::y.

Referenced by getHeightAboveMSL().

562 {
563  ossimEndian endian;
564 
565  ossimGpt shiftedPoint = gpt;
566  shiftedPoint.changeDatum(info.theDatum);
567  if(!info.theWgs84GroundRect.pointWithin(shiftedPoint))
568  {
569  return ossim::nan();
570  }
571 
572  ossimDpt pt;
573  info.theGeometry->worldToLocal(shiftedPoint,pt);
574  double xi = pt.x;
575  double yi = pt.y;
576 
577  xi -= info.theUl.x;
578  yi -= info.theUl.y;
579 
580  //modifed by simbla 2008 7.17
581  //double xi = (shiftedPoint.lond() - info.theUlGpt.lond())/info.thePostSpacing.x;
582  //double yi = (info.theUlGpt.latd() -
583  // shiftedPoint.latd())/info.thePostSpacing.y;
584 
585 
586  ossim_sint64 x0 = static_cast<ossim_sint64>(xi);
587  ossim_sint64 y0 = static_cast<ossim_sint64>(yi);
588 
589  double xt0 = xi - x0;
590  double yt0 = yi - y0;
591  double xt1 = 1-xt0;
592  double yt1 = 1-yt0;
593 
594  double w00 = xt1*yt1;
595  double w01 = xt0*yt1;
596  double w10 = xt1*yt0;
597  double w11 = xt0*yt0;
598  if ( xi < 0 || yi < 0 ||
599  x0 > (info.theWidth - 1.0) ||
600  y0 > (info.theHeight - 1.0) )
601  {
602  return ossim::nan();
603  }
604 
605  if(x0 == (info.theWidth - 1.0))
606  {
607  --x0;
608  }
609  if(y0 == (info.theHeight - 1.0))
610  {
611  --y0;
612  }
613  ossim_uint64 bytesPerLine = info.theBytesPerRawLine;
614 
615  ossim_uint64 offset = y0*bytesPerLine + x0*sizeof(T);
616  ossim_uint64 offset2 = offset+bytesPerLine;
617 
618  T v00 = *(reinterpret_cast<T*> (&m_memoryMap[offset]));
619  T v01 = *(reinterpret_cast<T*> (&m_memoryMap[offset + sizeof(T)]));
620  T v10 = *(reinterpret_cast<T*> (&m_memoryMap[offset2]));
621  T v11 = *(reinterpret_cast<T*> (&m_memoryMap[offset2 + sizeof(T)]));
622  if(endian.getSystemEndianType() != info.theByteOrder)
623  {
624  endian.swap(v00);
625  endian.swap(v01);
626  endian.swap(v10);
627  endian.swap(v11);
628  }
629  double p00 = v00;
630  double p01 = v01;
631  double p10 = v10;
632  double p11 = v11;
633 
634  if (p00 == info.theNullHeightValue)
635  w00 = 0.0;
636  if (p01 == info.theNullHeightValue)
637  w01 = 0.0;
638  if (p10 == info.theNullHeightValue)
639  w10 = 0.0;
640  if (p11 == info.theNullHeightValue)
641  w11 = 0.0;
642 
643 #if 0 /* Serious debug only... */
644  cout << "\np00: " << p00
645  << "\np01: " << p01
646  << "\np10: " << p10
647  << "\np11: " << p11
648  << "\nw00: " << w00
649  << "\nw01: " << w01
650  << "\nw10: " << w10
651  << "\nw11: " << w11
652  << endl;
653 #endif
654 
655  double sum_weights = w00 + w01 + w10 + w11;
656 
657  if (sum_weights)
658  {
659  return (p00*w00 + p01*w01 + p10*w10 + p11*w11) / sum_weights;
660  }
661 
662  return ossim::nan();
663 }
bool pointWithin(const ossimDpt &pt, double epsilon=0.0) const
Definition: ossimDrect.h:781
double nan()
Method to return ieee floating point double precision NAN.
Definition: ossimCommon.h:135
double y
Definition: ossimDpt.h:165
void changeDatum(const ossimDatum *datum)
This will actually perform a shift.
Definition: ossimGpt.cpp:316
unsigned long long ossim_uint64
ossimByteOrder getSystemEndianType() const
Definition: ossimEndian.h:78
ossim_int32 y
Definition: ossimIpt.h:142
double x
Definition: ossimDpt.h:164
bool worldToLocal(const ossimGpt &world_pt, ossimDpt &local_pt) const
Exposes the 3D world-to-local image coordinate reverse projection.
ossim_int32 x
Definition: ossimIpt.h:141
void swap(ossim_sint8 &)
Definition: ossimEndian.h:26
signed long long ossim_sint64

◆ getPostValue()

double ossimGeneralRasterElevHandler::getPostValue ( const ossimIpt gridPt) const
virtual

METHOD: getPostValue Returns the value at a given grid point as a double.

Satisfies pure virtual.

Implements ossimElevCellHandler.

Definition at line 198 of file ossimGeneralRasterElevHandler.cpp.

References ossim::nan(), ossimNotify(), and ossimNotifyLevel_WARN.

199 {
201  << "ossimGeneralRasterElevHandler::getPostValue(const ossimIpt& gridPt): NEED TO IMPLEMENT TO NEW INTERFACE\n";
202  return ossim::nan();
203 }
double nan()
Method to return ieee floating point double precision NAN.
Definition: ossimCommon.h:135
OSSIMDLLEXPORT std::ostream & ossimNotify(ossimNotifyLevel level=ossimNotifyLevel_WARN)

◆ getSizeOfElevCell()

ossimIpt ossimGeneralRasterElevHandler::getSizeOfElevCell ( ) const
virtual

METHOD: getSizeOfElevCell Returns the number of post in the cell.

Satisfies pure virtual. Note: x = longitude, y = latitude

Implements ossimElevCellHandler.

Definition at line 193 of file ossimGeneralRasterElevHandler.cpp.

References theGeneralRasterInfo, ossimGeneralRasterElevHandler::GeneralRasterInfo::theHeight, and ossimGeneralRasterElevHandler::GeneralRasterInfo::theWidth.

◆ isOpen()

bool ossimGeneralRasterElevHandler::isOpen ( ) const
virtual

Definition at line 205 of file ossimGeneralRasterElevHandler.cpp.

References m_inputStreamMutex, m_memoryMap, and m_streamOpen.

206 {
207  if(!m_memoryMap.empty()) return true;
208  std::lock_guard<std::mutex> lock(m_inputStreamMutex);
209 
210  //---
211  // Change to use flag as is_open is non-const on some old compilers.
212  return m_streamOpen;
213  // return (m_inputStream.is_open());
214 }
bool m_streamOpen
true if stream is open.

◆ open()

bool ossimGeneralRasterElevHandler::open ( const ossimFilename file,
bool  memoryMapFlag = false 
)
virtual

Opens a stream to the srtm cell.

Returns
Returns true on success, false on error.

Reimplemented from ossimElevCellHandler.

Definition at line 216 of file ossimGeneralRasterElevHandler.cpp.

References ossimString::c_str(), close(), ossimFilename::fileSize(), m_inputStream, m_memoryMap, m_streamOpen, setFilename(), ossimGeneralRasterElevHandler::GeneralRasterInfo::theFilename, and theGeneralRasterInfo.

Referenced by ossimGeneralRasterElevationDatabase::openGeneralRasterDirectory(), ossimGeneralRasterElevHandler(), and ossimGeneralRasterElevFactory::setDirectory().

217 {
218  close();
219  if(!setFilename(file)) return false;
220  m_inputStream.clear();
221  m_inputStream.open(theGeneralRasterInfo.theFilename.c_str(), ios::in | ios::binary);
222 
223  if(memoryMapFlag)
224  {
225  if(!m_inputStream.bad())
226  {
228  if(!m_memoryMap.empty())
229  {
230  m_inputStream.read((char*)(&m_memoryMap.front()), (streamsize)m_memoryMap.size());
231  }
232  }
233  m_inputStream.close();
234  }
235 
236  // Capture the stream state for non-const is_open on old compiler.
237  m_streamOpen = m_inputStream.is_open();
238 
239  return m_streamOpen;
240 }
virtual bool setFilename(const ossimFilename &file)
ossim_int64 fileSize() const
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo
bool m_streamOpen
true if stream is open.
virtual void close()
Closes the stream to the file.
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396

◆ pointHasCoverage()

bool ossimGeneralRasterElevHandler::pointHasCoverage ( const ossimGpt gpt) const
virtual

Loops through ossimGeneralRasterElevHandler::BoundingRectListType and checks for coverage.

Parameters
gptPoint to look for.
Returns
true if coverage is found false if not.

Reimplemented from ossimElevCellHandler.

Definition at line 705 of file ossimGeneralRasterElevHandler.cpp.

References ossimDrect::pointWithin(), theGeneralRasterInfo, and ossimGeneralRasterElevHandler::GeneralRasterInfo::theWgs84GroundRect.

Referenced by ossimGeneralRasterElevationDatabase::pointHasCoverage().

706 {
707  ossimDpt pt = gpt;
708 
710 // BoundingRectListType::const_iterator i = theBoundingRectInfoList.begin();
711 // while (i != theBoundingRectInfoList.end())
712 // {
713 // if ((*i).theBounds.pointWithin(pt))
714 // {
715 // return true;
716 // }
717 // ++i;
718 // }
719 // return false;
720 }
bool pointWithin(const ossimDpt &pt, double epsilon=0.0) const
Definition: ossimDrect.h:781
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo

◆ setFilename()

bool ossimGeneralRasterElevHandler::setFilename ( const ossimFilename file)
privatevirtual

Definition at line 252 of file ossimGeneralRasterElevHandler.cpp.

References ossimKeywordlist::add(), ossimKeywordlist::addFile(), ossimGeneralRasterInfo::bytesPerRawLine(), ossimString::c_str(), ossimGpt::changeDatum(), ossimKeywordlist::clear(), ossimGpt::datum(), ossimFilename::exists(), ossimKeywordNames::FILENAME_KW, ossimKeywordlist::find(), ossimErrorStatusInterface::getErrorStatus(), ossimGeneralRasterInfo::getImageDataByteOrder(), ossimGeneralRasterInfo::getImageMetaData(), ossimImageGeometry::getMetersPerPixel(), ossimImageMetaData::getNullPix(), ossimImageMetaData::getScalarType(), ossimIrect::height(), ossimGeneralRasterInfo::imageRect(), ossimIrect::ll(), ossimGeneralRasterInfo::loadState(), ossimImageGeometry::loadState(), ossimImageGeometry::localToWorld(), ossimIrect::lr(), ossim::nan(), ossimGeneralRasterInfo::numberOfBands(), ossimErrorCodes::OSSIM_ERROR, OSSIM_RIGHT_HANDED, ossimNotify(), ossimNotifyLevel_WARN, ossimFilename::setExtension(), ossimGeneralRasterElevHandler::GeneralRasterInfo::theByteOrder, ossimGeneralRasterElevHandler::GeneralRasterInfo::theBytesPerRawLine, ossimGeneralRasterElevHandler::GeneralRasterInfo::theDatum, ossimGeneralRasterElevHandler::GeneralRasterInfo::theFilename, ossimElevCellHandler::theFilename, theGeneralRasterInfo, ossimGeneralRasterElevHandler::GeneralRasterInfo::theGeometry, ossimElevSource::theGroundRect, ossimGeneralRasterElevHandler::GeneralRasterInfo::theHeight, ossimGeneralRasterElevHandler::GeneralRasterInfo::theImageRect, ossimGeneralRasterElevHandler::GeneralRasterInfo::theLr, ossimElevCellHandler::theMeanSpacing, ossimGeneralRasterElevHandler::GeneralRasterInfo::theNullHeightValue, ossimElevSource::theNullHeightValue, ossimGeneralRasterElevHandler::GeneralRasterInfo::theScalarType, ossimGeneralRasterElevHandler::GeneralRasterInfo::theUl, ossimGeneralRasterElevHandler::GeneralRasterInfo::theWgs84GroundRect, ossimGeneralRasterElevHandler::GeneralRasterInfo::theWidth, ossimString::trim(), ossimIrect::ul(), ossimIrect::ur(), ossimRefPtr< T >::valid(), ossimIrect::width(), and ossimDpt::y.

Referenced by open().

253 {
254  if(file.trim() == "")
255  {
256  return false;
257  }
258  theFilename = file;
259  ossimFilename hdrFile = file;
260  ossimFilename geomFile = file;
265  hdrFile = hdrFile.setExtension("omd");
266  geomFile = geomFile.setExtension("geom");
267 
268  if(!hdrFile.exists()||
269  !geomFile.exists())
270  {
271  return false;
272  }
273  ossimKeywordlist kwl(hdrFile);
274  if (kwl.getErrorStatus() == ossimErrorCodes::OSSIM_ERROR)
275  {
276  return false;
277  }
278 
279  kwl.add(ossimKeywordNames::FILENAME_KW, file.c_str(), true);
280  ossimGeneralRasterInfo generalInfo;
281 
282  if(!generalInfo.loadState(kwl))
283  {
284  return false;
285  }
286  if(generalInfo.numberOfBands() != 1)
287  {
288  ossimNotify(ossimNotifyLevel_WARN) << "ossimGeneralRasterElevHandler::initializeInfo WARNING:The number of bands are not specified in the header file" << std::endl;
289  return false;
290  }
291 
292  kwl.clear();
293  if(kwl.addFile(geomFile))
294  {
305 
306  //add by simbla
307 
308  // ---
309  // Try to determine if there is a prefix like "image0." or not.
310  // ---
311  std::string prefix = "";
312  if ( kwl.find("image0.type") )
313  {
314  prefix = "image0.";
315  }
316 
318  if(!theGeneralRasterInfo.theGeometry->loadState( kwl, prefix.c_str() ))
319  {
321  }
322 
324  {
325  return false;
326  }
327  ossimGpt defaultDatum;
328  ossimGpt ulGpt;
329  ossimGpt urGpt;
330  ossimGpt lrGpt;
331  ossimGpt llGpt;
332  theGeneralRasterInfo.theDatum = defaultDatum.datum();
337 
343  theGroundRect = ossimGrect(ulGpt, urGpt, lrGpt, llGpt);
346  }
347  else
348  {
349  return false;
350  }
351 
352  return true;
353 }
Represents serializable keyword/value map.
bool valid() const
Definition: ossimRefPtr.h:75
virtual bool loadState(const ossimKeywordlist &kwl, const char *prefix=0)
Attempts to initialize a transform and a projection given the KWL.
ossimScalarType getScalarType() const
virtual bool loadState(const ossimKeywordlist &kwl, const char *prefix=0)
Method to the load (recreate) the state of an object from a keyword list.
double nan()
Method to return ieee floating point double precision NAN.
Definition: ossimCommon.h:135
double y
Definition: ossimDpt.h:165
ossim_uint32 height() const
Definition: ossimIrect.h:487
const ossimIpt & ul() const
Definition: ossimIrect.h:274
ossim_int32 bytesPerRawLine() const
Returns the number of bytes in a raw line.
static const ossimErrorCode OSSIM_ERROR
const ossimIpt & ll() const
Definition: ossimIrect.h:277
double getNullPix(ossim_uint32 band) const
void changeDatum(const ossimDatum *datum)
This will actually perform a shift.
Definition: ossimGpt.cpp:316
ossimByteOrder getImageDataByteOrder() const
const ossimDatum * datum() const
datum().
Definition: ossimGpt.h:196
ossimGrect theGroundRect
bool exists() const
bool localToWorld(const ossimDpt &local_pt, ossimGpt &world_pt) const
Exposes the 3D projection from image to world coordinates.
ossimGeneralRasterElevHandler::GeneralRasterInfo theGeneralRasterInfo
ossimDpt getMetersPerPixel() const
Returns the GSD associated with this image in the active projection.
ossimString trim(const ossimString &valueToTrim=ossimString(" \\)) const
this will strip lead and trailing character passed in.
ossimFilename theFilename
Virtual method for reading.
const ossimIpt & lr() const
Definition: ossimIrect.h:276
ossim_uint32 width() const
Definition: ossimIrect.h:500
const ossimIpt & ur() const
Definition: ossimIrect.h:275
Container class that holds both 2D transform and 3D projection information for an image Only one inst...
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396
const ossimImageMetaData & getImageMetaData() const
const ossimIrect & imageRect() const
Zero based rectangle of the valid image.
ossimFilename & setExtension(const ossimString &e)
Sets the extension of a file name.
static const char * FILENAME_KW
ossim_int32 numberOfBands() const
Number of bands.
OSSIMDLLEXPORT std::ostream & ossimNotify(ossimNotifyLevel level=ossimNotifyLevel_WARN)

Member Data Documentation

◆ m_inputStream

std::ifstream ossimGeneralRasterElevHandler::m_inputStream
private

Definition at line 160 of file ossimGeneralRasterElevHandler.h.

Referenced by close(), getHeightAboveMSLFileTemplate(), and open().

◆ m_inputStreamMutex

std::mutex ossimGeneralRasterElevHandler::m_inputStreamMutex
mutableprivate

Definition at line 159 of file ossimGeneralRasterElevHandler.h.

Referenced by getHeightAboveMSLFileTemplate(), and isOpen().

◆ m_memoryMap

std::vector<char> ossimGeneralRasterElevHandler::m_memoryMap
private

◆ m_streamOpen

bool ossimGeneralRasterElevHandler::m_streamOpen
private

true if stream is open.

Definition at line 163 of file ossimGeneralRasterElevHandler.h.

Referenced by close(), isOpen(), and open().

◆ theGeneralRasterInfo

ossimGeneralRasterElevHandler::GeneralRasterInfo ossimGeneralRasterElevHandler::theGeneralRasterInfo
private

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