public class TLcdImageHeightProvider extends Object implements ILcdHeightProvider
sampling mode
of the image into account.
Assuming interpolation
is off:
Constructor and Description |
---|
TLcdImageHeightProvider(ALcdBasicImage aImage)
Create a new height provider.
|
TLcdImageHeightProvider(ALcdBasicImage aImage,
ALcdImagingEngine aImagingEngine)
Create a new height provider for a given image and imaging engine.
|
TLcdImageHeightProvider(ALcdBasicImage aImage,
ALcdImagingEngine aImagingEngine,
int aMinValidHeight,
int aMaxValidHeight)
Create a new height provider for a given image and imaging engine.
|
TLcdImageHeightProvider(ALcdImageMosaic aImageMosaic)
Create a new height provider using a default imaging engine.
|
TLcdImageHeightProvider(ALcdImageMosaic aImageMosaic,
ALcdImagingEngine aImagingEngine)
Create a new height provider.
|
TLcdImageHeightProvider(ALcdImageMosaic aImageMosaic,
ALcdImagingEngine aImagingEngine,
int aMinValidHeight,
int aMaxValidHeight)
Create a new height provider.
|
Modifier and Type | Method and Description |
---|---|
ILcdBounds |
getBounds()
Returns the
ILcdBounds by which the geometry of this ILcdBounded object
is bounded. |
double |
retrieveHeightAt(ILcdPoint aPoint)
Returns the height at the given point.
|
void |
setInterpolate(boolean aInterpolate)
Set whether height values should be interpolated.
|
public TLcdImageHeightProvider(ALcdBasicImage aImage)
Double.NaN
).aImage
- image to read elevation values frompublic TLcdImageHeightProvider(ALcdBasicImage aImage, ALcdImagingEngine aImagingEngine)
Double.NaN
).
If the given imaging engine is null
, a default imaging engine will be used.aImage
- image to read elevation values fromaImagingEngine
- imaging engine to use or null
to use the defaultpublic TLcdImageHeightProvider(ALcdBasicImage aImage, ALcdImagingEngine aImagingEngine, int aMinValidHeight, int aMaxValidHeight)
null
, a default imaging engine will be used.aImage
- image to read elevation values fromaImagingEngine
- imaging engine to use or null
to use the defaultaMinValidHeight
- the minimum valid heightaMaxValidHeight
- the maximum valid heightpublic TLcdImageHeightProvider(ALcdImageMosaic aImageMosaic)
Double.NaN
).aImageMosaic
- image mosaic to read elevation values frompublic TLcdImageHeightProvider(ALcdImageMosaic aImageMosaic, ALcdImagingEngine aImagingEngine)
Double.NaN
).
If the given imaging engine is null
, a default imaging engine will be used.aImageMosaic
- image mosaic to read elevation values fromaImagingEngine
- imaging engine to use or null
to use the defaultpublic TLcdImageHeightProvider(ALcdImageMosaic aImageMosaic, ALcdImagingEngine aImagingEngine, int aMinValidHeight, int aMaxValidHeight)
null
, a default imaging engine will be used.aImageMosaic
- image mosaic to read elevation values fromaImagingEngine
- imaging engine to use or null
to use the defaultaMinValidHeight
- the minimum valid heightaMaxValidHeight
- the maximum valid heightpublic void setInterpolate(boolean aInterpolate)
aInterpolate
- true if height values should be interpolated.public double retrieveHeightAt(ILcdPoint aPoint)
ILcdHeightProvider
retrieveHeightAt
in interface ILcdHeightProvider
aPoint
- a 2D point, in the horizontal reference that is determined by
the implementation.Double.NaN
, if the elevation is not known.public final ILcdBounds getBounds()
ILcdBounded
ILcdBounds
by which the geometry of this ILcdBounded
object
is bounded.
If the geometry does not allow retrieving valid bounds (for example a polyline with 0 points)
the return value is unspecified.
It is highly recommended to return an undefined
bounds.
You can create undefined bounds using the default constructors
of TLcdLonLatBounds
or TLcdXYBounds
.
getBounds
in interface ILcdBounded
ILcdBounds
by which the geometry of this ILcdBounded
object
is bounded.