This commit is contained in:
Бранимир Караџић
2024-03-29 16:36:55 -07:00
parent 8ec4b71303
commit 2ad67a4dfd
15 changed files with 218 additions and 189 deletions

View File

@@ -362,7 +362,7 @@ public:
if (bgfx::isValid(m_rb) )
{
struct Packed { uint8_t bgra[4]; } arr = bx::bit_cast<Packed>(m_lumBgra8);
struct Packed { uint8_t bgra[4]; } arr = bx::bitCast<Packed>(m_lumBgra8);
float exponent = arr.bgra[3] / 255.0f * 255.0f - 128.0f;
float lumAvg = arr.bgra[2] / 255.0f * bx::exp2(exponent);

View File

@@ -45,7 +45,7 @@ uint32_t packF4u(float _x, float _y = 0.0f, float _z = 0.0f, float _w = 0.0f)
arr.value[2] = uint8_t(_z * 127.0f + 128.0f);
arr.value[3] = uint8_t(_w * 127.0f + 128.0f);
return bx::bit_cast<uint32_t>(arr);
return bx::bitCast<uint32_t>(arr);
}
static PosTangentBitangentTexcoordVertex s_cubeVertices[24] =