cesium-native  0.41.0
CesiumGeospatial::SimplePlanarEllipsoidCurve Class Referencefinal

Produces points on an ellipse that lies on a plane that intersects the center of the earth and each of the input coordinates. The height above the surface at each point along the curve will be a linear interpolation between the source and destination heights. More...

#include <CesiumGeospatial/SimplePlanarEllipsoidCurve.h>

Public Member Functions

glm::dvec3 getPosition (double percentage, double additionalHeight=0.0) const
 Samples the curve at the given percentage of its length. More...
 

Static Public Member Functions

static std::optional< SimplePlanarEllipsoidCurvefromEarthCenteredEarthFixedCoordinates (const Ellipsoid &ellipsoid, const glm::dvec3 &sourceEcef, const glm::dvec3 &destinationEcef)
 Creates a new instance of SimplePlanarEllipsoidCurve from a source and destination specified in Earth-Centered, Earth-Fixed coordinates. More...
 
static std::optional< SimplePlanarEllipsoidCurvefromLongitudeLatitudeHeight (const Ellipsoid &ellipsoid, const Cartographic &source, const Cartographic &destination)
 Creates a new instance of SimplePlanarEllipsoidCurve from a source and destination specified in cartographic coordinates (Longitude, Latitude, and Height). More...
 

Detailed Description

Produces points on an ellipse that lies on a plane that intersects the center of the earth and each of the input coordinates. The height above the surface at each point along the curve will be a linear interpolation between the source and destination heights.

Definition at line 19 of file SimplePlanarEllipsoidCurve.h.

Member Function Documentation

◆ fromEarthCenteredEarthFixedCoordinates()

static std::optional<SimplePlanarEllipsoidCurve> CesiumGeospatial::SimplePlanarEllipsoidCurve::fromEarthCenteredEarthFixedCoordinates ( const Ellipsoid ellipsoid,
const glm::dvec3 &  sourceEcef,
const glm::dvec3 &  destinationEcef 
)
static

Creates a new instance of SimplePlanarEllipsoidCurve from a source and destination specified in Earth-Centered, Earth-Fixed coordinates.

Parameters
ellipsoidThe ellipsoid that the source and destination positions are relative to.
sourceEcefThe position that the path will begin at in ECEF coordinates.
destinationEcefThe position that the path will end at in ECEF coordinates.
Returns
An optional type containing a SimplePlanarEllipsoidCurve object representing the generated path, if possible. If it wasn't possible to scale the input coordinates to geodetic surface coordinates on a WGS84 ellipsoid, this will return std::nullopt instead.

◆ fromLongitudeLatitudeHeight()

static std::optional<SimplePlanarEllipsoidCurve> CesiumGeospatial::SimplePlanarEllipsoidCurve::fromLongitudeLatitudeHeight ( const Ellipsoid ellipsoid,
const Cartographic source,
const Cartographic destination 
)
static

Creates a new instance of SimplePlanarEllipsoidCurve from a source and destination specified in cartographic coordinates (Longitude, Latitude, and Height).

Parameters
ellipsoidThe ellipsoid that these cartographic coordinates are from.
sourceLlhThe position that the path will begin at in Longitude, Latitude, and Height.
destinationLlhThe position that the path will end at in Longitude, Latitude, and Height.
Returns
An optional type containing a SimplePlanarEllipsoidCurve object representing the generated path, if possible. If it wasn't possible to scale the input coordinates to geodetic surface coordinates on a WGS84 ellipsoid, this will return std::nullopt instead.

◆ getPosition()

glm::dvec3 CesiumGeospatial::SimplePlanarEllipsoidCurve::getPosition ( double  percentage,
double  additionalHeight = 0.0 
) const

Samples the curve at the given percentage of its length.

Parameters
percentageThe percentage of the curve's length to sample at, where 0 is the beginning and 1 is the end. This value will be clamped to the range [0..1].
additionalHeightThe height above the earth at this position will be calculated by interpolating between the height at the beginning and end of the curve based on the value of percentage. This parameter specifies an additional offset to add to the height.
Returns
The position of the given point on this curve in Earth-Centered Earth-Fixed coordinates.

The documentation for this class was generated from the following file: