fix: broken normals when packing unitvec3 for t6

This commit is contained in:
Jan 2024-09-07 08:48:49 +02:00
parent 7eb1714e89
commit 2c47212b52
No known key found for this signature in database
GPG Key ID: 44B581F78FF5C57C

View File

@ -44,7 +44,7 @@ namespace pack32
PackUtil32 z;
z.f = (in[2] - -24624.0939334638f) * 0.0001218318939208984f;
return x.u | y.u << 10u | z.u << 20u;
return (x.u & 0x3FF) | (y.u & 0x3FF) << 10u | (z.u & 0x3FF) << 20u;
}
uint32_t Vec4PackGfxColor(const float (&in)[4])