#pragma once #include //---------------------- Vector Types ---------------------- // TODO: make generic, as per glm struct vec2 { float x, y; }; //---------------------- Geometric Functions ---------------------- // These functions implement the Geometric Functions section of GLSL static inline float dot(const vec2& v, const vec2& u) { return v.x * u.x + v.y * u.y; } static inline float length(const vec2& v) { return sqrt(dot(v, v)); }