Responsible for animations saved in the workspace and ensuring that there always is at least one main Animation.
More...
#include <workspaceanimations.h>
|
|
| WorkspaceAnimations (InviwoApplication *app, AnimationManager &manager, AnimationModule &module) |
|
| WorkspaceAnimations (const WorkspaceAnimations &)=delete |
|
| WorkspaceAnimations (WorkspaceAnimations &&)=delete |
|
WorkspaceAnimations & | operator= (const WorkspaceAnimations &)=delete |
|
WorkspaceAnimations & | operator= (WorkspaceAnimations &&)=delete |
|
Animation & | get (size_t index) |
| std::vector< Animation * > | get (std::string_view name) |
|
Animation & | operator[] (size_t i) |
|
const Animation & | operator[] (size_t i) const |
|
const_iterator | begin () const |
|
const_iterator | end () const |
|
iterator | begin () |
|
iterator | end () |
| Animation & | add (std::string_view name) |
|
Animation & | add (Animation anim) |
|
Animation & | insert (size_t index, std::string_view name) |
|
Animation & | insert (const_iterator position, std::string_view name) |
| void | erase (size_t index) |
|
void | erase (const_iterator position) |
| void | clear () |
|
size_t | size () const |
|
void | setMainAnimation (Animation &anim) |
| | Set specified Animation to be the MainAnimation. A copy of the Animation will be added in case the it has not been added before. The AnimationController in MainAnimation will notify its observers of the animation change.
|
|
MainAnimation & | getMainAnimation () |
|
const MainAnimation & | getMainAnimation () const |
|
const_iterator | find (const Animation *anim) const |
|
iterator | find (const Animation *anim) |
|
virtual void | onStateChanged (AnimationController *, AnimationState, AnimationState) |
|
virtual void | onTimeChanged (AnimationController *, Seconds, Seconds) |
|
| Observer (const Observer &other) |
|
| Observer (Observer &&other) |
|
Observer & | operator= (Observer &&other) |
|
Observer & | operator= (const Observer &other) |
| virtual | ~Observer () |
| void | removeObservation (ObservableInterface *observable) |
|
void | removeObservations () |
|
virtual void | onFirstMoved () |
|
virtual void | onLastMoved () |
|
virtual void | onFirstMoved (Track *) |
|
virtual void | onLastMoved (Track *) |
|
| void | addObservation (ObservableInterface *observable) |
|
std::unordered_set< ObservableInterface * > | observables_ |
Responsible for animations saved in the workspace and ensuring that there always is at least one main Animation.
One of its animations is set to be the MainAnimation. The Animation used by MainAnimation must be set through WorkspaceAnimations.
WorkspaceAnimations is responsible for clearing, saving, and loading animations when the workspace is cleared, saved, or loaded. It will also call notifyObserversProcessorNetworkChanged whenever its animations change to enable undo/redo.
◆ const_iterator
| using inviwo::animation::WorkspaceAnimations::const_iterator |
◆ iterator
| using inviwo::animation::WorkspaceAnimations::iterator |
◆ OnChangedDispatcher
Called when an Animation is added or removed. In case of removal: The supplied Animation will be removed from WorkspaceAnimation before this function is called, but it will not be deleted until after this call.
- Parameters
-
| Index | of changed Animation (as it was before removal) |
| Reference | to the added/removed Animation. |
◆ add()
| Animation & inviwo::animation::WorkspaceAnimations::add |
( |
std::string_view | name | ) |
|
◆ clear()
| void inviwo::animation::WorkspaceAnimations::clear |
( |
| ) |
|
Removes all animations leaving an empty Animation, which is set to be the MainAnimation. The size() will be 1 after clearing.
◆ erase()
| void inviwo::animation::WorkspaceAnimations::erase |
( |
size_t | index | ) |
|
Removes the animation and adjusts the main animation to the next available index if needed. An empty animation will be added if all animations are erased.
◆ get()
| std::vector< Animation * > inviwo::animation::WorkspaceAnimations::get |
( |
std::string_view | name | ) |
|
- Returns
- all animations matching name
The documentation for this class was generated from the following file: