rewrite celestial angles classes (add normalization)
This commit is contained in:
@@ -476,6 +476,93 @@ std::string MccAngleFancyString(std::convertible_to<MccAngle> auto const& ang,
|
||||
|
||||
/* HELPER TYPES TO REPERESENT ANGLES ON THE CELESTIAL SPHERE */
|
||||
|
||||
template <MccAngle::norm_kind_t NORM_KIND>
|
||||
class MccCelestialAngle : public MccAngle
|
||||
{
|
||||
public:
|
||||
template <typename... CtorArgTs>
|
||||
MccCelestialAngle(CtorArgTs&&... args) : MccAngle(std::forward<CtorArgTs>(args)...)
|
||||
{
|
||||
normalize<NORM_KIND>();
|
||||
}
|
||||
|
||||
MccCelestialAngle(MccCelestialAngle const&) = default;
|
||||
MccCelestialAngle(MccCelestialAngle&&) = default;
|
||||
|
||||
MccCelestialAngle& operator=(MccCelestialAngle const&) = default;
|
||||
MccCelestialAngle& operator=(MccCelestialAngle&&) = default;
|
||||
};
|
||||
|
||||
class MccAngleRA_ICRS : public MccCelestialAngle<MccAngle::NORM_KIND_0_360>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_0_360>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleDEC_ICRS : public MccCelestialAngle<MccAngle::NORM_KIND_90_90>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_90_90>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleRA_APP : public MccCelestialAngle<MccAngle::NORM_KIND_0_360>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_0_360>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleDEC_APP : public MccCelestialAngle<MccAngle::NORM_KIND_90_90>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_90_90>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleRA_OBS : public MccCelestialAngle<MccAngle::NORM_KIND_0_360>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_0_360>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleDEC_OBS : public MccCelestialAngle<MccAngle::NORM_KIND_90_90>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_90_90>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
|
||||
class MccAngleHA_APP : public MccCelestialAngle<MccAngle::NORM_KIND_180_180>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_180_180>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleHA_OBS : public MccCelestialAngle<MccAngle::NORM_KIND_180_180>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_180_180>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
|
||||
class MccAngleAZ : public MccCelestialAngle<MccAngle::NORM_KIND_0_360>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_0_360>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleZD : public MccCelestialAngle<MccAngle::NORM_KIND_0_180>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_0_180>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
class MccAngleALT : public MccCelestialAngle<MccAngle::NORM_KIND_90_90>
|
||||
{
|
||||
public:
|
||||
using MccCelestialAngle<MccAngle::NORM_KIND_90_90>::MccCelestialAngle;
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
class MccNamedAngle : public MccAngle
|
||||
{
|
||||
public:
|
||||
@@ -573,7 +660,7 @@ public:
|
||||
using MccNamedAngle::MccNamedAngle;
|
||||
// using MccAngle::MccAngle;
|
||||
};
|
||||
|
||||
*/
|
||||
|
||||
class MccAngleX : public MccAngle // some co-longitude coordinate
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user