UAnimInstance::SnapshotPose
#include "Animation/AnimInstance.h"
Access: public
Specifiers: virtualENGINE_API
Description
Captures the current evaluated pose into an FPoseSnapshot struct for external use. Unlike SavePoseSnapshot, the result is returned to the caller rather than stored internally by name, giving full control over the snapshot's lifetime.
Caveats & Gotchas
- • The snapshot is taken at the resolution of the current LOD. Bones absent from the active LOD will not be included, so snapshots captured at a low LOD may have incomplete bone data if later applied to a higher LOD mesh.
- • FPoseSnapshot stores bone transforms in component space relative to the mesh's reference skeleton. If the skeleton changes (e.g. retargeting), stored snapshots become invalid.
Signature
ENGINE_API virtual void SnapshotPose(FPoseSnapshot& Snapshot); Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| Snapshot | FPoseSnapshot& | Output struct that receives the current bone transforms and curve data. | — |
Return Type
void Example
Capture pose before disabling animation for a physics simulation C++
FPoseSnapshot PreSimSnapshot;
MyAnimInstance->SnapshotPose(PreSimSnapshot);
// Now enable full ragdoll; use PreSimSnapshot later to blend back to animation Tags
Version History
Introduced in: 4.16
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?