Class SbProj4Projection
To use this class as a projection, refer to the documentation of SbProjection class.
By default, input points must be defined in the geodetic coordinate system :
- x coordinate : longitudes degrees from -180 to 180
- y coordinate : latitudes degrees from -90 to 90
- z coordinate : meters
It is possible to define the input data in the geocentric coordinate system by calling setCoordinateSystem(GEOCENTRIC). The geocentric coordinate system is the earth coordinate system, where x, y and z coordinate are expressed in meters.
The PROJ.4 library parameters are stored as SbProjection string parameters:
- parameter 0 : projection name
- parameter 1 : ellipsoid
- parameter 2 : units
- parameter 3 : longitude zero
The first SbProjection float parameter is used to specify the z coordinate scaleRatio applied to the projected shapes.
The enumeration PredefinedEllipsoid defines the list of available ellipsoid. An ellispoid definition is a mathematical representation used to approximate the earth when computing projections. Calling setEllipsoid() sets the current ellipsoid used to compute projections.
Only projections with an inverse function defined are available.
The available projections are defined with the Projection enumeration. When using an SbProj4Projection object with an SoProjection node, those projections are automatically added in the order above, and you can choose the desired projection by using the corresponding id (refer to SoProjection node).
LIMITATIONS
It can happen that vertices of a projected shape cross other ones, depending on the chosen projection. Visually it results in a flipping effect.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumAvailable coordinate systems.static enumAvailable ellipsoids.static enumAvailable projections.Nested classes/interfaces inherited from class com.openinventor.inventor.Inventor
Inventor.ConstructorCommand -
Field Summary
Fields inherited from class com.openinventor.inventor.Inventor
VERBOSE_LEVEL, ZeroHandle -
Constructor Summary
ConstructorsConstructorDescriptionConstructor.Constructor.Copy constructor. -
Method Summary
Modifier and TypeMethodDescriptionGet current coordinate system.Get current ellipsoid.Get current input ellipsoid.static StringGet PROJ.4 ellipsoid string.Get current projection .Get current input projection .static StringGet projection name description.static StringGet internal PROJ.4 projection string.intGet current UTM zone.booleanGet revertCoordNeeded.booleanGet m_south (UTM)voidsetCoordinateSystem(SbProj4Projection.CoordinateSystems coordinateSystem) Set current coordinate system.voidSet current ellipsoid.voidSet current input ellipsoid.voidSet current projection.voidSet current input projection.voidsetRevertCoord(boolean revertCoordNeeded) Set revertCoordNeeded.voidsetUTMSouth(boolean south) Set m_south (UTM)voidsetUTMZone(int zone) Set current UTM zone.Transform the given coordinates from Geodetic coordinate system to Geocentric coordinate system .Transform the given coordinates from Geocentric coordinate system to Geodetic coordinate system .Methods inherited from class com.openinventor.inventor.projection.SbProjection
exit, getFloatParameter, getNumFloatParameters, getNumStringParameters, getProjectedBoundingBox, getProjectionNode, getStringParameter, init, inverse, project, setNumFloatParameters, setNumStringParameters, setParameter, setParameterMethods inherited from class com.openinventor.inventor.Inventor
dispose, getNativeResourceHandle
-
Constructor Details
-
SbProj4Projection
Constructor. -
SbProj4Projection
public SbProj4Projection()Constructor. -
SbProj4Projection
Copy constructor.
-
-
Method Details
-
setEllipsoidIn
Set current input ellipsoid. -
getProjectionString
Get internal PROJ.4 projection string. -
getEllipsoidString
Get PROJ.4 ellipsoid string. -
getEllipsoidIn
Get current input ellipsoid. -
setUTMZone
public void setUTMZone(int zone) Set current UTM zone. -
getEllipsoid
Get current ellipsoid. -
getProjectionName
Get projection name description. -
setEllipsoid
Set current ellipsoid. -
toGeocentric
Transform the given coordinates from Geodetic coordinate system to Geocentric coordinate system . -
setProjectionIn
Set current input projection. -
isUTMSouth
public boolean isUTMSouth()Get m_south (UTM) -
getProjection
Get current projection . -
getUTMZone
public int getUTMZone()Get current UTM zone. -
getProjectionIn
Get current input projection . -
setUTMSouth
public void setUTMSouth(boolean south) Set m_south (UTM) -
getCoordinateSystem
Get current coordinate system. -
toGeodetic
Transform the given coordinates from Geocentric coordinate system to Geodetic coordinate system . -
setCoordinateSystem
Set current coordinate system. -
setRevertCoord
public void setRevertCoord(boolean revertCoordNeeded) Set revertCoordNeeded. -
setProjection
Set current projection. -
isRevertCoordNeeded
public boolean isRevertCoordNeeded()Get revertCoordNeeded.
-