Class TLspAboveTerrainCameraConstraint3D<T extends TLspViewXYZWorldTransformation3D>


public class TLspAboveTerrainCameraConstraint3D<T extends TLspViewXYZWorldTransformation3D> extends ALspCameraConstraint<T>
Camera constraint that makes sure the camera stays above the terrain. The minimum altitude above the terrain can be controlled using setMinAltitude.
  • Constructor Details

    • TLspAboveTerrainCameraConstraint3D

      public TLspAboveTerrainCameraConstraint3D()
  • Method Details

    • getMinAltitude

      public double getMinAltitude()
      Returns the minimum altitude over the terrain the eye point should have.
      the minimum altitude.
    • setMinAltitude

      public void setMinAltitude(double aMinAltitude)
      Sets the minimum altitude over the terrain the eye point should have. The default value is 20.
      aMinAltitude - the minimum altitude.
    • constrain

      public void constrain(T aSource, T aTargetSFCT)
      Description copied from class: ALspCameraConstraint

      Constrains the given view world transformation. This method can be implemented by modifying aTargetSFCT.

      When the original view world transformation is modified, the changes are first applied on a copy of the transformation (aTargetSFCT). This copy is passed to the constraints, which can also modify it. After all constraints are evaluated, all changes are applied on the original transformation.

      aSource is the original transformation. It is given as context information.

      Specified by:
      constrain in class ALspCameraConstraint<T extends TLspViewXYZWorldTransformation3D>
      aSource - the original transformation, on which all changes will be applied after all constraints are evaluated. It is given as context information.
      aTargetSFCT - the view transformation copy which contains the modifications. Constraints should be applied on this transformation.