Construct a low precision spatial reference with the same scale factor as the high precision input, but with a different domain extent. If the calculated domain extent cannot cover the specified data extent, an error is returned.
[Visual Basic .NET] Public Function ConstructLowPrecisionSpatialReference ( _ ByVal bMatchPrecision As Boolean, _ ByVal inSR As ISpatialReference, _ ByVal dataExtent As IEnvelope _ ) As ISpatialReference
[C#] public ISpatialReference ConstructLowPrecisionSpatialReference ( bool bMatchPrecision, ISpatialReference inSR, IEnvelope dataExtent );
[C++]
HRESULT ConstructLowPrecisionSpatialReference(
VARIANT_BOOL bMatchPrecision,
ISpatialReference* inSR,
IEnvelope* dataExtent,
ISpatialReference** ppOutSR
);
[C++]Parameters
bMatchPrecision bMatchPrecision is a parameter of type VARIANT_BOOL inSRinSR is a parameter of type ISpatialReference
dataExtentdataExtent is a parameter of type IEnvelope
ppOutSR [out, retval]ppOutSR is a parameter of type ISpatialReference
Product Availability
Errors Returned
E_INVALID_ARG - This error is returned if a low precision spatial reference is passed into InSR.
-2147220986 FDO_E_IMPLEMENTATION
If maintainPrecision = True and the data extent cannot be covered with a low precision spatial reference the following error is returned: a low precision spatial reference cannot cover the specified extent at the input precision. To successfully create a low precision spatial reference you must either reduce the data extent or set maintainPrecision = False.
Remarks
ConstructLowPrecisionSpatialReference creates a low precision copy of an existing high precision spatial reference.
- bMatchPrecision indicates whether the output low precision spatial reference should have the same resolution as the input high precision spatial reference. If not, then pExtent is used to help determine the output resolution.
- pInSR is the existing high precision spatial reference. Passing in a low precision spatial reference will return an error.
- pExtent is used to determine the output resolution
when matching the input resolultion is not desired.
ConstructLowPrecisionSpatialReference delegates to the existing
method
IGeometryEnvironment::ConstructDomainExtent in that
case, which attempts to enlarge the extent by a factor of 1.5
(clipped against the horizon extent). If an empty envelope is
passed in and bMatchPrecision is FALSE, then the low precision
version of
ISpatialReferenceResolution::ConstructFromHorizon is
used for GeographicCoordinateSystems or ProjectedCoordinateSystems.
If bMatchPrecision is true, then an attempt is made to use the
domain extent as the new domain extent; the precision is
not matched in this case.