Tweeny 4.1.0
A Tweening library for modern C++
Loading...
Searching...
No Matches

◆ seek()

template<typename FirstValueType, typename... RemainingValueTypes>
auto seek ( uint32_t target_frame) -> tween_value_t

Seeks to a specific frame in the animation.

Jumps directly to the target frame, updating the tween's current position and value. Clamped to [first_frame, last_frame]. Triggers event::seek listeners.

Parameters
target_frameAbsolute frame number to seek to
Returns
Interpolated value at the target frame
auto t = tweeny::from(0).to(100).during(100U).build();
t.seek(50U); // Jump to frame 50 (value: 50)
t.seek(0U); // Jump back to start
tweeny_builder< true, FirstValue, RemainingValues... > to(const FirstValue &firstComponent, const RemainingValues &... remainingComponents) &
Adds a target keyframe to the tween.
Definition tweeny.h:109
tweeny_builder & during(FrameCountsType... frame_counts)
Specifies per-component frame durations for the last keyframe segment.
Definition tweeny.h:245
tweeny_builder< false, FirstValue, RemainingValues... > from(FirstValue firstComponent, RemainingValues... remainingComponents)
Creates a new tween builder starting from the specified value(s).
Definition tweeny.h:347