This commit is contained in:
2025-08-27 17:55:57 +03:00
parent 9fb33e5bec
commit 45f655dc90
6 changed files with 229 additions and 5 deletions

View File

@@ -23,6 +23,21 @@ constexpr double operator""_arcsecs(long double val) // angle in arc seconds
return val * std::numbers::pi / 180.0 / 3600.0;
}
constexpr double operator""_hours(long double val) // angle in hours
{
return val * std::numbers::pi / 12.0;
}
constexpr double operator""_mins(long double val) // angle in hour minutes
{
return val * std::numbers::pi / 12.0 / 60.0;
}
constexpr double operator""_secs(long double val) // angle in hour seconds
{
return val * std::numbers::pi / 12.0 / 3600.0;
}
constexpr double operator""_dms(const char* s, size_t size) // as a string "DEGREES:MINUTES:SECONDS"
{
auto res = mcc::utils::parsAngleString(std::span{s, size});