#pragma once #include "vector.h" typedef struct { double x, y, z; } Vec3; static inline double vec3_magnitude(Vec3 v); static inline Vec3 vec3_diff(Vec3 a, Vec3 b); static inline Vec3 vec3_normalize(Vec3 v); static inline Vec3 vec3_mul(Vec3 v, double n);