diff options
Diffstat (limited to 'utility/stream_support.hpp')
-rw-r--r-- | utility/stream_support.hpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/utility/stream_support.hpp b/utility/stream_support.hpp index 6ab1bd1..9561e58 100644 --- a/utility/stream_support.hpp +++ b/utility/stream_support.hpp @@ -5,7 +5,7 @@ template<glm::length_t L, glm::length_t R, typename T, glm::qualifier Q> std::ostream & -operator<<(std::ostream & s, glm::mat<L, R, T, Q> & m) +operator<<(std::ostream & s, const glm::mat<L, R, T, Q> & m) { for (int y = 0; y < m.length(); y++) { const auto & col = m[y]; @@ -17,4 +17,14 @@ operator<<(std::ostream & s, glm::mat<L, R, T, Q> & m) return s; } +template<glm::length_t L, typename T, glm::qualifier Q> +std::ostream & +operator<<(std::ostream & s, const glm::vec<L, T, Q> & v) +{ + for (int x = 0; x < L; x++) { + s << v[x] << ", "; + } + return s; +} + #endif |