SpatiumLib
Public Member Functions | Friends | List of all members
spatium::geom3d::Spheroid Class Reference

Spheroid geometry. More...

#include <Spheroid.h>

Inheritance diagram for spatium::geom3d::Spheroid:
Inheritance graph
[legend]
Collaboration diagram for spatium::geom3d::Spheroid:
Collaboration graph
[legend]

Public Member Functions

 Spheroid (const Point3 &origin, double axisXY, double axisZ)
 Constructor. More...
 
 Spheroid (double axisXY, double axisZ)
 Constructor. More...
 
 Spheroid (const Spheroid &other)=default
 Copy constructor. More...
 
Spheroidoperator= (const Spheroid &other)=default
 Assignment operator. More...
 
virtual ~Spheroid ()=default
 Destructor. More...
 
void axisXY (double axisXY)
 Set X and Y axis length. More...
 
double axisXY () const
 Get X and Y axis length. More...
 
- Public Member Functions inherited from spatium::geom3d::Ellipsoid
 Ellipsoid (const Point3 &origin, double axisX, double axisY, double axisZ)
 Constructor. More...
 
 Ellipsoid (double axisX, double axisY, double axisZ)
 Constructor. More...
 
 Ellipsoid (const Ellipsoid &other)=default
 Copy constructor. More...
 
Ellipsoidoperator= (const Ellipsoid &other)=default
 Assignment operator. More...
 
virtual ~Ellipsoid ()=default
 Destructor. More...
 
void origin (const Point3 &origin)
 Set origin of ellipsoid. More...
 
Point3 origin () const
 Get origin of ellipsoid. More...
 
void axisX (double axisX)
 Set the X axis length. More...
 
double axisX () const
 Get the X axis length. More...
 
void axisY (double axisY)
 Set the Y axis length. More...
 
double axisY () const
 Get the Y axis length. More...
 
void axisZ (double axisZ)
 Set the Z axis length. More...
 
double axisZ () const
 Get the Z axis length. More...
 
double distanceTo (const Point3 &point) const override
 Compute Euclidean distance to point. More...
 
Point3 projectPoint (const Point3 &point) const override
 Project point onto ellipsoid. More...
 
bool intersectLine (const Point3 &origin, const Vector3 &direction, Point3 &intersection) const override
 Intersect line with ellipsoid. More...
 
Vector3 surfaceNormal (const Point3 &point) const
 Compute surface normal at given point. More...
 
Point3 pointOnHorizon (const Point3 &point, double direction, bool poleLimit=false)
 Compute point on horizon in a given direction. More...
 
- Public Member Functions inherited from spatium::geom3d::Geometry
 Geometry ()=default
 
virtual ~Geometry ()=default
 

Friends

std::ostream & operator<< (std::ostream &os, const Spheroid &spheroid)
 Output to ostream. More...
 

Additional Inherited Members

- Protected Member Functions inherited from spatium::geom3d::Ellipsoid
void updateTransformation ()
 Update the transformation parameters that transform a sphere into this ellipsoid. These parameters are internally used to represent the ellipsoid as a transformed sphere. More...
 
- Protected Attributes inherited from spatium::geom3d::Ellipsoid
Matrix4x4 m_ellipsoidalTransformation
 
Matrix4x4 m_ellipsoidalTransformationInverse
 
Point3 m_origin
 
double m_axisX
 
double m_axisY
 
double m_axisZ
 

Detailed Description

Spheroid geometry.

A spheroid is an ellipsoid with two equal semi-diamters.

A spheroid is defined by a point (origin) and two radii:

Parametric description = (x^2 + y^2) / a^2 + z^2 / c^2 = 1

Constructor & Destructor Documentation

◆ Spheroid() [1/3]

spatium::geom3d::Spheroid::Spheroid ( const Point3 origin,
double  axisXY,
double  axisZ 
)
inline

Constructor.

Parameters
[in]originOrigin
[in]axisXYX and Y axis length
[in]axisZZ axis length

◆ Spheroid() [2/3]

spatium::geom3d::Spheroid::Spheroid ( double  axisXY,
double  axisZ 
)
inline

Constructor.

Parameters
[in]axisXYX and Y axis length
[in]axisZZ axis length

◆ Spheroid() [3/3]

spatium::geom3d::Spheroid::Spheroid ( const Spheroid other)
default

Copy constructor.

◆ ~Spheroid()

virtual spatium::geom3d::Spheroid::~Spheroid ( )
virtualdefault

Destructor.

Member Function Documentation

◆ axisXY() [1/2]

void spatium::geom3d::Spheroid::axisXY ( double  axisXY)
inline

Set X and Y axis length.

Parameters
[in]axisXYX and Y axis length.

◆ axisXY() [2/2]

double spatium::geom3d::Spheroid::axisXY ( ) const
inline

Get X and Y axis length.

Returns
X and Y axis length

◆ operator=()

Spheroid& spatium::geom3d::Spheroid::operator= ( const Spheroid other)
default

Assignment operator.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
const Spheroid spheroid 
)
friend

Output to ostream.


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