USkinnedMeshComponent::SetSkeletalMesh

Change the SkeletalMesh that is rendered for this Component.

Choose your operating system:

Windows

macOS

Linux

Override Hierarchy

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Classes/Components/SkinnedMeshComponent.h

Include

#include "Components/SkinnedMeshComponent.h"

Source

/Engine/Source/Runtime/Engine/Private/Components/SkinnedMeshComponent.cpp

Syntax

virtual void SetSkeletalMesh
(
    class USkeletalMesh * NewMesh,
    bool bReinitPose
)

Remarks

Change the SkeletalMesh that is rendered for this Component. Will re-initialize the animation tree etc.

Parameters

Parameter

Description

NewMesh

New mesh to set for this component

bReinitPose

Whether we should keep current pose or reinitialize.