 |
Flutter Impeller
|
|
Go to the documentation of this file.
5 #ifndef FLUTTER_IMPELLER_GEOMETRY_SCALAR_H_
6 #define FLUTTER_IMPELLER_GEOMETRY_SCALAR_H_
20 template <
class T,
class = std::enable_if_t<std::is_arithmetic_v<T>>>
22 return val >= T{} ? val : -val;
67 #endif // FLUTTER_IMPELLER_GEOMETRY_SCALAR_H_
constexpr Degrees()=default
constexpr float kEhCloseEnough
constexpr Scalar Absolute< Scalar >(const float &val)
constexpr Radians()=default
constexpr bool ScalarNearlyZero(Scalar x, Scalar tolerance=kEhCloseEnough)
constexpr T Absolute(const T &val)
constexpr Radians(Scalar p_radians)
constexpr bool ScalarNearlyEqual(Scalar x, Scalar y, Scalar tolerance=kEhCloseEnough)
constexpr Degrees(Scalar p_degrees)