Open 3D Engine Atom Gem API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AZ::Render::SkinnedMeshInstance Class Reference

#include <SkinnedMeshInstance.h>

Inherits AZStd::intrusive_base.

Public Member Functions

 AZ_CLASS_ALLOCATOR (SkinnedMeshInstance, AZ::SystemAllocator)
 
void SuppressSignalOnDeallocate ()
 
void DisableSkinning (uint32_t lodIndex, uint32_t meshIndex)
 Set a flag to skip skinning for a particular mesh.
 
void EnableSkinning (uint32_t lodIndex, uint32_t meshIndex)
 Set a flag to enable skinning for a particular mesh.
 
bool IsSkinningEnabled (uint32_t lodIndex, uint32_t meshIndex) const
 Returns true if skinning should be executed for this mesh.
 

Public Attributes

Data::Instance< RPI::Modelm_model
 The target model, which is used by the MeshFeatureProcessor to render the mesh.
 
AZStd::vector< AZStd::vector< SkinnedMeshOutputVertexOffsets > > m_outputStreamOffsetsInBytes
 Offsets into the skinned vertex data which are used by SkinnedMeshDispatchItem to target the correct location to store the skinning results.
 
AZStd::vector< AZStd::vector< uint32_t > > m_positionHistoryBufferOffsetsInBytes
 Offsets to the start of the position history buffer for each mesh.
 
AZStd::vector< AZStd::vector< AZStd::intrusive_ptr< SkinnedMeshOutputStreamAllocation > > > m_allocations
 
AZStd::vector< AZStd::vector< MorphTargetInstanceMetaData > > m_morphTargetInstanceMetaData
 
AZStd::vector< AZStd::vector< bool > > m_isSkinningEnabled
 Meshes that have no influences or are skinned by another system (cloth) should be skipped.
 

Detailed Description

SkinnedMeshInstance contains the data that is needed to represent the output from skinning a single instance of a skinned mesh. It does not contain the actual skinned vertex data, but rather views into the buffers that do contain the data, which are owned by the SkinnedMeshOutputStreamManager

Member Function Documentation

◆ SuppressSignalOnDeallocate()

void AZ::Render::SkinnedMeshInstance::SuppressSignalOnDeallocate ( )

Typically, when a SkinnedMeshInstance goes out of scope and the memory is freed, the SkinnedMeshOutputStreamManager will signal an event indicating more memory is available If the creation of a SkinnedMeshInstance fails part way through after some memory has already been allocated, calling SupressSignalOnDeallocate before releasing the SkinnedMeshInstance will prevent this event since there is not really any new memory available that wasn't available before

Member Data Documentation

◆ m_allocations

AZStd::vector<AZStd::vector<AZStd::intrusive_ptr<SkinnedMeshOutputStreamAllocation> > > AZ::Render::SkinnedMeshInstance::m_allocations

Virtual addresses that represent the location of the data within the skinned mesh output stream. When they are released, they automatically mark the memory as freed so the SkinnedMeshOutputStreamManager can re-purpose the memory

◆ m_morphTargetInstanceMetaData

AZStd::vector<AZStd::vector<MorphTargetInstanceMetaData> > AZ::Render::SkinnedMeshInstance::m_morphTargetInstanceMetaData

Offsets into the output stream buffer to a location that contains accumulated morph target deltas from the morph pass. One offset per-lod. Set to MorphTargetConstants::s_invalidDeltaOffset if there are no morph targets for the lod


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