Provides access to additional members that associate a spatial reference with a vertical coordinate system.
When To Use
Use ISpatialReference3 to work with the vertical coordinate system part of a spatial reference.
Members
Name | Description | |
---|---|---|
Abbreviation | The abbreviated name of this spatial reference component. | |
Alias | The alias of this spatial reference component. | |
ApplyPrecision | Applies the measure and z value precisions. | |
ApplyXYPrecision | Applies the XY precision. | |
Changed | Notify this object that some of its parts have changed (parameter values, z unit, etc.). | |
FactoryCode | The factory code (WKID) of the spatial reference. | |
GetDomain | The XY domain extent. | |
GetFalseOriginAndUnits | Get the false origin and units. | |
GetMDomain | The measure domain extent. | |
GetMFalseOriginAndUnits | Get the measure false origin and units. | |
GetZDomain | The Z domain extent. | |
GetZFalseOriginAndUnits | Get the Z false origin and units. | |
HasMPrecision | Returns true when m-value precision information has been defined. | |
HasXYPrecision | Returns true when (x,y) precision information has been defined. | |
HasZPrecision | Returns true when z-value precision information has been defined. | |
IsMPrecisionEqual | Returns true if the measure precisions of the two spatial references are the same. | |
IsPrecisionEqual | Returns TRUE when the precision information for the two spatial references is the same. | |
IsXYPrecisionEqual | Returns true if the XY precisions of the two spatial references are the same. | |
IsZPrecisionEqual | Returns true if the Z precisions of the two spatial references are the same. | |
Name | The name of this spatial reference component. | |
PrecisionExImpl | An opaque reference to the precision information (including z/m awareness) implementation for this spatial reference. | |
PrecisionImpl | An opaque reference to the precision information implementation for this spatial reference. | |
ProjectionHint | Projection hint for speeding up projections. | |
Remarks | The comment string of this spatial reference component. | |
SetDomain | The XY domain extent. | |
SetFalseOriginAndUnits | Set the false origin and units. | |
SetMDomain | The measure domain extent. | |
SetMFalseOriginAndUnits | Set the measure false origin and units. | |
SetZDomain | The Z domain extent. | |
SetZFalseOriginAndUnits | Set the Z false origin and units. | |
SpatialReferenceImpl | SpatialReferenceImpl. | |
VerticalCoordinateSystem | The VCS associated with this spatial reference. | |
ZCoordinateUnit | The unit for the Z coordinate. |
ISpatialReference3.ProjectionHint Method
Projection hint for speeding up projections.
Public Sub ProjectionHint ( _
ByVal Geometry As IGeometry, _
ByVal targetSR As ISpatialReference, _
ByRef Direction As esriTransformDirection, _
ByRef pXForm As ITransformation, _
ByRef ProjectionHint As Integer _
)
public void ProjectionHint (
IGeometry Geometry,
ISpatialReference targetSR,
ref esriTransformDirection Direction,
ref ITransformation pXForm,
ref int ProjectionHint
);
Description
Each geographic or projected coordinate system has a horizon. The horizon defines the mathematical limits of the coordinate system. As an example, transverse Mercator is limited to longitude values that are within +/-45 degrees of the central meridian. Most projection workflows are local. That is, all geometries of a feature class are within the horizons of the input and output coordinate systems. The process of checking whether a geometry is within, crosses, or is outside a horizon takes time. You can use the projectionhint method to calculate whether the envelope or bounding geometry of a feature class is within the applicable horizons. If it is, you can add a flag to the ProjectEx5 method to omit horizon checking.
You can also have the projectionhint method check for a geographic (datum) transformation. In the SpatialReferenceEnvironment, the GeoTransformationOperationSet stores active transformations. Normally, none are loaded by default, but if you've loaded several transformations previously, you can use projection hint to return the appropriate one and in which direction to apply it for this projection operation.
The projectionhint values are:
esriProjectionHintNoHorizonCheck = 0,
esriProjectionHintCheckPCSHorizon = 1,
esriProjectionHintCheckGCSHorizon = 2,
esriProjectionHintFindGeoTransformation = 4,
esriProjectionHintDefault = 7,
esriProjectionHintExplore = 8,
esriProjectionHintDoNotProject = 16 // useful for isEqualNoName
ISpatialReference3.VerticalCoordinateSystem Property
The VCS associated with this spatial reference.
Public Property VerticalCoordinateSystem As IVerticalCoordinateSystem
public IVerticalCoordinateSystem VerticalCoordinateSystem {get; set;}
Description
ISpatialReferenceFactory3 srf3 = new SpatialReferenceEnvironmentClass();
IVerticalCoordinateSystem vcs1, vcs2;
vcs1 = srf3.CreateVerticalCoordinateSystem(5702);//NGVD_1929
vcs2 = srf3.CreateVerticalCoordinateSystem(5703);//NAVD_1988
ISpatialReference sr1, sr2;
sr1 = srf3.CreateSpatialReference(4269);//GCS_North_American_1983
((ISpatialReference3)sr1).VerticalCoordinateSystem = vcs1;
sr2 = srf3.CreateSpatialReference(5070);//NAD_1983_Contiguous_USA_Albers
((ISpatialReference3)sr2).VerticalCoordinateSystem = vcs2;
IProjectedCoordinateSystem pcs2 = (IProjectedCoordinateSystem)sr2;
IGeographicCoordinateSystem gcs1 = (IGeographicCoordinateSystem)sr1;
IGeographicCoordinateSystem gcs2 = pcs2.GeographicCoordinateSystem;
IHVCompositeDatumTransformationEditor edit = new HVCompositeDatumTransformationEditorClass();
IHVDatumTransformation hvdt;
edit.SetSpatialReferences(gcs1, gcs2);
hvdt = edit.CreateHVDatumTransformation(110011);//PE_VT_NGVD29_TO_NAVD88_NAD83_ECW
edit.Add(hvdt, esriTransformDirection.esriTransformForward);
IHVCompositeDatumTransformation hvcdt = edit.CreateNew();
ITransformation transform = (ITransformation)hvcdt;
IPoint pnt = new PointClass();
pnt.SpatialReference = sr1;
pnt.PutCoords(4, 3);
((IZAware)pnt).ZAware = true;
pnt.Z = 5;
((IGeometry5)pnt).ProjectEx5(sr2, esriTransformDirection.esriTransformForward, transform, false, 0, 0, ((int)esriProjectionHint.esriProjectionHintDefault) & ((int)esriProjectionHint.esriProjectionHintFindGeoTransformation));
double x, y, z;
pnt.QueryCoords(out x, out y);//10421841.071915826, 3982079.5947264349
z = pnt.Z;//1.5240030480060962
Inherited Interfaces
Interfaces | Description |
---|---|
ISpatialReference2 | Provides access to additional members that control a SpatialReference. |
ISpatialReference | Provides access to members that control a SpatialReference. |
ISpatialReferenceInfo | Provides access to members that control the properties common to all components of a spatial reference system. |
Classes that implement ISpatialReference3
Classes | Description |
---|---|
GeographicCoordinateSystem | Creates a geographic coordinate system. |
ProjectedCoordinateSystem | Creates a projected coordinate system. |