Diligent Engine
Loading...
Searching...
No Matches
Diligent::IRadientAnimationRegistry Struct Referenceabstract

#include <RadientAnimation.h>

Inheritance diagram for Diligent::IRadientAnimationRegistry:
Diligent.IObject

Public Member Functions

virtual IRadientScene *DILIGENT_CALL_TYPE GetScene () const =0
virtual RADIENT_STATUS DILIGENT_CALL_TYPE AddAnimationBinding (IRadientAnimationBinding *pBinding, const RadientEntityID *pEntities, Uint32 EntityCount)=0
virtual RADIENT_STATUS DILIGENT_CALL_TYPE RemoveAnimationBinding (IRadientAnimationBinding *pBinding, const RadientEntityID *pEntities, Uint32 EntityCount)=0
virtual RADIENT_STATUS DILIGENT_CALL_TYPE RemoveEntity (RadientEntityID Entity)=0
virtual RADIENT_STATUS DILIGENT_CALL_TYPE RemoveAnimationClip (IRadientAnimationClipAsset *pClip)=0
virtual const RadientAnimationRegistryState &DILIGENT_CALL_TYPE GetState () const =0
Public Member Functions inherited from Diligent.IObject
virtual void DILIGENT_CALL_TYPE QueryInterface (const INTERFACE_ID &IID, IObject **ppInterface)=0
 Queries the specific interface.
template<typename DerivedType, typename = typename std::enable_if<std::is_base_of<IObject, DerivedType>::value>::type>
void QueryInterface (const INTERFACE_ID &IID, DerivedType **ppInterface)
virtual ReferenceCounterValueType DILIGENT_CALL_TYPE AddRef ()=0
 Increments the number of strong references by 1.
virtual ReferenceCounterValueType DILIGENT_CALL_TYPE Release ()=0
virtual IReferenceCounters *DILIGENT_CALL_TYPE GetReferenceCounters () const =0

Detailed Description

Externally owned mapping from animation clips to compiled bindings.

A registry is associated with one scene and retains that scene. It does not modify the scene or automatically observe entity destruction. The code that adds or removes scene content is responsible for updating the registry's private entity associations.

Entity associations are lifetime tags, not animation destinations. The registry never inspects a binding's compiled destinations or assumes that an entity owns them. For example, one skeleton-pose binding may be associated with every mesh entity that shares the pose. The binding remains registered until its last entity association is removed. Public state is intentionally a bulk-playback view: it enumerates every instantiated binding for a clip but does not expose the private lifetime associations or identify a particular scene instance.

The interface is externally synchronized. Applications must not call its methods concurrently without their own synchronization.

Member Function Documentation

◆ AddAnimationBinding()

virtual RADIENT_STATUS DILIGENT_CALL_TYPE Diligent::IRadientAnimationRegistry::AddAnimationBinding ( IRadientAnimationBinding * pBinding,
const RadientEntityID * pEntities,
Uint32 EntityCount )
pure virtual

Adds unique binding-to-entity associations.

pBinding must be non-null and return a non-null clip. Every entity must belong to the registry's scene. The operation is atomic with respect to argument validation: no association is added if any new entity does not exist. Repeated entities and existing associations are ignored. The registry retains pBinding and the clip returned by pBinding->GetClip(). Returns RADIENT_STATUS_NO_CHANGE when EntityCount is zero or every association already exists.

◆ GetScene()

virtual IRadientScene *DILIGENT_CALL_TYPE Diligent::IRadientAnimationRegistry::GetScene ( ) const
pure virtual

Returns the scene associated with this registry. The returned pointer is borrowed and remains valid for the registry lifetime.

◆ GetState()

virtual const RadientAnimationRegistryState &DILIGENT_CALL_TYPE Diligent::IRadientAnimationRegistry::GetState ( ) const
pure virtual

Returns the current registry contents. The returned reference remains valid for the registry lifetime. Its arrays are invalidated by the next successful registry mutation.

◆ RemoveAnimationBinding()

virtual RADIENT_STATUS DILIGENT_CALL_TYPE Diligent::IRadientAnimationRegistry::RemoveAnimationBinding ( IRadientAnimationBinding * pBinding,
const RadientEntityID * pEntities,
Uint32 EntityCount )
pure virtual

Removes the specified binding-to-entity associations. Missing associations are ignored. Returns RADIENT_STATUS_NO_CHANGE when the registry is not modified. A binding is removed when its last entity association is removed; a clip entry is removed when its last binding is removed.

◆ RemoveAnimationClip()

virtual RADIENT_STATUS DILIGENT_CALL_TYPE Diligent::IRadientAnimationRegistry::RemoveAnimationClip ( IRadientAnimationClipAsset * pClip)
pure virtual

Removes a clip and all binding-to-entity associations grouped under it. Returns RADIENT_STATUS_NO_CHANGE when the clip is not registered.

◆ RemoveEntity()

virtual RADIENT_STATUS DILIGENT_CALL_TYPE Diligent::IRadientAnimationRegistry::RemoveEntity ( RadientEntityID Entity)
pure virtual

Removes an entity from every animation entry. This method only updates the registry and never destroys or otherwise modifies the scene entity. Returns RADIENT_STATUS_NO_CHANGE when the entity is not registered.