AABB blocks render simplified

This commit is contained in:
MihailRis
2023-12-28 20:03:25 +03:00
parent 3f9e36e682
commit b8d7e89f0b
3 changed files with 41 additions and 62 deletions
+3 -3
View File
@@ -28,14 +28,14 @@ struct CoordSystem {
glm::ivec3 axisX;
glm::ivec3 axisY;
glm::ivec3 axisZ;
// Grid 3d position fix offset (for negative vectors)
glm::ivec3 fix;
glm::ivec3 fix2;
CoordSystem() = default;
CoordSystem(glm::ivec3 axisX, glm::ivec3 axisY, glm::ivec3 axisZ, glm::ivec3 fix);
CoordSystem(glm::ivec3 axisX, glm::ivec3 axisY, glm::ivec3 axisZ);
void transform(AABB& aabb);
void transform(AABB& aabb) const;
static bool isVectorHasNegatives(glm::ivec3 vec) {
if (vec.x < 0 || vec.y < 0 || vec.z < 0) {