Move Vectormath main
C++20 game and graphics mathematics
Loading...
Searching...
No Matches
Constants.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <concepts>
4#include <numbers>
5
6namespace mv::math
7{
8 template <std::floating_point T>
9 inline constexpr T Pi = std::numbers::pi_v<T>;
10
11 template <std::floating_point T>
12 inline constexpr T HalfPi = Pi<T> / T(2);
13
14 template <std::floating_point T>
15 inline constexpr T QuarterPi = Pi<T> / T(4);
16
17 template <std::floating_point T>
18 inline constexpr T Tau = Pi<T> * T(2);
19} // namespace mv::math
constexpr T QuarterPi
Definition Constants.hpp:15
constexpr T Pi
Definition Constants.hpp:9
constexpr T HalfPi
Definition Constants.hpp:12
constexpr T Tau
Definition Constants.hpp:18