OSSIM - Open Source Software Image Map
Version 1.9.0 (20180803)
|
class for ground to image polynomial projection: (x,y,z)|->(x,y) polynom order is configurable More...
#include <ossimPolynomProjection.h>
Public Member Functions | |
ossimPolynomProjection () | |
Constructors. More... | |
ossimPolynomProjection (const ossimPolynomProjection ©me) | |
~ossimPolynomProjection () | |
virtual bool | operator== (const ossimProjection &projection) const |
Basic operations. More... | |
virtual bool | saveState (ossimKeywordlist &kwl, const char *prefix=0) const |
virtual bool | loadState (const ossimKeywordlist &kwl, const char *prefix=0) |
virtual std::ostream & | print (std::ostream &out) const |
Outputs theErrorStatus as an ossimErrorCode and an ossimString. More... | |
virtual ossimObject * | dup () const |
virtual void | worldToLineSample (const ossimGpt &world_point, ossimDpt &image_point) const |
Projection / localization methods. More... | |
virtual void | lineSampleToWorld (const ossimDpt &image_point, ossimGpt &world_point) const |
virtual void | lineSampleHeightToWorld (const ossimDpt &image_point, const double &heightEllipsoid, ossimGpt &worldPoint) const |
virtual ossimGpt | origin () const |
virtual ossimDpt | getMetersPerPixel () const |
virtual bool | setupOptimizer (const ossimString &setup) |
optimizableProjection implementation More... | |
virtual bool | useForward () const |
virtual ossim_uint32 | degreesOfFreedom () const |
virtual double | optimizeFit (const ossimTieGptSet &tieSet, double *targetVariance=NULL) |
const ossimPolynom< ossim_float64, 3 >::EXPT_SET & | getExpSet () const |
accessors (not all of them inline) More... | |
void | setExpSet (const ossimPolynom< ossim_float64, 3 >::EXPT_SET &nset) |
void | setupDesiredExponents (int horizonal_ord, int vertical_ord) |
bool | setupDesiredExponents (const ossimString &monoms) |
added for easy setup More... | |
const ossimPolynom< ossim_float64, 3 > & | getPolyLine () const |
added for easy setup More... | |
void | setPolyLine (const ossimPolynom< ossim_float64, 3 > &poly) |
const ossimPolynom< ossim_float64, 3 > & | getPolySamp () const |
void | setPolySamp (const ossimPolynom< ossim_float64, 3 > &poly) |
const ossim_float64 & | getLonOffset () const |
void | setLonOffset (const ossim_float64 &v) |
const ossim_float64 & | getLonScale () const |
void | setLonScale (const ossim_float64 &v) |
const ossim_float64 & | getLatOffset () const |
void | setLatOffset (const ossim_float64 &v) |
const ossim_float64 & | getLatScale () const |
void | setLatScale (const ossim_float64 &v) |
const ossim_float64 & | getHgtOffset () const |
void | setHgtOffset (const ossim_float64 &v) |
const ossim_float64 & | getHgtScale () const |
void | setHgtScale (const ossim_float64 &v) |
virtual bool | isAffectedByElevation () const |
Implementation of pure virtual ossimProjection::isAffectedByElevation method. More... | |
![]() | |
ossimProjection () | |
virtual | ~ossimProjection () |
virtual ossimDpt | forward (const ossimGpt &wp) const |
virtual ossimGpt | inverse (const ossimDpt &pp) const |
virtual void | getRoundTripError (const ossimDpt &imagePoint, ossimDpt &errorResult) const |
virtual void | getRoundTripError (const ossimGpt &groundPoint, ossimDpt &errorResult) const |
virtual void | getGroundClipPoints (ossimGeoPolygon &gpts) const |
virtual bool | isEqualTo (const ossimObject &obj, ossimCompareType compareType=OSSIM_COMPARE_FULL) const |
virtual bool | operator!= (const ossimProjection &projection) const |
![]() | |
ossimObject () | |
virtual | ~ossimObject () |
virtual ossimString | getShortName () const |
virtual ossimString | getLongName () const |
virtual ossimString | getDescription () 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 void | accept (ossimVisitor &visitor) |
![]() | |
ossimReferenced () | |
ossimReferenced (const ossimReferenced &) | |
ossimReferenced & | operator= (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 |
![]() | |
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 |
![]() | |
ossimOptimizableProjection () | |
ossimOptimizableProjection (const ossimOptimizableProjection &source) | |
virtual | ~ossimOptimizableProjection () |
virtual ossimOptimizableProjection & | operator= (const ossimOptimizableProjection &source) |
virtual bool | needsInitialState () const |
needsInitialState() More... | |
Protected Member Functions | |
void | buildDerivatives () |
protected methods More... | |
void | buildLineDerivatives () |
void | buildSampDerivatives () |
bool | stringToExp (const ossimString &s, ossimPolynom< ossim_float64, 3 >::EXP_TUPLE &et) const |
int | getSymbol (ossimString &ts, const ossimString &symbols) const |
takes string of xyz monoms, x2z3 More... | |
int | getExponent (ossimString &ts) const |
![]() | |
virtual | ~ossimReferenced () |
Protected Attributes | |
ossimPolynom< ossim_float64, 3 >::EXPT_SET | theExpSet |
desired exponents tuples set (for both line and sample polynoms) used for optimization More... | |
ossimPolynom< ossim_float64, 3 > | thePolyLine |
ground (3d) to image(2D) polynoms More... | |
ossimPolynom< ossim_float64, 3 > | thePolySamp |
xyz polynom More... | |
ossimPolynom< ossim_float64, 3 > | thePolyLine_DLon |
polynom partial derivatives More... | |
ossimPolynom< ossim_float64, 3 > | thePolyLine_DLat |
ossimPolynom< ossim_float64, 3 > | thePolySamp_DLon |
ossimPolynom< ossim_float64, 3 > | thePolySamp_DLat |
ossim_float64 | theLonOffset |
normalization parameters More... | |
ossim_float64 | theLonScale |
ossim_float64 | theLatOffset |
ossim_float64 | theLatScale |
ossim_float64 | theHgtOffset |
ossim_float64 | theHgtScale |
![]() | |
ossimErrorCode | theErrorStatus |
class for ground to image polynomial projection: (x,y,z)|->(x,y) polynom order is configurable
Definition at line 18 of file ossimPolynomProjection.h.
ossimPolynomProjection::ossimPolynomProjection | ( | ) |
Constructors.
Definition at line 36 of file ossimPolynomProjection.cpp.
ossimPolynomProjection::ossimPolynomProjection | ( | const ossimPolynomProjection & | copyme | ) |
Definition at line 47 of file ossimPolynomProjection.cpp.
ossimPolynomProjection::~ossimPolynomProjection | ( | ) |
Definition at line 68 of file ossimPolynomProjection.cpp.
|
protected |
protected methods
Definition at line 498 of file ossimPolynomProjection.cpp.
References buildLineDerivatives(), and buildSampDerivatives().
Referenced by optimizeFit().
|
protected |
Definition at line 505 of file ossimPolynomProjection.cpp.
References ossimPolynom< T, DIM >::pdiff(), thePolyLine, thePolyLine_DLat, and thePolyLine_DLon.
Referenced by buildDerivatives(), and setPolyLine().
|
protected |
Definition at line 512 of file ossimPolynomProjection.cpp.
References ossimPolynom< T, DIM >::pdiff(), thePolySamp, thePolySamp_DLat, and thePolySamp_DLon.
Referenced by buildDerivatives(), and setPolySamp().
|
virtual |
degreesOfFreedom() number of degrees of freedom (eg: 8 for bilinear, 6 for affine, 2 for translation) especially useful when not inheriting from AdjustableParameterInterface
Implements ossimOptimizableProjection.
Definition at line 526 of file ossimPolynomProjection.cpp.
References theExpSet.
|
inlinevirtual |
Implements ossimProjection.
Definition at line 39 of file ossimPolynomProjection.h.
|
protected |
Definition at line 745 of file ossimPolynomProjection.cpp.
References ossimString::afterPos(), and ossimString::size().
Referenced by stringToExp().
|
inline |
accessors (not all of them inline)
Definition at line 65 of file ossimPolynomProjection.h.
|
inline |
Definition at line 85 of file ossimPolynomProjection.h.
|
inline |
Definition at line 87 of file ossimPolynomProjection.h.
|
inline |
Definition at line 80 of file ossimPolynomProjection.h.
|
inline |
Definition at line 82 of file ossimPolynomProjection.h.
|
inline |
Definition at line 75 of file ossimPolynomProjection.h.
|
inline |
Definition at line 77 of file ossimPolynomProjection.h.
|
virtual |
ACCESS METHODS:
Implements ossimProjection.
Definition at line 262 of file ossimPolynomProjection.cpp.
References lineSampleToWorld(), theHgtOffset, theLatOffset, theLonOffset, worldToLineSample(), ossimDpt::x, and ossimDpt::y.
|
inline |
added for easy setup
Definition at line 70 of file ossimPolynomProjection.h.
|
inline |
Definition at line 72 of file ossimPolynomProjection.h.
|
protected |
takes string of xyz monoms, x2z3
Definition at line 731 of file ossimPolynomProjection.cpp.
References ossimString::afterPos(), and ossimString::size().
Referenced by stringToExp().
|
inlinevirtual |
Implementation of pure virtual ossimProjection::isAffectedByElevation method.
Implements ossimProjection.
Definition at line 95 of file ossimPolynomProjection.h.
|
virtual |
METHOD: lineSampleHeightToWorld This is the pure virtual that projects the image point to the given elevation above ellipsoid, thereby bypassing reference to a DEM. Useful for projections that are sensitive to elevation (such as sensor models).
Implements ossimProjection.
Definition at line 135 of file ossimPolynomProjection.cpp.
References ossim::almostEqual(), ossimPolynom< T, DIM >::eval(), ossimGpt::hgt, ossim::isnan(), ossimGpt::lat, ossimGpt::lon, ossimNotify(), ossimNotifyLevel_WARN, theHgtOffset, theHgtScale, theLatOffset, theLatScale, theLonOffset, theLonScale, thePolyLine, thePolyLine_DLat, thePolyLine_DLon, thePolySamp, thePolySamp_DLat, thePolySamp_DLon, ossimDpt::x, and ossimDpt::y.
Referenced by lineSampleToWorld().
|
virtual |
METHOD: lineSampleToWorld() Performs the inverse projection from line, sample to ground (world):
Implements ossimProjection.
Definition at line 110 of file ossimPolynomProjection.cpp.
References ossimDpt::hasNans(), ossimGpt::height(), lineSampleHeightToWorld(), and ossimGpt::makeNan().
Referenced by getMetersPerPixel().
|
virtual |
Method to the load (recreate) the state of the object from a keyword list. Return true if ok or false on error.
Reimplemented from ossimProjection.
Definition at line 364 of file ossimPolynomProjection.cpp.
References ossimProjection::loadState(), ossimNotify(), and ossimNotifyLevel_DEBUG.
|
virtual |
Basic operations.
Implements ossimProjection.
Definition at line 293 of file ossimPolynomProjection.cpp.
|
virtual |
optimizeFit() adjusts projection to GLOBALLY fit best to ALL tie points (no outlier rejection) can select an optional threshold for accuracy
RETURNS : resulting image error variance of fitted model, or negative value for error
IMPORTANT : the unit for *targetVariance and the returned value is : meters^2 when useForward() is true OR pixel^2 if useForward() is false
Implements ossimOptimizableProjection.
Definition at line 566 of file ossimPolynomProjection.cpp.
References buildDerivatives(), DBL_EPSILON, ossimTieGptSet::getGroundBoundaries(), ossimTieGptSet::getTiePoints(), ossimGpt::hgt, ossimGpt::isLatNan(), ossimGpt::isLonNan(), ossim::isnan(), ossimGpt::lat, ossimPolynom< T, DIM >::LMSfit(), ossimGpt::lon, OSSIM_DEFAULT_MIN_PIX_DOUBLE, ossimNotify(), ossimNotifyLevel_FATAL, ossimTieGptSet::size(), theExpSet, theHgtOffset, theHgtScale, theLatOffset, theLatScale, theLonOffset, theLonScale, thePolyLine, and thePolySamp.
|
virtual |
METHOD: origin() Returns projection's ground point origin. That is the GP corresponding to line=0, sample=0.
Implements ossimProjection.
Definition at line 253 of file ossimPolynomProjection.cpp.
References theHgtOffset, theLatOffset, and theLonOffset.
|
virtual |
Outputs theErrorStatus as an ossimErrorCode and an ossimString.
Reimplemented from ossimProjection.
Definition at line 309 of file ossimPolynomProjection.cpp.
|
virtual |
METHODS: saveState, loadState Fulfills ossimObject base-class pure virtuals.
Reimplemented from ossimProjection.
Definition at line 331 of file ossimPolynomProjection.cpp.
References ossimKeywordlist::add(), and ossimKeywordNames::TYPE_KW.
|
inline |
Definition at line 66 of file ossimPolynomProjection.h.
|
inline |
Definition at line 86 of file ossimPolynomProjection.h.
|
inline |
Definition at line 88 of file ossimPolynomProjection.h.
|
inline |
Definition at line 81 of file ossimPolynomProjection.h.
|
inline |
Definition at line 83 of file ossimPolynomProjection.h.
|
inline |
Definition at line 76 of file ossimPolynomProjection.h.
|
inline |
Definition at line 78 of file ossimPolynomProjection.h.
void ossimPolynomProjection::setPolyLine | ( | const ossimPolynom< ossim_float64, 3 > & | poly | ) |
Definition at line 484 of file ossimPolynomProjection.cpp.
References buildLineDerivatives(), and thePolyLine.
void ossimPolynomProjection::setPolySamp | ( | const ossimPolynom< ossim_float64, 3 > & | poly | ) |
Definition at line 491 of file ossimPolynomProjection.cpp.
References buildSampDerivatives(), and thePolySamp.
void ossimPolynomProjection::setupDesiredExponents | ( | int | horizonal_ord, |
int | vertical_ord | ||
) |
Definition at line 557 of file ossimPolynomProjection.cpp.
References ossimPolynom< T, DIM >::addExpTupleRight(), theExpSet, and thePolySamp.
Referenced by setupOptimizer().
bool ossimPolynomProjection::setupDesiredExponents | ( | const ossimString & | monoms | ) |
added for easy setup
Definition at line 533 of file ossimPolynomProjection.cpp.
References ossimString::explode(), ossimNotify(), ossimNotifyLevel_FATAL, stringToExp(), and theExpSet.
|
virtual |
optimizableProjection implementation
Reimplemented from ossimOptimizableProjection.
Definition at line 519 of file ossimPolynomProjection.cpp.
References setupDesiredExponents().
|
protected |
Definition at line 685 of file ossimPolynomProjection.cpp.
References getExponent(), getSymbol(), ossimNotify(), ossimNotifyLevel_FATAL, ossimString::size(), ossimString::trim(), and ossimString::upcase().
Referenced by setupDesiredExponents().
|
inlinevirtual |
useForward() return true when it's better (more accurate / fast) to use forward (from ground to image) than inverse(from image to ground)
Implements ossimOptimizableProjection.
Definition at line 58 of file ossimPolynomProjection.h.
|
virtual |
Projection / localization methods.
Implements ossimProjection.
Definition at line 78 of file ossimPolynomProjection.cpp.
References ossim::almostEqual(), ossimPolynom< T, DIM >::eval(), ossimGpt::hgt, ossimGpt::isLatNan(), ossimGpt::isLonNan(), ossim::isnan(), ossimGpt::lat, ossimGpt::lon, ossimDpt::makeNan(), theHgtOffset, theHgtScale, theLatOffset, theLatScale, theLonOffset, theLonScale, thePolyLine, thePolySamp, ossimDpt::x, and ossimDpt::y.
Referenced by getMetersPerPixel().
|
protected |
desired exponents tuples set (for both line and sample polynoms) used for optimization
Definition at line 102 of file ossimPolynomProjection.h.
Referenced by degreesOfFreedom(), optimizeFit(), and setupDesiredExponents().
|
protected |
Definition at line 125 of file ossimPolynomProjection.h.
Referenced by getMetersPerPixel(), lineSampleHeightToWorld(), optimizeFit(), origin(), and worldToLineSample().
|
protected |
Definition at line 126 of file ossimPolynomProjection.h.
Referenced by lineSampleHeightToWorld(), optimizeFit(), and worldToLineSample().
|
protected |
Definition at line 123 of file ossimPolynomProjection.h.
Referenced by getMetersPerPixel(), lineSampleHeightToWorld(), optimizeFit(), origin(), and worldToLineSample().
|
protected |
Definition at line 124 of file ossimPolynomProjection.h.
Referenced by lineSampleHeightToWorld(), optimizeFit(), and worldToLineSample().
|
protected |
normalization parameters
Definition at line 121 of file ossimPolynomProjection.h.
Referenced by getMetersPerPixel(), lineSampleHeightToWorld(), optimizeFit(), origin(), and worldToLineSample().
|
protected |
Definition at line 122 of file ossimPolynomProjection.h.
Referenced by lineSampleHeightToWorld(), optimizeFit(), and worldToLineSample().
|
protected |
ground (3d) to image(2D) polynoms
Definition at line 107 of file ossimPolynomProjection.h.
Referenced by buildLineDerivatives(), lineSampleHeightToWorld(), optimizeFit(), setPolyLine(), and worldToLineSample().
|
protected |
Definition at line 114 of file ossimPolynomProjection.h.
Referenced by buildLineDerivatives(), and lineSampleHeightToWorld().
|
protected |
polynom partial derivatives
Definition at line 113 of file ossimPolynomProjection.h.
Referenced by buildLineDerivatives(), and lineSampleHeightToWorld().
|
protected |
xyz polynom
Definition at line 108 of file ossimPolynomProjection.h.
Referenced by buildSampDerivatives(), lineSampleHeightToWorld(), optimizeFit(), setPolySamp(), setupDesiredExponents(), and worldToLineSample().
|
protected |
Definition at line 116 of file ossimPolynomProjection.h.
Referenced by buildSampDerivatives(), and lineSampleHeightToWorld().
|
protected |
Definition at line 115 of file ossimPolynomProjection.h.
Referenced by buildSampDerivatives(), and lineSampleHeightToWorld().