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

#include <StaticMeshResources.h>

Public Member Functions

ENGINE_API FStaticMeshRenderData ()
 
ENGINE_API ~FStaticMeshRenderData ()
 
bool IsInitialized () const
 
ENGINE_API bool HasValidNaniteData () const
 
ENGINE_API bool HasNaniteFallbackMesh (EShaderPlatform ShaderPlatform) const
 
int32 GetNumNonStreamingLODs () const
 
int32 GetNumNonOptionalLODs () const
 
void Serialize (FArchive &Ar, UStaticMesh *Owner, bool bCooked)
 
void SerializeInlineDataRepresentations (FArchive &Ar, UStaticMesh *Owner)
 
void InitResources (ERHIFeatureLevel::Type InFeatureLevel, UStaticMesh *Owner)
 
ENGINE_API void ReleaseResources ()
 
ENGINE_API void GetResourceSizeEx (FResourceSizeEx &CumulativeResourceSize) const
 
ENGINE_API SIZE_T GetCPUAccessMemoryOverhead () const
 
ENGINE_API void AllocateLODResources (int32 NumLODs)
 
void ComputeUVDensities (UStaticMesh *Mesh)
 
void BuildAreaWeighedSamplingData ()
 
ENGINE_API void InitializeRayTracingRepresentationFromRenderingLODs ()
 
ENGINE_API int32 GetFirstValidLODIdx (int32 MinLODIdx) const
 
int32 GetCurrentFirstLODIdx (int32 MinLODIdx) const
 
const FStaticMeshLODResourcesGetCurrentFirstLOD (int32 MinLODIdx) const
 

Public Attributes

FStaticMeshLODResourcesArray LODResources
 
FStaticMeshVertexFactoriesArray LODVertexFactories
 
FPerPlatformFloat ScreenSize [MAX_STATIC_MESH_LODS]
 
TPimplPtr< Nanite::FResourcesNaniteResourcesPtr
 
FStaticMeshRayTracingProxyRayTracingProxy = nullptr
 
FBoxSphereBounds Bounds
 
bool bLODsShareStaticLighting
 
bool bHasNaniteFallbackMesh
 
bool bReadyForStreaming
 
uint8 NumInlinedLODs
 
uint8 CurrentFirstLODIdx
 
uint8 LODBiasModifier
 

Detailed Description

FStaticMeshRenderData - All data needed to render a static mesh.

Constructor & Destructor Documentation

◆ FStaticMeshRenderData()

FStaticMeshRenderData::FStaticMeshRenderData ( )

Default constructor.

◆ ~FStaticMeshRenderData()

FStaticMeshRenderData::~FStaticMeshRenderData ( )

Member Function Documentation

◆ AllocateLODResources()

void FStaticMeshRenderData::AllocateLODResources ( int32  NumLODs)

Allocate LOD resources.

◆ BuildAreaWeighedSamplingData()

void FStaticMeshRenderData::BuildAreaWeighedSamplingData ( )

◆ ComputeUVDensities()

void FStaticMeshRenderData::ComputeUVDensities ( UStaticMesh Mesh)

Update LOD-SECTION uv densities.

◆ GetCPUAccessMemoryOverhead()

SIZE_T FStaticMeshRenderData::GetCPUAccessMemoryOverhead ( ) const

Get the estimated memory overhead of buffers marked as NeedsCPUAccess.

◆ GetCurrentFirstLOD()

const FStaticMeshLODResources * FStaticMeshRenderData::GetCurrentFirstLOD ( int32  MinLODIdx) const
inline

Return the current first LOD that can be used for rendering starting at MinLODIdx. This takes into account the streaming status from CurrentFirstLODIdx, and MinLODIdx is expected to be UStaticMesh::MinLOD, which is platform specific.

◆ GetCurrentFirstLODIdx()

int32 FStaticMeshRenderData::GetCurrentFirstLODIdx ( int32  MinLODIdx) const
inline

Return the current first LODIdx that can be used.

◆ GetFirstValidLODIdx()

int32 FStaticMeshRenderData::GetFirstValidLODIdx ( int32  MinLODIdx) const

Return first valid LOD index starting at MinLODIdx.

◆ GetNumNonOptionalLODs()

int32 FStaticMeshRenderData::GetNumNonOptionalLODs ( ) const

Count the number of LODs that not optional and guarantied to be installed. Starting from the last LOD and stopping at the first optional LOD.

◆ GetNumNonStreamingLODs()

int32 FStaticMeshRenderData::GetNumNonStreamingLODs ( ) const

Count the number of LODs that are inlined and not streamable. Starting from the last LOD and stopping at the first non inlined LOD.

◆ GetResourceSizeEx()

void FStaticMeshRenderData::GetResourceSizeEx ( FResourceSizeEx CumulativeResourceSize) const

Compute the size of this resource.

◆ HasNaniteFallbackMesh()

bool FStaticMeshRenderData::HasNaniteFallbackMesh ( EShaderPlatform  ShaderPlatform) const

◆ HasValidNaniteData()

bool FStaticMeshRenderData::HasValidNaniteData ( ) const

◆ InitializeRayTracingRepresentationFromRenderingLODs()

void FStaticMeshRenderData::InitializeRayTracingRepresentationFromRenderingLODs ( )

◆ InitResources()

void FStaticMeshRenderData::InitResources ( ERHIFeatureLevel::Type  InFeatureLevel,
UStaticMesh Owner 
)

Initialize the render resources.

◆ IsInitialized()

bool FStaticMeshRenderData::IsInitialized ( ) const
inline

◆ ReleaseResources()

void FStaticMeshRenderData::ReleaseResources ( )

Releases the render resources.

◆ Serialize()

void FStaticMeshRenderData::Serialize ( FArchive Ar,
UStaticMesh Owner,
bool  bCooked 
)

Serialization.

◆ SerializeInlineDataRepresentations()

void FStaticMeshRenderData::SerializeInlineDataRepresentations ( FArchive Ar,
UStaticMesh Owner 
)

Serialize mesh build data which is inlined.

Member Data Documentation

◆ bHasNaniteFallbackMesh

bool FStaticMeshRenderData::bHasNaniteFallbackMesh

◆ bLODsShareStaticLighting

bool FStaticMeshRenderData::bLODsShareStaticLighting

True if LODs share static lighting data.

◆ Bounds

FBoxSphereBounds FStaticMeshRenderData::Bounds

Bounds of the renderable mesh.

◆ bReadyForStreaming

bool FStaticMeshRenderData::bReadyForStreaming

True if rhi resources are initialized

◆ CurrentFirstLODIdx

uint8 FStaticMeshRenderData::CurrentFirstLODIdx

◆ LODBiasModifier

uint8 FStaticMeshRenderData::LODBiasModifier

◆ LODResources

FStaticMeshLODResourcesArray FStaticMeshRenderData::LODResources

Per-LOD resources. For compatibility reasons, the FStaticMeshLODResources array are not referenced through TRefCountPtr. The LODResource still has a ref count of at least 1, see FStaticMeshLODResources() constructor.

◆ LODVertexFactories

FStaticMeshVertexFactoriesArray FStaticMeshRenderData::LODVertexFactories

◆ NaniteResourcesPtr

TPimplPtr<Nanite::FResources> FStaticMeshRenderData::NaniteResourcesPtr

◆ NumInlinedLODs

uint8 FStaticMeshRenderData::NumInlinedLODs

◆ RayTracingProxy

FStaticMeshRayTracingProxy* FStaticMeshRenderData::RayTracingProxy = nullptr

Ray tracing representation of this mesh, null if not present.

◆ ScreenSize

FPerPlatformFloat FStaticMeshRenderData::ScreenSize[MAX_STATIC_MESH_LODS]

Screen size to switch LODs


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