move vec to generated

This commit is contained in:
Asuro
2025-03-30 19:45:48 +02:00
parent b006d14197
commit 052fc2cc07
16 changed files with 662 additions and 289 deletions

View File

@@ -1,6 +1,8 @@
#include "../Log.h"
#include "Dither.h"
using namespace Generated;
void DitherGen(DitherData& data, int32_t recursion)
{
data.Points[0] = {0.0f, 0.0f};
@@ -55,7 +57,7 @@ void DitherGen(DitherData& data, int32_t recursion)
{
Vec2 vec = point - data.Points[i];
Vec2 wrappedVec{bx::mod(vec.x + 0.5f, 1.0f) - 0.5f, bx::mod(vec.y + 0.5f, 1.0f) - 0.5f};
float curDist = wrappedVec.Magnitude();
float curDist = Magnitude(wrappedVec);
dist = bx::min(dist, curDist);
}