Files
UnrealEngineUWP/Engine/Source/Runtime/AnimGraphRuntime/Public/AnimSequencerInstance.h
mike zyracki 9833a94abd Sequencer: Need to make sure we re-Construct the Animation Sequence Nodes when entering a section since it may have been changed to a pose snapshot node. Also made sure ConstructNodes really just sets them up lightly since it's used by both SequencerInst/ControlRigInst.
#jira UE-87806
#rb max.chen

#ROBOMERGE-SOURCE: CL 11446379 in //UE4/Release-4.25/...
#ROBOMERGE-BOT: RELEASE (Release-4.25 -> Release-4.25Plus) (v654-11333218)

[CL 11446390 by mike zyracki in 4.25-Plus branch]
2020-02-14 13:57:22 -05:00

51 lines
1.6 KiB
C++

// Copyright Epic Games, Inc. All Rights Reserved.
/**
*
* This Instance only contains one AnimationAsset, and produce poses
* Used by Preview in AnimGraph, Playing single animation in Kismet2 and etc
*/
#pragma once
#include "Animation/AnimInstance.h"
#include "SequencerAnimationSupport.h"
#include "AnimSequencerInstance.generated.h"
UCLASS(transient, NotBlueprintable)
class ANIMGRAPHRUNTIME_API UAnimSequencerInstance : public UAnimInstance, public ISequencerAnimationSupport
{
GENERATED_UCLASS_BODY()
public:
/** Update an animation sequence player in this instance */
virtual void UpdateAnimTrack(UAnimSequenceBase* InAnimSequence, int32 SequenceId, float InPosition, float Weight, bool bFireNotifies);
virtual void UpdateAnimTrack(UAnimSequenceBase* InAnimSequence, int32 SequenceId, float InFromPosition, float InToPosition, float Weight, bool bFireNotifies);
/** Construct all nodes in this instance */
virtual void ConstructNodes() override;
/** Reset all nodes in this instance */
virtual void ResetNodes() override;
/** Reset the pose for this instance*/
virtual void ResetPose() override;
/** Saved the named pose to restore after */
virtual void SavePose() override;
virtual UAnimInstance* GetSourceAnimInstance() override { return this; }
virtual void SetSourceAnimInstance(UAnimInstance* SourceAnimInstance) { /* nothing to do */ ensure(false); }
virtual bool DoesSupportDifferentSourceAnimInstance() const override { return false; }
protected:
// UAnimInstance interface
virtual FAnimInstanceProxy* CreateAnimInstanceProxy() override;
public:
static const FName SequencerPoseName;
};