Presentation-only montage player over an ActionTimeline. 更多...
#include <MontagePlayer.h>
Public 成员函数 | |
| MontagePlayer (AnimSkeleton &skeleton) | |
| Borrow a skeleton that must outlive this player. | |
| ~MontagePlayer () | |
| Montage player. | |
| MontagePlayer (const MontagePlayer &)=delete | |
| MontagePlayer & | operator= (const MontagePlayer &)=delete |
| Result< void > | prepare (action::ActionTimeline timeline, std::vector< MontageClipAsset > &&clips) |
| Validate and atomically replace the complete montage presentation. | |
| Result< void > | prepare (action::ActionTimeline timeline, IMontageClipProvider &provider) |
| Resolve every distinct section URI and atomically prepare the montage. | |
| Result< void > | reloadClips (IMontageClipProvider &provider) |
| Transactionally reload every referenced clip while preserving playback state. | |
| Result< void > | setSettings (action::ActionMontageSettings settings) |
| Apply validated montage-wide settings without rebuilding clip topology or playback time. | |
| Result< void > | setSectionSplits (std::vector< Duration > splitTimestamps) |
| Atomically replace objective physical-section split timestamps without rebuilding clip topology. | |
| Result< void > | replaceClip (std::string_view uri, std::unique_ptr< AnimClip > clip) |
| Transactionally replace one URI-backed clip and preserve the current cursor and slot weight. | |
| Result< void > | play (action::ActionExecutionId executionId) |
| Bind presentation playback to one authoritative ActionRuntime execution. | |
| Result< void > | rebindExecution (action::ActionExecutionId executionId) |
| Rebind an already playing presentation after its external gameplay authority is recreated. | |
| Result< MontageAdvance > | present (const action::ActionAdvance &advance, SimulationTick tick) |
| Present one ActionRuntime-owned advance without advancing gameplay time locally. | |
| Result< MontageAdvance > | jumpToTime (action::ActionExecutionId executionId, Duration target, SimulationTick tick) |
| Atomically realign presentation and active state blocks to an externally authoritative timestamp. | |
| Result< MontageAdvance > | jumpToSection (action::ActionExecutionId executionId, std::size_t sectionIndex, SimulationTick tick) |
| Jump presentation to the start of one objective physical section. | |
| Result< MontageAdvance > | evaluateSectionProgress (action::ActionExecutionId executionId, std::size_t sectionIndex, double progress, SimulationTick tick) |
| Evaluate a normalized physical-section progress and atomically realign presentation. | |
| Result< std::size_t > | physicalSectionIndex () const |
| Resolve the objective physical section containing the current cursor. | |
| Result< double > | physicalSectionProgress (std::size_t sectionIndex) const |
| Return current normalized progress within an objective physical section. | |
| Result< MontageAdvance > | interrupt (SimulationTick tick) |
| Interrupt playback and emit paired exits for every active state block. | |
| Result< MontageAdvance > | beginBlendOut (Duration duration, SimulationTick tick) |
| Enter continuous blend-out and emit exits for every active state block. | |
| Result< MontageAdvance > | advanceBlendOut (Duration delta, SimulationTick tick) |
| Advance an active blend-out without advancing gameplay or montage time. | |
| void | stop () noexcept |
| Stop playback and reset the derived cursor. | |
| void | setRootMotionReceiver (IMontageRootMotionReceiver &receiver) noexcept |
| Install a borrowed root-motion receiver. | |
| void | clearRootMotionReceiver () noexcept |
| Clear the borrowed root-motion receiver before its owner is destroyed. | |
| void | setRootMotionMask (MontageRootMotionMask mask) noexcept |
| Compatibility setter for axis enable bits. | |
| MontageRootMotionMask | getRootMotionMask () const noexcept |
| Compatibility projection of the active policy lock bits. | |
| Result< void > | setRootMotionPolicy (const RootMotionPolicy &policy) |
| Replace the canonical root-motion policy used by presentation and the owned AnimPlayer. | |
| RootMotionPolicy | getRootMotionPolicy () const noexcept |
| Copy of the active root-motion policy. | |
| Result< void > | setRootMotionCharacterYaw (float yawRadians) |
| Update CharacterFacing yaw without replacing bake/lock/apply-space. | |
| void | setGapPolicy (MontageGapPolicy policy) noexcept |
| Select the explicit pose policy used in gaps between animation sections. | |
| AnimPose & | pose () |
| Borrow the current evaluated pose. | |
| Duration | time () const noexcept |
| Current derived montage presentation time. | |
| bool | isPlaying () const noexcept |
| Whether the prepared montage is actively playing. | |
| bool | isBlendingOut () const noexcept |
| Whether playback is in externally requested blend-out. | |
| bool | isFinished () const noexcept |
| Whether playback completed naturally while retaining its final weighted pose. | |
| double | weight () const noexcept |
| Current continuous montage slot weight. | |
| std::size_t | animationLayer () const noexcept |
| Authored output layer requested by the prepared montage, or zero before preparation. | |
| bool | footIkEnabled () const noexcept |
| Whether the host should run its terrain-specific foot-IK provider after this pose. | |
详细描述
Presentation-only montage player over an ActionTimeline.
ActionRuntime remains the sole gameplay lifecycle authority. This object owns all resolved clips and only keeps a derived presentation cursor. It is owner-thread-only, reads no wall clock, and invokes the optional receiver without holding a lock.
在文件 MontagePlayer.h 第 107 行定义.
构造及析构函数说明
◆ MontagePlayer() [1/2]
|
explicit |
Borrow a skeleton that must outlive this player.
在文件 MontagePlayer.cpp 第 47 行定义.
◆ ~MontagePlayer()
|
default |
Montage player.
◆ MontagePlayer() [2/2]
|
delete |
成员函数说明
◆ advanceBlendOut()
| Result< MontageAdvance > eve::animation::MontagePlayer::advanceBlendOut | ( | Duration | delta, |
| SimulationTick | tick | ||
| ) |
Advance an active blend-out without advancing gameplay or montage time.
在文件 MontagePlayer.cpp 第 593 行定义.
引用了 eve::Applied, eve::animation::MontageAdvance::completed, eve::Conflict, eve::animation::MontageAdvance::current, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, eve::Pending, eve::animation::MontageAdvance::previous, eve::Duration::seconds(), eve::Status::success(), eve::Result< T >::success(), t, tick, eve::Duration::tryAdd(), eve::animation::MontageAdvance::weight , 以及 eve::Duration::zero().
◆ animationLayer()
|
inlinenoexcept |
Authored output layer requested by the prepared montage, or zero before preparation.
在文件 MontagePlayer.h 第 229 行定义.
◆ beginBlendOut()
| Result< MontageAdvance > eve::animation::MontagePlayer::beginBlendOut | ( | Duration | duration, |
| SimulationTick | tick | ||
| ) |
Enter continuous blend-out and emit exits for every active state block.
在文件 MontagePlayer.cpp 第 549 行定义.
引用了 eve::Applied, eve::animation::MontageAdvance::completed, eve::Conflict, eve::animation::MontageAdvance::current, duration, eve::Diagnostic::error(), eve::animation::MontageAdvance::events, eve::Result< T >::failure(), interrupt(), eve::InvalidArgument, eve::NoOp, eve::Pending, eve::animation::MontageAdvance::previous, state, eve::action::StateExit, eve::Status::success(), eve::Result< T >::success(), tick, eve::animation::MontageAdvance::weight , 以及 eve::Duration::zero().
◆ clearRootMotionReceiver()
|
inlinenoexcept |
Clear the borrowed root-motion receiver before its owner is destroyed.
在文件 MontagePlayer.h 第 190 行定义.
◆ evaluateSectionProgress()
| Result< MontageAdvance > eve::animation::MontagePlayer::evaluateSectionProgress | ( | action::ActionExecutionId | executionId, |
| std::size_t | sectionIndex, | ||
| double | progress, | ||
| SimulationTick | tick | ||
| ) |
Evaluate a normalized physical-section progress and atomically realign presentation.
在文件 MontagePlayer.cpp 第 481 行定义.
引用了 eve::Diagnostic::error(), executionId, eve::Result< T >::failure(), eve::Duration::fromNanoseconds(), eve::InvalidArgument, jumpToTime(), range, target , 以及 tick.
◆ footIkEnabled()
|
inlinenoexcept |
Whether the host should run its terrain-specific foot-IK provider after this pose.
在文件 MontagePlayer.h 第 233 行定义.
◆ getRootMotionMask()
|
inlinenoexcept |
Compatibility projection of the active policy lock bits.
在文件 MontagePlayer.h 第 198 行定义.
◆ getRootMotionPolicy()
|
inlinenoexcept |
Copy of the active root-motion policy.
在文件 MontagePlayer.h 第 206 行定义.
◆ interrupt()
| Result< MontageAdvance > eve::animation::MontagePlayer::interrupt | ( | SimulationTick | tick | ) |
Interrupt playback and emit paired exits for every active state block.
在文件 MontagePlayer.cpp 第 518 行定义.
引用了 eve::Applied, eve::animation::MontageAdvance::completed, eve::Conflict, eve::animation::MontageAdvance::current, eve::Diagnostic::error(), eve::animation::MontageAdvance::events, eve::Result< T >::failure(), eve::InvalidArgument, eve::NoOp, eve::animation::MontageAdvance::previous, state, eve::action::StateExit, eve::Status::success(), eve::Result< T >::success(), tick , 以及 eve::animation::MontageAdvance::weight.
被这些函数引用 beginBlendOut().
◆ isBlendingOut()
|
inlinenoexcept |
Whether playback is in externally requested blend-out.
在文件 MontagePlayer.h 第 221 行定义.
◆ isFinished()
|
inlinenoexcept |
Whether playback completed naturally while retaining its final weighted pose.
在文件 MontagePlayer.h 第 223 行定义.
◆ isPlaying()
|
inlinenoexcept |
Whether the prepared montage is actively playing.
在文件 MontagePlayer.h 第 219 行定义.
◆ jumpToSection()
| Result< MontageAdvance > eve::animation::MontagePlayer::jumpToSection | ( | action::ActionExecutionId | executionId, |
| std::size_t | sectionIndex, | ||
| SimulationTick | tick | ||
| ) |
Jump presentation to the start of one objective physical section.
在文件 MontagePlayer.cpp 第 471 行定义.
引用了 eve::Diagnostic::error(), executionId, eve::Result< T >::failure(), eve::InvalidArgument, jumpToTime(), range, tick , 以及 eve::detail::StrongUint64< Tag >::value().
◆ jumpToTime()
| Result< MontageAdvance > eve::animation::MontagePlayer::jumpToTime | ( | action::ActionExecutionId | executionId, |
| Duration | target, | ||
| SimulationTick | tick | ||
| ) |
Atomically realign presentation and active state blocks to an externally authoritative timestamp.
- 备注
- This does not advance ActionRuntime; the caller must align its gameplay authority separately.
在文件 MontagePlayer.cpp 第 433 行定义.
引用了 active, eve::animation::MontageAdvance::activeBlocks, eve::Applied, eve::Conflict, eve::animation::MontageAdvance::current, eve::Diagnostic::error(), eve::animation::MontageAdvance::events, executionId, eve::Result< T >::failure(), eve::Duration::fromNanoseconds(), eve::InvalidArgument, eve::animation::MontageAdvance::previous, eve::animation::MontageAdvance::sectionId, eve::Status::success(), eve::Result< T >::success(), target, tick , 以及 eve::Duration::zero().
被这些函数引用 evaluateSectionProgress() , 以及 jumpToSection().
◆ operator=()
|
delete |
◆ physicalSectionIndex()
| Result< std::size_t > eve::animation::MontagePlayer::physicalSectionIndex | ( | ) | const |
Resolve the objective physical section containing the current cursor.
在文件 MontagePlayer.cpp 第 498 行定义.
引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), found, eve::InvalidArgument , 以及 eve::Result< T >::success().
◆ physicalSectionProgress()
| Result< double > eve::animation::MontagePlayer::physicalSectionProgress | ( | std::size_t | sectionIndex | ) | const |
Return current normalized progress within an objective physical section.
在文件 MontagePlayer.cpp 第 507 行定义.
引用了 eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, eve::Duration::nanoseconds(), range , 以及 eve::Result< T >::success().
◆ play()
| Result< void > eve::animation::MontagePlayer::play | ( | action::ActionExecutionId | executionId | ) |
Bind presentation playback to one authoritative ActionRuntime execution.
在文件 MontagePlayer.cpp 第 209 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), executionId, eve::Result< T >::failure(), eve::InvalidArgument, eve::detail::StrongUint64< Tag >::isZero(), eve::Status::success(), eve::Result< T >::success() , 以及 eve::Duration::zero().
◆ pose()
| AnimPose & eve::animation::MontagePlayer::pose | ( | ) |
Borrow the current evaluated pose.
在文件 MontagePlayer.cpp 第 623 行定义.
◆ prepare() [1/2]
| Result< void > eve::animation::MontagePlayer::prepare | ( | action::ActionTimeline | timeline, |
| IMontageClipProvider & | provider | ||
| ) |
Resolve every distinct section URI and atomically prepare the montage.
- 参数
-
provider Borrowed only for this synchronous call and never retained.
在文件 MontagePlayer.cpp 第 54 行定义.
引用了 eve::action::ActionTimeline::animationSections, eve::Result< T >::failure(), eve::animation::IMontageClipProvider::load(), prepare(), valid , 以及 eve::action::ActionTimeline::validate().
◆ prepare() [2/2]
| Result< void > eve::animation::MontagePlayer::prepare | ( | action::ActionTimeline | timeline, |
| std::vector< MontageClipAsset > && | clips | ||
| ) |
Validate and atomically replace the complete montage presentation.
- 参数
-
timeline Canonical owning timeline copied into the player. clips Clip ownership transferred only on success.
在文件 MontagePlayer.cpp 第 68 行定义.
引用了 eve::action::ActionTimeline::animationSections, eve::Applied, clip, eve::Diagnostic::error(), eve::Result< T >::failure(), index, eve::InvalidArgument, eve::Status::success(), eve::Result< T >::success(), uri, valid, eve::action::ActionTimeline::validate(), eve::detail::StrongUint64< detail::SimulationTickTag >::zero() , 以及 eve::Duration::zero().
被这些函数引用 prepare() , 以及 reloadClips().
◆ present()
| Result< MontageAdvance > eve::animation::MontagePlayer::present | ( | const action::ActionAdvance & | advance, |
| SimulationTick | tick | ||
| ) |
Present one ActionRuntime-owned advance without advancing gameplay time locally.
- 参数
-
advance Owning observation returned by ActionRuntime::advance. tick Strictly increasing simulation tick associated with the observation.
在文件 MontagePlayer.cpp 第 332 行定义.
引用了 eve::action::ActionAdvance::activeBlocks, eve::animation::MontageAdvance::activeBlocks, eve::Applied, eve::animation::IMontageRootMotionReceiver::applyMontageRootMotion(), eve::animation::BindPose, eve::action::Completed, eve::animation::MontageAdvance::completed, eve::Conflict, eve::animation::MontageAdvance::current, cursor, eve::action::ActionAnimationSection::end, eve::Diagnostic::error(), eve::animation::MontageAdvance::events, eve::Result< T >::failure(), eve::Duration::fromNanoseconds(), eve::action::ActionAdvance::id, eve::action::ActionAnimationSection::id, eve::InvalidArgument, eve::Duration::nanoseconds(), eve::Pending, eve::action::ActionAdvance::phase, eve::animation::MontageAdvance::previous, eve::animation::MontageAdvance::rootMotion, eve::Duration::seconds(), eve::animation::MontageAdvance::sectionId, eve::action::ActionAnimationSection::start, start, eve::Status::success(), eve::Result< T >::success(), t, tick, eve::action::ActionAdvance::timelineEvents, eve::action::ActionAdvance::totalElapsed, eve::animation::MontageAdvance::weight , 以及 eve::Duration::zero().
◆ rebindExecution()
| Result< void > eve::animation::MontagePlayer::rebindExecution | ( | action::ActionExecutionId | executionId | ) |
Rebind an already playing presentation after its external gameplay authority is recreated.
在文件 MontagePlayer.cpp 第 228 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), executionId, eve::Result< T >::failure(), eve::InvalidArgument, eve::detail::StrongUint64< Tag >::isZero(), eve::Status::success() , 以及 eve::Result< T >::success().
◆ reloadClips()
| Result< void > eve::animation::MontagePlayer::reloadClips | ( | IMontageClipProvider & | provider | ) |
Transactionally reload every referenced clip while preserving playback state.
- 参数
-
provider Borrowed synchronous provider; no replacement is committed unless all clips validate.
在文件 MontagePlayer.cpp 第 121 行定义.
引用了 eve::Applied, duration, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::Duration::fromNanoseconds(), eve::InvalidArgument, eve::animation::IMontageClipProvider::load(), eve::Duration::nanoseconds(), prepare(), eve::Status::success() , 以及 eve::Result< T >::success().
◆ replaceClip()
| Result< void > eve::animation::MontagePlayer::replaceClip | ( | std::string_view | uri, |
| std::unique_ptr< AnimClip > | clip | ||
| ) |
Transactionally replace one URI-backed clip and preserve the current cursor and slot weight.
在文件 MontagePlayer.cpp 第 174 行定义.
引用了 eve::action::ActionAnimationSection::animationUri, eve::Applied, clip, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::Duration::fromNanoseconds(), index, eve::InvalidArgument, eve::Duration::nanoseconds(), eve::Status::success(), eve::Result< T >::success(), uri , 以及 value.
◆ setGapPolicy()
|
inlinenoexcept |
Select the explicit pose policy used in gaps between animation sections.
在文件 MontagePlayer.h 第 213 行定义.
◆ setRootMotionCharacterYaw()
| Result< void > eve::animation::MontagePlayer::setRootMotionCharacterYaw | ( | float | yawRadians | ) |
Update CharacterFacing yaw without replacing bake/lock/apply-space.
- 返回
- Applied on success; InvalidArgument when yaw is non-finite.
在文件 MontagePlayer.cpp 第 325 行定义.
引用了 eve::Applied, eve::animation::RootMotionPolicy::characterYaw, eve::Status::success() , 以及 eve::Result< T >::success().
◆ setRootMotionMask()
|
noexcept |
Compatibility setter for axis enable bits.
Updates RootMotionPolicy lockAxes / lockRotation and pushes the policy into the owned AnimPlayer. Bake / apply-space / yaw are preserved.
在文件 MontagePlayer.cpp 第 308 行定义.
引用了 mask.
◆ setRootMotionPolicy()
| Result< void > eve::animation::MontagePlayer::setRootMotionPolicy | ( | const RootMotionPolicy & | policy | ) |
Replace the canonical root-motion policy used by presentation and the owned AnimPlayer.
- 返回
- Applied on success; InvalidArgument leaves the previous policy unchanged. @thread Owner thread only; no callbacks or reentrancy.
在文件 MontagePlayer.cpp 第 315 行定义.
引用了 eve::Applied, eve::Status::success(), eve::Result< T >::success() , 以及 eve::animation::validateRootMotionPolicy().
◆ setRootMotionReceiver()
|
inlinenoexcept |
Install a borrowed root-motion receiver.
- 参数
-
receiver Receiver that must outlive this player or be cleared before destruction. @lifetime The player retains a non-owning observer until clearRootMotionReceiver() is called.
在文件 MontagePlayer.h 第 188 行定义.
◆ setSectionSplits()
| Result< void > eve::animation::MontagePlayer::setSectionSplits | ( | std::vector< Duration > | splitTimestamps | ) |
Atomically replace objective physical-section split timestamps without rebuilding clip topology.
- 参数
-
splitTimestamps Strictly ordered boundaries inside the prepared montage duration.
- 返回
- Applied, or a structured validation/state failure with the previous boundaries preserved.
在文件 MontagePlayer.cpp 第 162 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, eve::Status::success(), eve::Result< T >::success() , 以及 valid.
◆ setSettings()
| Result< void > eve::animation::MontagePlayer::setSettings | ( | action::ActionMontageSettings | settings | ) |
Apply validated montage-wide settings without rebuilding clip topology or playback time.
- 参数
-
settings Candidate settings validated against the prepared timeline before publication.
- 返回
- Applied, or a structured validation/state failure with no observable mutation.
在文件 MontagePlayer.cpp 第 149 行定义.
引用了 eve::Applied, eve::Diagnostic::error(), eve::Result< T >::failure(), eve::InvalidArgument, settings, eve::Status::success(), eve::Result< T >::success() , 以及 valid.
◆ stop()
|
noexcept |
Stop playback and reset the derived cursor.
在文件 MontagePlayer.cpp 第 239 行定义.
◆ time()
|
inlinenoexcept |
Current derived montage presentation time.
在文件 MontagePlayer.h 第 217 行定义.
◆ weight()
|
inlinenoexcept |
Current continuous montage slot weight.
在文件 MontagePlayer.h 第 227 行定义.
该类的文档由以下文件生成:
- src/modules/animation/MontagePlayer.h
- src/modules/animation/MontagePlayer.cpp