book_4_sparkGenerated
code_blocksInput

Description

The Morphs property provides access to the morph targets of a skinned model. Morph targets are used to create complex animations by blending different shapes of a model. This property is part of the SkinnedModelRenderer class, which is responsible for rendering skinned models with bones and animations in the world.

Usage

To access the morphs of a skinned model, use the Morphs property of the SkinnedModelRenderer instance. This property returns a MorphAccessor object, which allows you to manipulate the morph targets of the model.

Example

// Assuming 'renderer' is an instance of SkinnedModelRenderer
var morphs = renderer.Morphs;

// Example: Set a specific morph target's weight
morphs.SetWeight("Smile", 0.5f);