moved stuff around, added a grayscale test.

This commit is contained in:
Yggdrasil75
2025-11-11 14:34:19 -05:00
parent 5b7b6115a9
commit bff1efb291
13 changed files with 851 additions and 414 deletions

19
util/vectorlogic/vec.cpp Normal file
View File

@@ -0,0 +1,19 @@
#ifndef vec_hpp
#define vec_hpp
#include "Vec4.hpp"
#include "Vec3.hpp"
#include "Vec2.hpp"
Vec4::Vec4(const Vec3& vec3, float w) : x(vec3.x), y(vec3.y), z(vec3.z), w(w) {}
Vec3::Vec3(const Vec2& vec2, float z) : x(vec2.x), y(vec2.y), z(z) {}
Vec3 Vec4::xyz() const {
return Vec3(x, y, z);
}
Vec3 Vec4::rgb() const {
return Vec3(r, g, b);
}
#endif