21 concept StrongScalarType = std::is_same_v<T, deg64> || std::is_same_v<T, deg32> || std::is_same_v<T, rad64> || std::is_same_v<T, rad32>;
39 constexpr operator deg32() const noexcept;
61 constexpr operator deg64() const noexcept;
70 constexpr auto to_deg64(
this rad64 self)
noexcept ->
deg64;
71 constexpr auto to_deg32(
this rad64 self)
noexcept ->
deg32;
79 constexpr auto to_rad64(
this rad32 self)
noexcept ->
rad64;
80 constexpr auto to_deg64(
this rad32 self)
noexcept ->
deg64;
81 constexpr auto to_deg32(
this rad32 self)
noexcept ->
deg32;
97 constexpr deg64::operator
deg32() const noexcept
113 constexpr deg32::operator
deg64() const noexcept
137 return rad64{ self._value };
152 return {
static_cast<ice::f64>(value) };
157 template<StrongScalarType ScalarType, SimpleNumberType NumberType>
158 inline constexpr auto operator*(ScalarType left, NumberType right)
noexcept -> ScalarType
160 return { left.raw_value() * right };
163 template<StrongScalarType ScalarType, SimpleNumberType NumberType>
164 inline constexpr auto operator/(ScalarType left, NumberType right)
noexcept -> ScalarType
166 return { left.raw_value() / right };
Definition algorithm.hxx:8
rad32 rad
Definition angles.hxx:170
static constexpr ice::f32 f32_pi
Definition constants.hxx:11
deg32 deg
Definition angles.hxx:169
static constexpr ice::f64 f64_pi
Definition constants.hxx:15
double f64
Definition types.hxx:17
float f32
Definition types.hxx:16
constexpr auto to_rad64(this deg32 self) noexcept -> rad64
Definition angles.hxx:103
f32 _value
Definition angles.hxx:63
constexpr auto to_rad32(this deg32 self) noexcept -> rad32
Definition angles.hxx:108
constexpr auto operator/(this deg32 self, SimpleNumberType auto number) noexcept -> deg32
Definition angles.hxx:48
constexpr auto operator-(this deg32 self, SimpleNumberType auto number) noexcept -> deg32
Definition angles.hxx:50
constexpr auto operator<=>(this deg32 self, SimpleNumberType auto other) noexcept
Definition angles.hxx:54
constexpr auto raw_value(this deg32 self) noexcept -> f32
Definition angles.hxx:57
constexpr auto operator+(this deg32 self, deg32 other) noexcept -> deg32
Definition angles.hxx:51
constexpr auto operator-(this deg32 self, deg32 other) noexcept -> deg32
Definition angles.hxx:52
constexpr auto operator*(this deg32 self, SimpleNumberType auto number) noexcept -> deg32
Definition angles.hxx:47
constexpr auto operator<=>(this deg32 self, deg32 other) noexcept
Definition angles.hxx:55
constexpr auto operator+(this deg32 self, SimpleNumberType auto number) noexcept -> deg32
Definition angles.hxx:49
constexpr auto operator<=>(this deg64 self, SimpleNumberType auto other) noexcept
Definition angles.hxx:32
constexpr auto operator*(this deg64 self, SimpleNumberType auto number) noexcept -> deg64
Definition angles.hxx:25
constexpr auto operator<=>(this deg64 self, deg64 other) noexcept
Definition angles.hxx:33
f64 _value
Definition angles.hxx:42
constexpr auto operator-(this deg64 self, SimpleNumberType auto number) noexcept -> deg64
Definition angles.hxx:28
constexpr auto to_rad64(this deg64 self) noexcept -> rad64
Definition angles.hxx:87
constexpr auto to_rad32(this deg64 self) noexcept -> rad32
Definition angles.hxx:92
constexpr auto operator+(this deg64 self, SimpleNumberType auto number) noexcept -> deg64
Definition angles.hxx:27
constexpr auto operator/(this deg64 self, SimpleNumberType auto number) noexcept -> deg64
Definition angles.hxx:26
constexpr auto raw_value(this deg64 self) noexcept -> f64
Definition angles.hxx:35
constexpr auto operator-(this deg64 self, deg64 other) noexcept -> deg64
Definition angles.hxx:30
constexpr auto operator+(this deg64 self, deg64 other) noexcept -> deg64
Definition angles.hxx:29
constexpr auto to_deg64(this rad32 self) noexcept -> deg64
Definition angles.hxx:140
constexpr auto to_rad64(this rad32 self) noexcept -> rad64
Definition angles.hxx:135
constexpr auto to_deg32(this rad32 self) noexcept -> deg32
Definition angles.hxx:145
constexpr auto raw_value(this rad32 self) noexcept -> f32
Definition angles.hxx:78
f32 _value
Definition angles.hxx:83
constexpr auto to_deg32(this rad64 self) noexcept -> deg32
Definition angles.hxx:129
constexpr auto to_rad32(this rad64 self) noexcept -> rad32
Definition angles.hxx:119
f64 _value
Definition angles.hxx:73
constexpr auto to_deg64(this rad64 self) noexcept -> deg64
Definition angles.hxx:124
constexpr auto raw_value(this rad64 self) noexcept -> f64
Definition angles.hxx:68