FComponentCacheAdapter

Base adapter type for interfacing with Chaos simulation caches.

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

ChaosCaching

Header

/Engine/Plugins/Experimental/ChaosCaching/Source/ChaosCaching/Public/Chaos/Adapters/CacheAdapter.h

Include

#include "Chaos/Adapters/CacheAdapter.h"

Syntax

class FComponentCacheAdapter : public IModularFeature

Remarks

Base adapter type for interfacing with Chaos simulation caches. Any component wishing to use caches must have a compatible record adapter and a playback adapter to produce and consume cache data.

This base interface should not be used to implement those adapters however but the derived classes FCacheRecordAdapter and FCachePlaybackAdapter (declared below) should instead be used.

Constructors

Name Description

Public function

FComponentCacheAdapter()

Destructors

Name Description

Public function Virtual

~FComponentCacheAdapter()

Functions

Name Description

Public function Const

Chaos::FPhys...

 

GetComponentSolver

(
    UPrimitiveComponent* InCompone...
)

Called to retrieve the solver for a specific component.

Public function Const

UClass *

 

GetDesiredClass()

Query the class that this adapter wants to drive.

Public function Const

FGuid

 

GetGuid()

Gets a unique identifier for the adapter

Public function Const

uint8

 

GetPriority()

Gets the priority for an adapter.

Public function Const

bool

 

InitializeForPlayback

(
    UPrimitiveComponent* InCompone...,
    UChaosCache* InCache
)

Called from the game thread to initialize a component and cache ready to playback a cache

Public function Const

bool

 

InitializeForRecord

(
    UPrimitiveComponent* InCompone...,
    UChaosCache* InCache
)

Called from the game thread to initialize a component and cache ready to record a cache

Public function Const

void

 

Playback_PreSolve

(
    UPrimitiveComponent* InCompone...,
    UChaosCache* InCache,
    Chaos::FReal InTime,
    FPlaybackTickRecord& TickRecord,
    TArray< TPBDRigidParticleHandle< Ch...
)

Called by a cache observer actor when a cache needs to be applied to a component through this adapter.

Public function Const

void

 

Record_PostSolve

(
    UPrimitiveComponent* InComp,
    const FTransform& InRootTransform,
    FPendingFrameWrite& OutFrame,
    Chaos::FReal InTime
)

Called by a cache observer when a component should be recorded to a cache through this adapter.

Public function Const

SupportType

 

SupportsComponentClass

(
    UClass* InComponentClass
)

Query whether InComponentClass can be driven by this adapter.

Public function Const

bool

 

ValidForPlayback

(
    UPrimitiveComponent* InCompone...,
    UChaosCache* InCache
)

Determines whether a cache is able to safely playback on a component.

Enums

Name

Description

Public enum

SupportType

Constants

Name

Description

EngineAdapterPriotityBegin

FeatureName

Registration name for modular features module

UserAdapterPriotityBegin

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss