summary refs log tree commit diff
path: root/src/Math
diff options
context:
space:
mode:
Diffstat (limited to 'src/Math')
-rw-r--r--src/Math/Vector.hpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Math/Vector.hpp b/src/Math/Vector.hpp
index 3525e42..d179049 100644
--- a/src/Math/Vector.hpp
+++ b/src/Math/Vector.hpp
@@ -204,6 +204,12 @@ struct Vector {
     T& w() { static_assert(S > 3); return elements[3]; }
     const T& w() const { static_assert(S > 3); return elements[3]; }
 
+    std::array<T, S> values() const {
+        std::array<T, S> result{};
+        for (UInt i = 0; i < S; i++) result[i] = elements[i];
+        return result;
+    }
+
     std::string string() const {
         std::stringstream str{};