UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
Chaos::Softs::FVelocityAndPressureField Class Referencefinal

#include <VelocityField.h>

Public Member Functions

 FVelocityAndPressureField (const FCollectionPropertyConstFacade &PropertyCollection)
 
 FVelocityAndPressureField (const FSolverParticlesRange &Particles, const FTriangleMesh *TriangleMesh, const FCollectionPropertyConstFacade &PropertyCollection, const TMap< FString, TConstArrayView< FRealSingle > > &Weightmaps, FSolverReal WorldScale)
 
 FVelocityAndPressureField ()
 
 ~FVelocityAndPressureField ()
 
CHAOS_API void UpdateForces (const FSolverParticles &InParticles, const FSolverReal)
 
void Apply (FSolverParticles &InParticles, const FSolverReal Dt, const int32 Index) const
 
CHAOS_API void Apply (FSolverParticlesRange &InParticles, const FSolverReal Dt) const
 
CHAOS_API void SetProperties (const FCollectionPropertyConstFacade &PropertyCollection, const TMap< FString, TConstArrayView< FRealSingle > > &Weightmaps, FSolverReal WorldScale, bool bEnableAerodynamics)
 
CHAOS_API void SetPropertiesAndWind (const FCollectionPropertyConstFacade &PropertyCollection, const TMap< FString, TConstArrayView< FRealSingle > > &Weightmaps, FSolverReal WorldScale, bool bEnableAerodynamics, const FSolverVec3 &SolverWind, const FRotation3 &LocalSpaceRotation=FRotation3::Identity, const FRotation3 &ReferenceSpaceRotation=FRotation3::Identity)
 
CHAOS_API void SetProperties (const FSolverVec2 &Drag, const FSolverVec2 &OuterDrag, const FSolverVec2 &Lift, const FSolverVec2 &OuterLift, const FSolverReal FluidDensity, const FSolverVec2 &Pressure=FSolverVec2::ZeroVector, FSolverReal WorldScale=1.f)
 
bool IsActive () const
 
CHAOS_API void SetGeometry (const FTriangleMesh *TriangleMesh, const FCollectionPropertyConstFacade &PropertyCollection, const TMap< FString, TConstArrayView< FRealSingle > > &Weightmaps, FSolverReal WorldScale)
 
CHAOS_API void SetGeometry (const FTriangleMesh *TriangleMesh, const TConstArrayView< FRealSingle > &DragMultipliers, const TConstArrayView< FRealSingle > &OuterDragMultipliers, const TConstArrayView< FRealSingle > &LiftMultipliers, const TConstArrayView< FRealSingle > &OuterLiftMultipliers, const TConstArrayView< FRealSingle > &PressureMultipliers)
 
void SetGeometry (const FTriangleMesh *TriangleMesh, const TConstArrayView< FRealSingle > &DragMultipliers, const TConstArrayView< FRealSingle > &LiftMultipliers, const TConstArrayView< FRealSingle > &PressureMultipliers=TConstArrayView< FRealSingle >())
 
void SetVelocity (const FSolverVec3 &InVelocity)
 
const FSolverVec3GetVelocity () const
 
TConstArrayView< TVector< int32, 3 > > GetElements () const
 
TConstArrayView< FSolverVec3GetForces () const
 
CHAOS_API FSolverVec3 CalculateForce (const TConstArrayView< FSolverVec3 > &Xs, const TConstArrayView< FSolverVec3 > &Vs, int32 ElementIndex) const
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (Drag, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (OuterDrag, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (Lift, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (OuterLift, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (FluidDensity, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (Pressure, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (TurbulenceRatio, float)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (WindVelocity, FVector3f)
 
 UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME (WindVelocitySpace, int32)
 

Static Public Member Functions

static bool IsEnabled (const FCollectionPropertyConstFacade &PropertyCollection)
 

Static Public Attributes

static constexpr FSolverReal DefaultDragCoefficient = (FSolverReal)0.5
 
static constexpr FSolverReal DefaultLiftCoefficient = (FSolverReal)0.1
 
static constexpr FSolverReal DefaultFluidDensity = (FSolverReal)1.225
 
static constexpr FSolverReal MinCoefficient = (FSolverReal)0.
 
static constexpr FSolverReal MaxCoefficient = (FSolverReal)10.
 
static constexpr EChaosSoftsSimulationSpace DefaultWindVelocitySpace = EChaosSoftsSimulationSpace::WorldSpace
 
static constexpr FSolverReal DefaultTurbulenceRatio = (FSolverReal)1.f
 

Constructor & Destructor Documentation

◆ FVelocityAndPressureField() [1/3]

Chaos::Softs::FVelocityAndPressureField::FVelocityAndPressureField ( const FCollectionPropertyConstFacade PropertyCollection)
inlineexplicit

◆ FVelocityAndPressureField() [2/3]

Chaos::Softs::FVelocityAndPressureField::FVelocityAndPressureField ( const FSolverParticlesRange Particles,
const FTriangleMesh TriangleMesh,
const FCollectionPropertyConstFacade PropertyCollection,
const TMap< FString, TConstArrayView< FRealSingle > > &  Weightmaps,
FSolverReal  WorldScale 
)
inline

◆ FVelocityAndPressureField() [3/3]

Chaos::Softs::FVelocityAndPressureField::FVelocityAndPressureField ( )
inline

◆ ~FVelocityAndPressureField()

Chaos::Softs::FVelocityAndPressureField::~FVelocityAndPressureField ( )
inline

Member Function Documentation

◆ Apply() [1/2]

void Chaos::Softs::FVelocityAndPressureField::Apply ( FSolverParticles InParticles,
const FSolverReal  Dt,
const int32  Index 
) const
inline

◆ Apply() [2/2]

void Chaos::Softs::FVelocityAndPressureField::Apply ( FSolverParticlesRange InParticles,
const FSolverReal  Dt 
) const

◆ CalculateForce()

FSolverVec3 Chaos::Softs::FVelocityAndPressureField::CalculateForce ( const TConstArrayView< FSolverVec3 > &  Xs,
const TConstArrayView< FSolverVec3 > &  Vs,
int32  ElementIndex 
) const

◆ GetElements()

TConstArrayView< TVector< int32, 3 > > Chaos::Softs::FVelocityAndPressureField::GetElements ( ) const
inline

◆ GetForces()

TConstArrayView< FSolverVec3 > Chaos::Softs::FVelocityAndPressureField::GetForces ( ) const
inline

◆ GetVelocity()

const FSolverVec3 & Chaos::Softs::FVelocityAndPressureField::GetVelocity ( ) const
inline

◆ IsActive()

bool Chaos::Softs::FVelocityAndPressureField::IsActive ( ) const
inline

◆ IsEnabled()

static bool Chaos::Softs::FVelocityAndPressureField::IsEnabled ( const FCollectionPropertyConstFacade PropertyCollection)
inlinestatic

◆ SetGeometry() [1/3]

void Chaos::Softs::FVelocityAndPressureField::SetGeometry ( const FTriangleMesh TriangleMesh,
const FCollectionPropertyConstFacade PropertyCollection,
const TMap< FString, TConstArrayView< FRealSingle > > &  Weightmaps,
FSolverReal  WorldScale 
)

◆ SetGeometry() [2/3]

void Chaos::Softs::FVelocityAndPressureField::SetGeometry ( const FTriangleMesh TriangleMesh,
const TConstArrayView< FRealSingle > &  DragMultipliers,
const TConstArrayView< FRealSingle > &  LiftMultipliers,
const TConstArrayView< FRealSingle > &  PressureMultipliers = TConstArrayView<FRealSingle>() 
)
inline

◆ SetGeometry() [3/3]

void Chaos::Softs::FVelocityAndPressureField::SetGeometry ( const FTriangleMesh TriangleMesh,
const TConstArrayView< FRealSingle > &  DragMultipliers,
const TConstArrayView< FRealSingle > &  OuterDragMultipliers,
const TConstArrayView< FRealSingle > &  LiftMultipliers,
const TConstArrayView< FRealSingle > &  OuterLiftMultipliers,
const TConstArrayView< FRealSingle > &  PressureMultipliers 
)

◆ SetProperties() [1/2]

void Chaos::Softs::FVelocityAndPressureField::SetProperties ( const FCollectionPropertyConstFacade PropertyCollection,
const TMap< FString, TConstArrayView< FRealSingle > > &  Weightmaps,
FSolverReal  WorldScale,
bool  bEnableAerodynamics 
)

◆ SetProperties() [2/2]

void Chaos::Softs::FVelocityAndPressureField::SetProperties ( const FSolverVec2 Drag,
const FSolverVec2 OuterDrag,
const FSolverVec2 Lift,
const FSolverVec2 OuterLift,
const FSolverReal  FluidDensity,
const FSolverVec2 Pressure = FSolverVec2::ZeroVector,
FSolverReal  WorldScale = 1.f 
)

◆ SetPropertiesAndWind()

void Chaos::Softs::FVelocityAndPressureField::SetPropertiesAndWind ( const FCollectionPropertyConstFacade PropertyCollection,
const TMap< FString, TConstArrayView< FRealSingle > > &  Weightmaps,
FSolverReal  WorldScale,
bool  bEnableAerodynamics,
const FSolverVec3 SolverWind,
const FRotation3 LocalSpaceRotation = FRotation3::Identity,
const FRotation3 ReferenceSpaceRotation = FRotation3::Identity 
)

◆ SetVelocity()

void Chaos::Softs::FVelocityAndPressureField::SetVelocity ( const FSolverVec3 InVelocity)
inline

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [1/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( Drag  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [2/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( FluidDensity  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [3/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( Lift  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [4/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( OuterDrag  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [5/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( OuterLift  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [6/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( Pressure  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [7/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( TurbulenceRatio  ,
float   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [8/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( WindVelocity  ,
FVector3f   
)

◆ UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME() [9/9]

Chaos::Softs::FVelocityAndPressureField::UE_CHAOS_DECLARE_INDEXLESS_PROPERTYCOLLECTION_NAME ( WindVelocitySpace  ,
int32   
)

◆ UpdateForces()

void Chaos::Softs::FVelocityAndPressureField::UpdateForces ( const FSolverParticles InParticles,
const FSolverReal   
)

Member Data Documentation

◆ DefaultDragCoefficient

constexpr FSolverReal Chaos::Softs::FVelocityAndPressureField::DefaultDragCoefficient = (FSolverReal)0.5
staticconstexpr

◆ DefaultFluidDensity

constexpr FSolverReal Chaos::Softs::FVelocityAndPressureField::DefaultFluidDensity = (FSolverReal)1.225
staticconstexpr

◆ DefaultLiftCoefficient

constexpr FSolverReal Chaos::Softs::FVelocityAndPressureField::DefaultLiftCoefficient = (FSolverReal)0.1
staticconstexpr

◆ DefaultTurbulenceRatio

constexpr FSolverReal Chaos::Softs::FVelocityAndPressureField::DefaultTurbulenceRatio = (FSolverReal)1.f
staticconstexpr

◆ DefaultWindVelocitySpace

constexpr EChaosSoftsSimulationSpace Chaos::Softs::FVelocityAndPressureField::DefaultWindVelocitySpace = EChaosSoftsSimulationSpace::WorldSpace
staticconstexpr

◆ MaxCoefficient

constexpr FSolverReal Chaos::Softs::FVelocityAndPressureField::MaxCoefficient = (FSolverReal)10.
staticconstexpr

◆ MinCoefficient

constexpr FSolverReal Chaos::Softs::FVelocityAndPressureField::MinCoefficient = (FSolverReal)0.
staticconstexpr

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