MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / QuantizeResolution

Function QuantizeResolution

Source/Engine/Renderer/ShadowsPass.cpp:55–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53};
54
55uint16 QuantizeResolution(float input)
56{
57 uint16 output = Math::FloorToInt(input);
58 uint16 alignment = 32;
59 if (output >= 512)
60 alignment = 128;
61 else if (output >= 256)
62 alignment = 64;
63 output = Math::AlignDown<uint16>(output, alignment);
64 return output;
65}
66
67// State for shadow projection
68struct ShadowAtlasLightTile

Callers 1

SetupShadowsMethod · 0.85

Calls 1

FloorToIntFunction · 0.50

Tested by

no test coverage detected