File include/brisk/gui/internal/Animation.hpp
¶
Transition2
class (Internal::Transition2
)¶
template <typename T> Transition2
Animated
class¶
template <typename ValueType,
typename AnimatedType = ValueType>
Animated
AnimatedRepresents a value that can be animated over time.
This structure holds both the target value and the current animated value, allowing smooth transitions or animations between values.
value
variable (Animated::value
)¶
ValueType value
The target value to which the animation is progressing.
current
variable (Animated::current
)¶
AnimatedType current
The current value in the animation sequence.
TransitionParams
class¶
TransitionParams
animationSpeed
variable¶
extern double animationSpeed
Global variable controlling the speed of animations. Default is 1.0.
PropertyAnimations
class¶
PropertyAnimations
PropertyAnimationsManages property animations and transitions for GUI widgets.
The PropertyAnimations class provides an interface for animating properties over time using customizable transition parameters and easing functions.
Thread Safety: - This class is not thread-safe. All methods should be called from the UI thread.
startTransition
function (PropertyAnimations::startTransition
)¶
template <typename ValueType>
bool startTransition(
ValueType &value, ValueType targetValue,
PropertyId propertyId,
std::function<void()> changed = nullptr)
Returns true if the property is animated, false otherwise.
isActive
function (PropertyAnimations::isActive
)¶
bool isActive() const noexcept
Checks if there are any active animations.
This method returns true if there are animations currently active.
It must be called before calling tick during frame processing.
Returns true if there are active animations, false otherwise.
tick
function (PropertyAnimations::tick
)¶
void tick()
Advances all active animations and removes completed animations.
Param frameTime
The current time in seconds, used to calculate the elapsed time for each animation.
getTransitionParams
function (PropertyAnimations::getTransitionParams
)¶
TransitionParams getTransitionParams(PropertyId id) const
Retrieves the transition parameters associated with a given property ID.
Param id
The identifier of the property for which to retrieve transition parameters.
Returns TransitionParams The transition parameters if the given property has transition,
default-initialized TransitionParams otherwise.
setTransitionParams
function (PropertyAnimations::setTransitionParams
)¶
void setTransitionParams(PropertyId id,
const TransitionParams ¶ms)
Sets the transition parameters for a specific property.
Param id
The identifier of the property for which to set the transition parameters.
Param params
The transition parameters to apply to the property.
Entry
class (PropertyAnimations::Entry
)¶
Entry
Auto-generated from sources, Revision , https://github.com/brisklib/brisk/blob//include/brisk/