siderust-cpp
Header-only C++ wrapper for siderust
Loading...
Searching...
No Matches
frames.hpp File Reference

Zero-sized reference-frame tag types mirroring Rust's affn::frames. More...

#include "ffi_core.hpp"
Include dependency graph for frames.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  siderust::frames::is_frame< F, typename >
 Concept-like compile-time check (C++17: constexpr bool). More...
 
struct  siderust::frames::is_frame< F, std::void_t< decltype(FrameTraits< F >::ffi_id)> >
 
struct  siderust::frames::ICRS
 International Celestial Reference System. More...
 
struct  siderust::frames::ICRF
 International Celestial Reference Frame (treated ≡ ICRS). More...
 
struct  siderust::frames::EclipticMeanJ2000
 Mean ecliptic & equinox of J2000.0. More...
 
struct  siderust::frames::EclipticOfDate
 Ecliptic of date (precessed mean obliquity, no nutation). More...
 
struct  siderust::frames::EclipticTrueOfDate
 True ecliptic of date (precessed + nutated). More...
 
struct  siderust::frames::EquatorialMeanJ2000
 Mean equatorial of J2000.0 (FK5-aligned). More...
 
struct  siderust::frames::EquatorialMeanOfDate
 Mean equatorial of date (precessed, no nutation). More...
 
struct  siderust::frames::EquatorialTrueOfDate
 True equatorial of date (precessed + nutated). More...
 
struct  siderust::frames::Horizontal
 Local horizontal (topocentric alt-az). More...
 
struct  siderust::frames::Galactic
 Galactic coordinate system (IAU 1958). More...
 
struct  siderust::frames::ECEF
 Earth-Centered Earth-Fixed. More...
 
struct  siderust::frames::ITRF
 International Terrestrial Reference Frame. More...
 
struct  siderust::frames::CIRS
 Celestial Intermediate Reference System. More...
 
struct  siderust::frames::GCRS
 Geocentric Celestial Reference System. More...
 
struct  siderust::frames::TIRS
 Terrestrial Intermediate Reference System. More...
 
struct  siderust::frames::EclipticMeanOfDate
 Ecliptic mean of date (alias for EclipticOfDate). More...
 
struct  siderust::frames::SphericalNaming< F >
 Maps a frame to its conventional spherical-coordinate names. More...
 
struct  siderust::frames::SphericalNaming< ICRS >
 
struct  siderust::frames::SphericalNaming< ICRF >
 
struct  siderust::frames::SphericalNaming< EquatorialMeanJ2000 >
 
struct  siderust::frames::SphericalNaming< EquatorialMeanOfDate >
 
struct  siderust::frames::SphericalNaming< EquatorialTrueOfDate >
 
struct  siderust::frames::SphericalNaming< Horizontal >
 
struct  siderust::frames::SphericalNaming< Galactic >
 
struct  siderust::frames::SphericalNaming< EclipticMeanJ2000 >
 
struct  siderust::frames::has_ra_dec< F >
 True for equatorial frames that expose right-ascension / declination. More...
 
struct  siderust::frames::has_ra_dec< ICRS >
 
struct  siderust::frames::has_ra_dec< ICRF >
 
struct  siderust::frames::has_ra_dec< EquatorialMeanJ2000 >
 
struct  siderust::frames::has_ra_dec< EquatorialMeanOfDate >
 
struct  siderust::frames::has_ra_dec< EquatorialTrueOfDate >
 
struct  siderust::frames::has_az_alt< F >
 True for the horizontal frame that exposes azimuth / altitude. More...
 
struct  siderust::frames::has_az_alt< Horizontal >
 
struct  siderust::frames::has_lon_lat< F >
 True for ecliptic and galactic frames that use longitude / latitude. More...
 
struct  siderust::frames::has_lon_lat< EclipticMeanJ2000 >
 
struct  siderust::frames::has_lon_lat< EclipticOfDate >
 
struct  siderust::frames::has_lon_lat< EclipticTrueOfDate >
 
struct  siderust::frames::has_lon_lat< Galactic >
 
struct  siderust::frames::has_lon_lat< CIRS >
 
struct  siderust::frames::has_lon_lat< GCRS >
 
struct  siderust::frames::has_lon_lat< TIRS >
 
struct  siderust::frames::has_lon_lat< ECEF >
 
struct  siderust::frames::has_lon_lat< ITRF >
 
struct  siderust::frames::has_frame_transform< From, To >
 Marks frame pairs for which a FrameRotationProvider exists in siderust-ffi. More...
 
struct  siderust::frames::has_frame_transform< F, F >
 
struct  siderust::frames::has_horizontal_transform< F >
 Marks frames from which to_horizontal is reachable. More...
 
struct  siderust::frames::has_horizontal_transform< ICRS >
 
struct  siderust::frames::has_horizontal_transform< ICRF >
 
struct  siderust::frames::has_horizontal_transform< EclipticMeanJ2000 >
 
struct  siderust::frames::has_horizontal_transform< EquatorialMeanJ2000 >
 
struct  siderust::frames::has_horizontal_transform< EquatorialMeanOfDate >
 
struct  siderust::frames::has_horizontal_transform< EquatorialTrueOfDate >
 

Namespaces

namespace  siderust
 
namespace  siderust::frames
 

Macros

#define SIDERUST_DEFINE_FRAME(Tag, EnumVal, Label)
 
#define SIDERUST_FRAME_TRANSFORM_PAIR(A, B)
 

Functions

 siderust::frames::SIDERUST_DEFINE_FRAME (ICRS, SIDERUST_FRAME_T_ICRS, "ICRS")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (ICRF, SIDERUST_FRAME_T_ICRF, "ICRF")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (EclipticMeanJ2000, SIDERUST_FRAME_T_ECLIPTIC_MEAN_J2000, "EclipticMeanJ2000")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (EclipticOfDate, SIDERUST_FRAME_T_ECLIPTIC_OF_DATE, "EclipticOfDate")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (EclipticTrueOfDate, SIDERUST_FRAME_T_ECLIPTIC_TRUE_OF_DATE, "EclipticTrueOfDate")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (EquatorialMeanJ2000, SIDERUST_FRAME_T_EQUATORIAL_MEAN_J2000, "EquatorialMeanJ2000")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (EquatorialMeanOfDate, SIDERUST_FRAME_T_EQUATORIAL_MEAN_OF_DATE, "EquatorialMeanOfDate")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (EquatorialTrueOfDate, SIDERUST_FRAME_T_EQUATORIAL_TRUE_OF_DATE, "EquatorialTrueOfDate")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (Horizontal, SIDERUST_FRAME_T_HORIZONTAL, "Horizontal")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (Galactic, SIDERUST_FRAME_T_GALACTIC, "Galactic")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (ECEF, SIDERUST_FRAME_T_ECEF, "ECEF")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (ITRF, SIDERUST_FRAME_T_ITRF, "ITRF")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (CIRS, SIDERUST_FRAME_T_CIRS, "CIRS")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (GCRS, SIDERUST_FRAME_T_GCRS, "GCRS")
 
 siderust::frames::SIDERUST_DEFINE_FRAME (TIRS, SIDERUST_FRAME_T_TIRS, "TIRS")
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRS, EclipticMeanJ2000)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRS, EquatorialMeanJ2000)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRS, EquatorialMeanOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRS, EquatorialTrueOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (EclipticMeanJ2000, EquatorialMeanJ2000)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (EclipticMeanJ2000, EquatorialMeanOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (EclipticMeanJ2000, EquatorialTrueOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (EquatorialMeanJ2000, EquatorialMeanOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (EquatorialMeanJ2000, EquatorialTrueOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (EquatorialMeanOfDate, EquatorialTrueOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRF, EclipticMeanJ2000)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRF, EquatorialMeanJ2000)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRF, EquatorialMeanOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRF, EquatorialTrueOfDate)
 
 siderust::frames::SIDERUST_FRAME_TRANSFORM_PAIR (ICRF, ICRS)
 

Variables

template<typename F >
constexpr bool siderust::frames::is_frame_v = is_frame<F>::value
 
template<typename F >
constexpr bool siderust::frames::has_ra_dec_v = has_ra_dec<F>::value
 
template<typename F >
constexpr bool siderust::frames::has_az_alt_v = has_az_alt<F>::value
 
template<typename F >
constexpr bool siderust::frames::has_lon_lat_v = has_lon_lat<F>::value
 
template<typename From , typename To >
constexpr bool siderust::frames::has_frame_transform_v = has_frame_transform<From, To>::value
 
template<typename F >
constexpr bool siderust::frames::has_horizontal_transform_v = has_horizontal_transform<F>::value
 

Detailed Description

Zero-sized reference-frame tag types mirroring Rust's affn::frames.

Each frame is a unique empty struct used as a compile-time tag for coordinate templates. Every tag carries a static ffi_id that maps to the runtime siderust_frame_t C enum, and a human-readable name.

Definition in file frames.hpp.

Macro Definition Documentation

◆ SIDERUST_DEFINE_FRAME

#define SIDERUST_DEFINE_FRAME (   Tag,
  EnumVal,
  Label 
)
Value:
template <> \
struct FrameTraits<Tag> { \
static constexpr siderust_frame_t ffi_id = EnumVal; \
static constexpr const char* name() { return Label; } \
}

Definition at line 83 of file frames.hpp.

◆ SIDERUST_FRAME_TRANSFORM_PAIR

#define SIDERUST_FRAME_TRANSFORM_PAIR (   A,
 
)
Value:
template <> \
struct has_frame_transform<A, B> : std::true_type {}; \
template <> \
struct has_frame_transform<B, A> : std::true_type {}

Definition at line 257 of file frames.hpp.