Class ALcdDensityBasedElevationProvider

All Implemented Interfaces:
ILcdAltitudeProvider

public abstract class ALcdDensityBasedElevationProvider extends ALcdModelBasedTerrainElevationProvider
This abstract class implements ILcdAltitudeProvider. The height data is extracted from a set of models, provided by the user of this class using the following methods :
  • addModel( ILcdModel aModel )
  • removeModel( ILcdModel aModel )
  • removeAllModels()
To retrieve height data from the models, a set of ILcdHeightProviders is used, exactly one height provider for each model. This set of height providers is provided by the user by means of the abstract method createHeightProviderList().
Since:
9.1
  • Constructor Details

    • ALcdDensityBasedElevationProvider

      public ALcdDensityBasedElevationProvider()
      Defines an ALcdModelBasedTerrainElevationProvider which retrieves elevation values from the models, eventually choosing a raster based on the closest pixel density.
  • Method Details

    • retrieveElevationAt

      public double retrieveElevationAt(ILcdPoint aPoint, ILcdGeoReference aPointReference)
      Description copied from class: ALcdTerrainElevationProvider
      Returns the elevation for a given location, defined in meters above the geoid from the given location reference.

      Special elevation values should be interpreted as defined by the altitude descriptor (from ALcdTerrainElevationProvider.getAltitudeDescriptor()). Keep in mind that Double.NaN, Double.NEGATIVE_INFINITY and Double.POSITIVE_INFINITY can also be used as special values.

      Specified by:
      retrieveElevationAt in class ALcdTerrainElevationProvider
      Parameters:
      aPoint - The point indicating the location for which to retrieve the elevation.
      aPointReference - The reference in which the given location is defined. Note that the ellipsoid from this reference should be used to define the returning elevation value.
      Returns:
      the elevation for a given location, defined in meters above the ellipsoid.
    • createHeightProviderList

      protected abstract List<ILcdHeightProvider> createHeightProviderList()
      Creates a list of height providers. The result is a list of height providers containing exactly 1 ILcdHeightProvider for each model in the same order as the models. It is possible that for a specific ILcdModel no ILcdHeightProvider can be created. In that case the list should contain a null value.
      Returns:
      a list of height providers for each model.
    • addModel

      public void addModel(ILcdModel aModel)
      Description copied from class: ALcdModelBasedTerrainElevationProvider
      Add a model to the list of models to be taken into account for retrieving elevation data.
      Overrides:
      addModel in class ALcdModelBasedTerrainElevationProvider
      Parameters:
      aModel - The model to be added.
    • removeModel

      public void removeModel(ILcdModel aModel)
      Description copied from class: ALcdModelBasedTerrainElevationProvider
      Remove a model from list set of models to be taken into account for retrieving elevation data.
      Overrides:
      removeModel in class ALcdModelBasedTerrainElevationProvider
      Parameters:
      aModel - The model to be removed.
    • removeAllModels

      public void removeAllModels()
      Description copied from class: ALcdModelBasedTerrainElevationProvider
      Empty the list of models to be taken into account for retrieving elevation data.
      Overrides:
      removeAllModels in class ALcdModelBasedTerrainElevationProvider
    • getPixelDensityReference

      public ILcdGeoReference getPixelDensityReference()
      Gets the reference in which the pixel density is defined. The default is a geodetic reference with WGS84 geodetic datum. This means the pixel density is then defined in pixels per square degree.
      Returns:
      The pixel density reference.
      See Also:
    • setPixelDensityReference

      public void setPixelDensityReference(ILcdGeoReference aPixelDensityReference)
      Set the reference in which the pixel density is defined. The default is a geodetic reference with WGS84 geodetic datum. This means the pixel density is then defined in pixels per square degree.
      Parameters:
      aPixelDensityReference - The pixel density reference.
      See Also:
    • getPixelDensity

      public double getPixelDensity()
      Gets the pixel density value. The pixel density is defined with respect to the pixelDensityReference. This value is specified in pixels per square reference unit. When retrieving elevation data from a set of rasters, the raster with pixel density closest to this one is used.
      Returns:
      The pixel density.
      See Also:
    • setPixelDensity

      public void setPixelDensity(double aPixelDensity)
      Set the pixel density value.
      Parameters:
      aPixelDensity - The pixel density.
      See Also:
    • isClassTraceOn

      @Deprecated public static boolean isClassTraceOn()
      Deprecated.
      This method has been deprecated. It is recommended to use the standard Java logging framework directly.
      Returns true if tracing is enabled for this class.
      Returns:
      true if tracing is enabled for this class, false otherwise.
    • setClassTraceOn

      @Deprecated public static void setClassTraceOn(boolean aClassTraceOn)
      Deprecated.
      This method has been deprecated. It is recommended to use the standard Java logging framework directly.
      Enables tracing for all instances of this class. If the argument is true then all log messages are recorded, otherwise only the informative, warning and error messages are recorded.
      Parameters:
      aClassTraceOn - if true then all log messages are recorded, otherwise only the informative, warning and error messages are recorded.