sKit  0.0.9
math.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include <glm/mat4x4.hpp>
4 
5 namespace sKit {
6 
8 namespace math {
9 
44 auto map(
45  float value,
46  float inputMin,
47  float inputMax,
48  float outputMin,
49  float outputMax,
50  bool clamp = true
51 ) -> float;
52 
54 auto flatten(const glm::mat4& mat) -> std::array<float, 16>;
55 
56 } // namespace math
57 } // namespace sKit
sKit::math::flatten
auto flatten(const glm::mat4 &mat) -> std::array< float, 16 >
flattens a 4x4 matrix with row major order
Definition: math.cpp:42
sKit
Definition: camera.hpp:8
sKit::math::map
auto map(float value, float inputMin, float inputMax, float outputMin, float outputMax, bool clamp) -> float
Given a value and an input range, map the value to an output range.
Definition: math.cpp:10