UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FVirtualShadowMapPerLightCacheEntry Class Reference

#include <VirtualShadowMapCacheManager.h>

Public Member Functions

 FVirtualShadowMapPerLightCacheEntry (int32 MaxPersistentScenePrimitiveIndex, uint32 NumShadowMaps)
 
void OnPrimitiveRendered (const FPrimitiveSceneInfo *PrimitiveSceneInfo, bool bPrimitiveRevealed)
 
bool IsFullyCached () const
 
bool IsUncached () const
 
bool ShouldUseReceiverMask () const
 
void MarkRendered (int32 FrameIndex)
 
void Invalidate ()
 
bool IsInvalidated () const
 
void MarkScheduled (int32 FrameIndex)
 
int32 GetLastScheduledFrameNumber () const
 
void UpdateVirtualShadowMapId (int32 NextVirtualShadowMapId)
 
int32 GetVirtualShadowMapId () const
 
int32 GetPrevVirtualShadowMapId () const
 
void UpdateClipmap (const FVector &LightDirection, int FirstLevel, bool bForceInvalidate, bool bInUseReceiverMask)
 
void UpdateLocal (const FProjectedShadowInitializer &InCacheKey, const FVector &NewLightOrigin, const float NewLightRadius, bool bNewIsDistantLight, bool bForceInvalidate, bool bAllowInvalidation, bool bInUseReceiverMask)
 
bool AffectsBounds (const FBoxSphereBounds &Bounds) const
 

Public Attributes

int32 RenderedFrameNumber = -1
 
int32 ScheduledFrameNumber = -1
 
int32 PrevVirtualShadowMapId = INDEX_NONE
 
int32 VirtualShadowMapId = INDEX_NONE
 
bool bIsUncached = false
 
bool bIsDistantLight = false
 
bool bUseReceiverMask = false
 
bool bReferencedThisRender = false
 
uint32 LastReferencedFrameNumber = 0
 
TBitArray RenderedPrimitives
 
TArray< FVirtualShadowMapCacheEntryShadowMapEntries
 
TArray< FVirtualShadowMapInstanceRangePrimitiveInstancesToInvalidate
 

Constructor & Destructor Documentation

◆ FVirtualShadowMapPerLightCacheEntry()

FVirtualShadowMapPerLightCacheEntry::FVirtualShadowMapPerLightCacheEntry ( int32  MaxPersistentScenePrimitiveIndex,
uint32  NumShadowMaps 
)
inline

Member Function Documentation

◆ AffectsBounds()

bool FVirtualShadowMapPerLightCacheEntry::AffectsBounds ( const FBoxSphereBounds Bounds) const
inline

◆ GetLastScheduledFrameNumber()

int32 FVirtualShadowMapPerLightCacheEntry::GetLastScheduledFrameNumber ( ) const
inline

◆ GetPrevVirtualShadowMapId()

int32 FVirtualShadowMapPerLightCacheEntry::GetPrevVirtualShadowMapId ( ) const
inline

◆ GetVirtualShadowMapId()

int32 FVirtualShadowMapPerLightCacheEntry::GetVirtualShadowMapId ( ) const
inline

◆ Invalidate()

void FVirtualShadowMapPerLightCacheEntry::Invalidate ( )
inline

◆ IsFullyCached()

bool FVirtualShadowMapPerLightCacheEntry::IsFullyCached ( ) const
inline

The (local) VSM is fully cached if it is distant and has been rendered to previously "Fully" implies that we know all pages are mapped as well as rendered to (ignoring potential CPU-side object culling).

◆ IsInvalidated()

bool FVirtualShadowMapPerLightCacheEntry::IsInvalidated ( ) const
inline

◆ IsUncached()

bool FVirtualShadowMapPerLightCacheEntry::IsUncached ( ) const
inline

◆ MarkRendered()

void FVirtualShadowMapPerLightCacheEntry::MarkRendered ( int32  FrameIndex)
inline

◆ MarkScheduled()

void FVirtualShadowMapPerLightCacheEntry::MarkScheduled ( int32  FrameIndex)
inline

◆ OnPrimitiveRendered()

void FVirtualShadowMapPerLightCacheEntry::OnPrimitiveRendered ( const FPrimitiveSceneInfo PrimitiveSceneInfo,
bool  bPrimitiveRevealed 
)

◆ ShouldUseReceiverMask()

bool FVirtualShadowMapPerLightCacheEntry::ShouldUseReceiverMask ( ) const
inline

◆ UpdateClipmap()

void FVirtualShadowMapPerLightCacheEntry::UpdateClipmap ( const FVector LightDirection,
int  FirstLevel,
bool  bForceInvalidate,
bool  bInUseReceiverMask 
)

◆ UpdateLocal()

void FVirtualShadowMapPerLightCacheEntry::UpdateLocal ( const FProjectedShadowInitializer InCacheKey,
const FVector NewLightOrigin,
const float  NewLightRadius,
bool  bNewIsDistantLight,
bool  bForceInvalidate,
bool  bAllowInvalidation,
bool  bInUseReceiverMask 
)

◆ UpdateVirtualShadowMapId()

void FVirtualShadowMapPerLightCacheEntry::UpdateVirtualShadowMapId ( int32  NextVirtualShadowMapId)

Member Data Documentation

◆ bIsDistantLight

bool FVirtualShadowMapPerLightCacheEntry::bIsDistantLight = false

◆ bIsUncached

bool FVirtualShadowMapPerLightCacheEntry::bIsUncached = false

◆ bReferencedThisRender

bool FVirtualShadowMapPerLightCacheEntry::bReferencedThisRender = false

◆ bUseReceiverMask

bool FVirtualShadowMapPerLightCacheEntry::bUseReceiverMask = false

◆ LastReferencedFrameNumber

uint32 FVirtualShadowMapPerLightCacheEntry::LastReferencedFrameNumber = 0

◆ PrevVirtualShadowMapId

int32 FVirtualShadowMapPerLightCacheEntry::PrevVirtualShadowMapId = INDEX_NONE

◆ PrimitiveInstancesToInvalidate

TArray<FVirtualShadowMapInstanceRange> FVirtualShadowMapPerLightCacheEntry::PrimitiveInstancesToInvalidate

◆ RenderedFrameNumber

int32 FVirtualShadowMapPerLightCacheEntry::RenderedFrameNumber = -1

◆ RenderedPrimitives

TBitArray FVirtualShadowMapPerLightCacheEntry::RenderedPrimitives

◆ ScheduledFrameNumber

int32 FVirtualShadowMapPerLightCacheEntry::ScheduledFrameNumber = -1

◆ ShadowMapEntries

TArray<FVirtualShadowMapCacheEntry> FVirtualShadowMapPerLightCacheEntry::ShadowMapEntries

◆ VirtualShadowMapId

int32 FVirtualShadowMapPerLightCacheEntry::VirtualShadowMapId = INDEX_NONE

The documentation for this class was generated from the following files: