|
|
Valtype * | ptr () noexcept |
| | Pointer accessor for direct copying.
|
|
const Valtype * | ptr () const noexcept |
| | Pointer accessor for direct copying.
|
|
Position & | Init () noexcept |
| | Initialisation to origin.
|
|
Position & | Transport (const Vector< Valtype > &v) noexcept |
| | Moves the position by v.
|
| template<typename Valtype2> |
| Position & | Rotate (const VectorBundle< Valtype, Valtype2 > &axis) noexcept |
| | Rotates a position by axis (length of axis.T make angle in radints).
|
| template<typename Valtype2> |
| Position & | Rotate (const VectorBundle< Valtype, Valtype2 > &axis, Valtype2 angle) noexcept |
| | Rotates a position by axis and angle in radiants.
|
| constexpr bool | Equals (const Position &p, Valtype epsilon=Valtype{0}) const noexcept |
| | Comparison within some range. The area within two positions regarded as equal is a sphere with radius epsilon.
|
|
Position & | Round (int toDigit) noexcept |
| | Rounds the positions values to a certain digit after the point.
|
|
template<typename Valtype2> |
| Position< Valtype > & | operator= (const Valtype2 *pVal) noexcept |
|
template<typename Valtype2> |
| Position< Valtype > & | Rotate (const VectorBundle< Valtype, Valtype2 > &axis) noexcept |
|
template<typename Valtype2> |
| Position< Valtype > & | Rotate (const VectorBundle< Valtype, Valtype2 > &axis, Valtype2 angle) noexcept |
- Parameters
-
| x | cartesian x coordinate. |
| y | cartesian y coordinate. |
| z | cartesian z coordinate. |
| v | Vector for explicit conversion.
|
| p2d | initializes x, y. z gets set to zero. |
| pVal | Array of three values. |
| sp | Spherical coordinates will get transformed to cartesian. |
|
|
constexpr | Position () noexcept=default |
| | Does not initialize the members.
|
|
constexpr | Position (Valtype x, Valtype y, Valtype z) noexcept |
| | Does not initialize the members.
|
|
| Position (const Vector< Valtype > &v)=delete |
| | Conversions between Vector and Position shouldn't be necessary and if needed anyhow explicitly specified.
|
|
template<typename Valtype2> |
| constexpr | Position (const VectorBundle< Valtype, Valtype2 > &b) noexcept |
| | Does not initialize the members.
|
|
constexpr | Position (const Position2D< Valtype > &p) noexcept |
| | Does not initialize the members.
|
|
template<typename Valtype2> |
| constexpr | Position (const PositionH< Valtype2 > &pos) noexcept |
| | Does not initialize the members.
|
|
template<typename Valtype2> |
| | Position (const Valtype2 *pVal) noexcept |
| | Does not initialize the members.
|
- Parameters
-
| p2d | initializes x, y. z gets set to zero. |
| pVal | Array of three values. |
| sp | Spherical coordinates will get transformed to cartesian. |
|
|
Position & | operator= (const Position2D< Valtype > &p2d) noexcept |
|
template<typename Valtype2> |
| Position & | operator= (const Valtype2 *pVal) noexcept |
- Returns
- Reference to value.
|
|
const Valtype & | operator[] (size_t index) const |
|
Valtype & | operator[] (size_t index) |
template<typename Valtype>
struct spat::Position< Valtype >
Implements a 3D - position in cartesian coordinates.
Specifies the coordinates of a point in 3D space. For Vectors, like e.g. surface normals, use the Vector type.