diff --git a/filament/src/ShadowMapManager.h b/filament/src/ShadowMapManager.h index e45b0198c1..b35780ebe5 100644 --- a/filament/src/ShadowMapManager.h +++ b/filament/src/ShadowMapManager.h @@ -45,14 +45,10 @@ class FrameGraph; class RenderPass; struct ShadowMappingUniforms { - std::array lightFromWorldMatrix; math::float4 cascadeSplits; - float shadowBulbRadiusLs; - float shadowBias; float ssContactShadowDistance; uint32_t directionalShadows; uint32_t cascades; - bool elvsm; }; class ShadowMapManager { @@ -105,7 +101,7 @@ public: ShadowMap* getPointOrSpotShadowMap(size_t index) noexcept { assert_invariant(index < CONFIG_MAX_SHADOWMAPS); return std::launder(reinterpret_cast( - &mShadowMapCache[CONFIG_MAX_SHADOW_CASCADES + index])); + &mShadowMapCache[index])); } ShadowMap const* getPointOrSpotShadowMap(size_t spot) const noexcept { @@ -215,13 +211,13 @@ private: utils::FixedCapacityVector mSpotShadowMaps{ utils::FixedCapacityVector::with_capacity( - CONFIG_MAX_SHADOWMAPS) }; + CONFIG_MAX_SHADOWMAPS - CONFIG_MAX_SHADOW_CASCADES) }; // inline storage for all our ShadowMap objects, we can't easily use a std::array<> directly. // because ShadowMap doesn't have a default ctor, and we avoid out-of-line allocations. // Each ShadowMap is currently 40 bytes (total of 2.5KB for 64 shadow maps) using ShadowMapStorage = std::aligned_storage::type; - std::array mShadowMapCache; + std::array mShadowMapCache; }; } // namespace filament