Loading...
Searching...
No Matches
juce::VBlankAnimatorUpdater Class Reference

Detailed Description

Similar to AnimatorUpdater, but automatically calls update() whenever the screen refreshes.

Inheritance diagram for juce::VBlankAnimatorUpdater:

Public Member Functions

 VBlankAnimatorUpdater (Component *c)
 Constructs a VBlankAnimatorUpdater that is synchronised to the refresh rate of the monitor that the provided Component is being displayed on.
void addAnimator (const Animator &animator)
 Registers an Animator with the updater.
void addAnimator (const Animator &animator, std::function< void()> onComplete)
 Registers an Animator with the updater and specifies a callback to be called upon the completion of the Animator.
void removeAnimator (const Animator &animator)
 Removes an Animator.

Constructors and Destructors

◆ VBlankAnimatorUpdater()

juce::VBlankAnimatorUpdater::VBlankAnimatorUpdater ( Component * c)
explicit

Constructs a VBlankAnimatorUpdater that is synchronised to the refresh rate of the monitor that the provided Component is being displayed on.

References juce::AnimatorUpdater::update().

Member Functions

◆ addAnimator() [1/2]

void juce::AnimatorUpdater::addAnimator ( const Animator & animator)

Registers an Animator with the updater.

◆ addAnimator() [2/2]

void juce::AnimatorUpdater::addAnimator ( const Animator & animator,
std::function< void()> onComplete )

Registers an Animator with the updater and specifies a callback to be called upon the completion of the Animator.

This callback can be used for cleanup purposes e.g.

animatorUpdater.addAnimator (someComponentPtr->getAnimator(),
[&someComponentPtr] { someComponentPtr.reset(); });

◆ removeAnimator()

void juce::AnimatorUpdater::removeAnimator ( const Animator & animator)

Removes an Animator.

linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram