Vector2#
File: samarium/math/Vector2.hpp
-
namespace sm
Typedefs
Functions
-
template<typename T>
struct Vector2_t# Represents a canonical Euclidean vector, ie an arrow in space
auto vec = Vector2{.x = 42, .y = -3.1415};
- Template Parameters:
T – type of x and y, required to be integral or floating point
Public Functions
-
inline constexpr auto length() const noexcept#
-
inline constexpr auto length_sq() const noexcept#
-
inline constexpr auto angle() const noexcept#
-
inline constexpr auto slope() const noexcept#
Public Static Functions
-
static inline constexpr auto make(auto x_coord, auto y_coord)#
-
struct Polar#
-
namespace literals#
-
template<typename T>