UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FDynamicMeshEmitterData Struct Reference

#include <ParticleHelper.h>

+ Inheritance diagram for FDynamicMeshEmitterData:

Public Member Functions

 FDynamicMeshEmitterData (const UParticleModuleRequired *RequiredModule)
 
virtual ~FDynamicMeshEmitterData ()
 
uint32 GetMeshLODIndexFromProxy (const FParticleSystemSceneProxy *InOwnerProxy) const
 
void Init (bool bInSelected, const FParticleMeshEmitterInstance *InEmitterInstance, UStaticMesh *InStaticMesh, bool InUseStaticMeshLODs, float InLODSizeScale, ERHIFeatureLevel::Type InFeatureLevel)
 
virtual void UpdateRenderThreadResourcesEmitter (const FParticleSystemSceneProxy *InOwnerProxy) override
 
virtual void ReleaseRenderThreadResources (const FParticleSystemSceneProxy *InOwnerProxy) override
 
virtual void GetDynamicMeshElementsEmitter (const FParticleSystemSceneProxy *Proxy, const FSceneView *View, const FSceneViewFamily &ViewFamily, int32 ViewIndex, FMeshElementCollector &Collector) const override
 
void GetInstanceData (void *InstanceData, void *DynamicParameterData, void *PrevTransformBuffer, const FParticleSystemSceneProxy *Proxy, const FSceneView *View, uint32 InstanceFactor) const
 
void GetParticleTransform (const FBaseParticle &InParticle, const FParticleSystemSceneProxy *Proxy, const FSceneView *View, FMatrix &OutTransformMat) const
 
void GetParticlePrevTransform (const FBaseParticle &InParticle, const FParticleSystemSceneProxy *Proxy, const FSceneView *View, FMatrix &OutTransformMat) const
 
void CalculateParticleTransform (const FMatrix &ProxyLocalToWorld, const FVector &ParticleLocation, float ParticleRotation, const FVector3f &ParticleVelocity, const FVector3f &ParticleSize, const FVector3f &ParticlePayloadInitialOrientation, const FVector3f &ParticlePayloadRotation, const FVector &ParticlePayloadCameraOffset, const FVector3f &ParticlePayloadOrbitOffset, const FVector &ViewOrigin, const FVector3f &ViewDirection, FMatrix &OutTransformMat) const
 
virtual void GatherSimpleLights (const FParticleSystemSceneProxy *Proxy, const FSceneViewFamily &ViewFamily, FSimpleLightArray &OutParticleLights) const override
 
virtual int32 GetDynamicVertexStride (ERHIFeatureLevel::Type) const override
 
virtual int32 GetDynamicParameterVertexStride () const override
 
virtual const FDynamicSpriteEmitterReplayDataBaseGetSourceData () const override
 
void SetupVertexFactory (FRHICommandListBase &RHICmdList, FMeshParticleVertexFactory *InVertexFactory, const FStaticMeshLODResources &LODResources, uint32 LODIdx) const
 
virtual const FDynamicEmitterReplayDataBaseGetSource () const override
 
- Public Member Functions inherited from FDynamicSpriteEmitterDataBase
 FDynamicSpriteEmitterDataBase (const UParticleModuleRequired *RequiredModule)
 
virtual ~FDynamicSpriteEmitterDataBase ()
 
const FMaterialRenderProxyGetMaterialRenderProxy ()
 
void SortSpriteParticles (int32 SortMode, bool bLocalSpace, int32 ParticleCount, const uint8 *ParticleData, int32 ParticleStride, const uint16 *ParticleIndices, const FSceneView *View, const FMatrix &LocalToWorld, FParticleOrder *ParticleOrder) const
 
virtual void GetIndexAllocInfo (int32 &OutNumIndices, int32 &OutStride) const
 
virtual void RenderDebug (const FParticleSystemSceneProxy *Proxy, FPrimitiveDrawInterface *PDI, const FSceneView *View, bool bCrosses) const
 
virtual void DoBufferFill (FAsyncBufferFillData &Me) const
 
void BuildViewFillData (const FParticleSystemSceneProxy *Proxy, const FSceneView *InView, int32 InVertexCount, int32 InVertexSize, int32 InDynamicParameterVertexSize, FGlobalDynamicIndexBuffer &DynamicIndexBuffer, FGlobalDynamicVertexBuffer &DynamicVertexBuffer, FGlobalDynamicVertexBufferAllocation &DynamicVertexAllocation, FGlobalDynamicIndexBufferAllocation &DynamicIndexAllocation, FGlobalDynamicVertexBufferAllocation *DynamicParameterAllocation, FAsyncBufferFillData &Data) const
 
- Public Member Functions inherited from FDynamicEmitterDataBase
 FDynamicEmitterDataBase (const class UParticleModuleRequired *RequiredModule)
 
virtual ~FDynamicEmitterDataBase ()
 
voidoperator new (size_t Size)
 
void operator delete (void *RawMemory, size_t Size)
 
virtual const FMacroUVOverrideGetMacroUVOverride () const
 

Public Attributes

FDynamicMeshEmitterReplayData Source
 
int32 LastFramePreRendered
 
UStaticMeshStaticMesh
 
TArray< FMaterialRenderProxy *, TInlineAllocator< 2 > > MeshMaterials
 
uint32 MeshTypeDataOffset
 
uint32 bApplyPreRotation:1
 
uint32 bUseMeshLockedAxis:1
 
uint32 bUseCameraFacing:1
 
uint32 bApplyParticleRotationAsSpin:1
 
uint32 bFaceCameraDirectionRatherThanPosition:1
 
uint8 CameraFacingOption
 
bool bUseStaticMeshLODs
 
float LODSizeScale
 
int32 LastCalculatedMeshLOD
 
const FParticleMeshEmitterInstanceEmitterInstance
 
- Public Attributes inherited from FDynamicSpriteEmitterDataBase
const FMaterialRenderProxyMaterialResource
 
uint32 bUsesDynamicParameter:1
 
- Public Attributes inherited from FDynamicEmitterDataBase
TStatId StatID
 
uint32 bSelected:1
 
uint32 bValid:1
 
int32 EmitterIndex
 

Detailed Description

Dynamic emitter data for Mesh emitters

Constructor & Destructor Documentation

◆ FDynamicMeshEmitterData()

FDynamicMeshEmitterData::FDynamicMeshEmitterData ( const UParticleModuleRequired RequiredModule)

◆ ~FDynamicMeshEmitterData()

FDynamicMeshEmitterData::~FDynamicMeshEmitterData ( )
virtual

Member Function Documentation

◆ CalculateParticleTransform()

void FDynamicMeshEmitterData::CalculateParticleTransform ( const FMatrix ProxyLocalToWorld,
const FVector ParticleLocation,
float  ParticleRotation,
const FVector3f ParticleVelocity,
const FVector3f ParticleSize,
const FVector3f ParticlePayloadInitialOrientation,
const FVector3f ParticlePayloadRotation,
const FVector ParticlePayloadCameraOffset,
const FVector3f ParticlePayloadOrbitOffset,
const FVector ViewOrigin,
const FVector3f ViewDirection,
FMatrix OutTransformMat 
) const

◆ GatherSimpleLights()

void FDynamicMeshEmitterData::GatherSimpleLights ( const FParticleSystemSceneProxy Proxy,
const FSceneViewFamily ViewFamily,
FSimpleLightArray OutParticleLights 
) const
overridevirtual

Gathers simple lights for this emitter.

Reimplemented from FDynamicEmitterDataBase.

◆ GetDynamicMeshElementsEmitter()

void FDynamicMeshEmitterData::GetDynamicMeshElementsEmitter ( const FParticleSystemSceneProxy Proxy,
const FSceneView View,
const FSceneViewFamily ViewFamily,
int32  ViewIndex,
FMeshElementCollector Collector 
) const
overridevirtual

Reimplemented from FDynamicEmitterDataBase.

◆ GetDynamicParameterVertexStride()

virtual int32 FDynamicMeshEmitterData::GetDynamicParameterVertexStride ( ) const
inlineoverridevirtual

Get the vertex stride for the dynamic parameter rendering data

Reimplemented from FDynamicSpriteEmitterDataBase.

◆ GetDynamicVertexStride()

virtual int32 FDynamicMeshEmitterData::GetDynamicVertexStride ( ERHIFeatureLevel::Type  ) const
inlineoverridevirtual

Get the vertex stride for the dynamic rendering data

Reimplemented from FDynamicSpriteEmitterDataBase.

◆ GetInstanceData()

void FDynamicMeshEmitterData::GetInstanceData ( void InstanceData,
void DynamicParameterData,
void PrevTransformBuffer,
const FParticleSystemSceneProxy Proxy,
const FSceneView View,
uint32  InstanceFactor 
) const

Retrieve the instance data required to render this emitter. Render-thread only

Parameters
InstanceDataThe memory to fill the vertex data into
DynamicParameterDataThe memory to fill the vertex dynamic parameter data into
PrevTransformBufferThe memory to fill the vertex prev transform data into. May be null
ProxyThe scene proxy for the particle system that owns this emitter
ViewThe scene view being rendered
InstanceFactorThe factor to duplicate instances by

◆ GetMeshLODIndexFromProxy()

uint32 FDynamicMeshEmitterData::GetMeshLODIndexFromProxy ( const FParticleSystemSceneProxy InOwnerProxy) const

◆ GetParticlePrevTransform()

void FDynamicMeshEmitterData::GetParticlePrevTransform ( const FBaseParticle InParticle,
const FParticleSystemSceneProxy Proxy,
const FSceneView View,
FMatrix OutTransformMat 
) const

◆ GetParticleTransform()

void FDynamicMeshEmitterData::GetParticleTransform ( const FBaseParticle InParticle,
const FParticleSystemSceneProxy Proxy,
const FSceneView View,
FMatrix OutTransformMat 
) const

Helper function for retrieving the particle transform.

Parameters
InParticleThe particle being processed
ProxyThe scene proxy for the particle system that owns this emitter
ViewThe scene view being rendered
OutTransformThe InstanceToWorld transform matrix for the particle

◆ GetSource()

virtual const FDynamicEmitterReplayDataBase & FDynamicMeshEmitterData::GetSource ( ) const
inlineoverridevirtual

Returns the source data for this particle system

Implements FDynamicEmitterDataBase.

◆ GetSourceData()

virtual const FDynamicSpriteEmitterReplayDataBase * FDynamicMeshEmitterData::GetSourceData ( ) const
inlineoverridevirtual

Get the source replay data for this emitter

Reimplemented from FDynamicSpriteEmitterDataBase.

◆ Init()

void FDynamicMeshEmitterData::Init ( bool  bInSelected,
const FParticleMeshEmitterInstance InEmitterInstance,
UStaticMesh InStaticMesh,
bool  InUseStaticMeshLODs,
float  InLODSizeScale,
ERHIFeatureLevel::Type  InFeatureLevel 
)

Initialize this emitter's dynamic rendering data, called after source data has been filled in

◆ ReleaseRenderThreadResources()

void FDynamicMeshEmitterData::ReleaseRenderThreadResources ( const FParticleSystemSceneProxy InOwnerProxy)
overridevirtual

Release the render thread resources for this emitter data

Parameters
InOwnerProxyThe proxy that owns this dynamic emitter data
Returns
bool true if successful, false if failed

Reimplemented from FDynamicEmitterDataBase.

◆ SetupVertexFactory()

void FDynamicMeshEmitterData::SetupVertexFactory ( FRHICommandListBase RHICmdList,
FMeshParticleVertexFactory InVertexFactory,
const FStaticMeshLODResources LODResources,
uint32  LODIdx 
) const

Initialize this emitter's vertex factory with the vertex buffers from the mesh's rendering data.

◆ UpdateRenderThreadResourcesEmitter()

void FDynamicMeshEmitterData::UpdateRenderThreadResourcesEmitter ( const FParticleSystemSceneProxy InOwnerProxy)
overridevirtual

Create the render thread resources for this emitter data

Parameters
InOwnerProxyThe proxy that owns this dynamic emitter data
Returns
bool true if successful, false if failed

Reimplemented from FDynamicEmitterDataBase.

Member Data Documentation

◆ bApplyParticleRotationAsSpin

uint32 FDynamicMeshEmitterData::bApplyParticleRotationAsSpin

If true, apply 'sprite' particle rotation about the orientation axis (direction mesh is pointing). If false, apply 'sprite' particle rotation about the camera facing axis.

◆ bApplyPreRotation

uint32 FDynamicMeshEmitterData::bApplyPreRotation

If true, apply the 'pre-rotation' values to the mesh.

◆ bFaceCameraDirectionRatherThanPosition

uint32 FDynamicMeshEmitterData::bFaceCameraDirectionRatherThanPosition

If true, all camera facing options will point the mesh against the camera's view direction rather than pointing at the cameras location. If false, the camera facing will point to the cameras position as normal.

◆ bUseCameraFacing

uint32 FDynamicMeshEmitterData::bUseCameraFacing

If true, then use the camera facing options supplied. Trumps all other settings.

◆ bUseMeshLockedAxis

uint32 FDynamicMeshEmitterData::bUseMeshLockedAxis

If true, then use the locked axis setting supplied. Trumps locked axis module and/or TypeSpecific mesh settings.

◆ bUseStaticMeshLODs

bool FDynamicMeshEmitterData::bUseStaticMeshLODs

◆ CameraFacingOption

uint8 FDynamicMeshEmitterData::CameraFacingOption

The EMeshCameraFacingOption setting to use if bUseCameraFacing is true.

◆ EmitterInstance

const FParticleMeshEmitterInstance* FDynamicMeshEmitterData::EmitterInstance

◆ LastCalculatedMeshLOD

int32 FDynamicMeshEmitterData::LastCalculatedMeshLOD
mutable

◆ LastFramePreRendered

int32 FDynamicMeshEmitterData::LastFramePreRendered

◆ LODSizeScale

float FDynamicMeshEmitterData::LODSizeScale

◆ MeshMaterials

TArray<FMaterialRenderProxy*, TInlineAllocator<2> > FDynamicMeshEmitterData::MeshMaterials

◆ MeshTypeDataOffset

uint32 FDynamicMeshEmitterData::MeshTypeDataOffset

offset to FMeshTypeDataPayload

◆ Source

FDynamicMeshEmitterReplayData FDynamicMeshEmitterData::Source

The frame source data for this particle system. This is everything needed to represent this this particle system frame. It does not include any transient rendering thread data. Also, for non-simulating 'replay' particle systems, this data may have come straight from disk!

◆ StaticMesh

UStaticMesh* FDynamicMeshEmitterData::StaticMesh

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