The ClipDescriptor configures the placement of each clip to be used in compositing the ComposedClip. More...
#include <foleys_ClipDescriptor.h>
Inheritance diagram for ClipDescriptor:Classes | |
| class | ClipParameterController |
| class | Listener |
| Listener to be notified of changes in this ClipDescriptor, especially the removal of a ProcessorController. More... | |
Public Member Functions | |
| ClipDescriptor (ComposedClip &owner, std::shared_ptr< AVClip > clip, juce::UndoManager *undo) | |
| Create a ClipDescriptor from an AVClip, that will be included in the ComposedClip. | |
| ClipDescriptor (ComposedClip &owner, juce::ValueTree state, juce::UndoManager *undo) | |
| Create a ClipDescriptor from an AVClip, that will be included in the ComposedClip. | |
| ~ClipDescriptor () override | |
| juce::String | getDescription () const |
| Returns a human readable description of this clip. | |
| void | setDescription (const juce::String &name) |
| Set the description of this clip. | |
| double | getStart () const |
| start of the clip in seconds | |
| int64_t | getStartInSamples () const |
| void | setStart (double start) |
| double | getLength () const |
| length of the clip in seconds | |
| int64_t | getLengthInSamples () const |
| void | setLength (double length) |
| double | getOffset () const |
| offset in seconds into the media | |
| int64_t | getOffsetInSamples () const |
| void | setOffset (double offset) |
| void | setVideoVisible (bool shouldBeVisible) |
| switch video invisible | |
| bool | getVideoVisible () const |
| void | setAudioPlaying (bool shouldPlay) |
| switch audio muted | |
| bool | getAudioPlaying () const |
| double | getClipTimeInDescriptorTime (double time) const |
| Transforms a time relative to the containing clip into a local time in ClipDescriptor. | |
| void | readPluginStatesIntoValueTree () |
| Read all plugins getStateInformation() and save it into the statusTree as BLOB. | |
| juce::ValueTree & | getStatusTree () |
| Grants access to the underlying state. | |
| void | updateSampleCounts () |
| ClipParameterController & | getAudioParameterController () |
| ClipParameterController & | getVideoParameterController () |
| void | addProcessor (juce::ValueTree tree, int index=-1) |
| void | addAudioProcessor (std::unique_ptr< ProcessorController > controller, int index=-1) |
| void | addAudioProcessor (std::unique_ptr< juce::AudioProcessor > processor, int index=-1) |
| void | removeAudioProcessor (int index) |
| const std::vector< std::unique_ptr< ProcessorController > > & | getAudioProcessors () const |
| void | addVideoProcessor (std::unique_ptr< ProcessorController > controller, int index=-1) |
| void | addVideoProcessor (std::unique_ptr< VideoProcessor > processor, int index=-1) |
| void | removeVideoProcessor (int index) |
| void | removeProcessor (ProcessorController *controller) |
| const std::vector< std::unique_ptr< ProcessorController > > & | getVideoProcessors () const |
| ComposedClip & | getOwningClip () |
| const ComposedClip & | getOwningClip () const |
| void | addListener (Listener *listener) |
| Add a listener to the ClipDescriptor. | |
| void | removeListener (Listener *listener) |
| Add a listener from the ClipDescriptor. | |
| double | getCurrentTimeInSeconds () const override |
| Since the automation values are time dependent, every instance, that inherits ControllableBase needs a way to tell the local time (presentation time stamp). | |
| void | triggerTimecodeUpdate (juce::NotificationType type) |
| Sends the current local timecode to it's timecodeListeners. | |
| void | updateAudioAutomations (double pts) |
| void | updateVideoAutomations (double pts) |
Public Member Functions inherited from TimeCodeAware | |
| TimeCodeAware ()=default | |
| virtual | ~TimeCodeAware ()=default |
| void | addTimecodeListener (Listener *listener) |
| Register a TimecodeListener to be notified, when the visual frame changes. | |
| void | removeTimecodeListener (Listener *listener) |
| Unregister a TimecodeListener. | |
Public Attributes | |
| std::shared_ptr< AVClip > | clip |
Additional Inherited Members | |
Protected Member Functions inherited from TimeCodeAware | |
| void | sendTimecode (int64_t count, double seconds, juce::NotificationType nt) |
| Subclasses can call this to notify displays, that the time code has changed, e.g. | |
The ClipDescriptor configures the placement of each clip to be used in compositing the ComposedClip.
It also holds a list of VideoProcessors and AudioProcessors including their automation data relative to the clip.
| ClipDescriptor | ( | ComposedClip & | owner, |
| std::shared_ptr< AVClip > | clip, | ||
| juce::UndoManager * | undo | ||
| ) |
Create a ClipDescriptor from an AVClip, that will be included in the ComposedClip.
Every ClipDescriptor can only live in one ComposedClip.
| owner | is the ComposedClip, where the Clipdescriptor will live in. |
| clip | the AVClip, that will be wrapped and described by this ClipDescriptor. |
References ClipDescriptor::clip, and ClipDescriptor::ClipParameterController::setClip().
| ClipDescriptor | ( | ComposedClip & | owner, |
| juce::ValueTree | state, | ||
| juce::UndoManager * | undo | ||
| ) |
Create a ClipDescriptor from an AVClip, that will be included in the ComposedClip.
This will use the owners VideoEngine to resolve and load the clip and all processors. Every ClipDescriptor can only live in one ComposedClip.
| owner | is the ComposedClip, where the Clipdescriptor will live in. |
| state | is the ValueTree coded state to describe this ClipDescriptor. |
References ClipDescriptor::addAudioProcessor(), ClipDescriptor::addVideoProcessor(), ClipDescriptor::clip, AVClip::getVideoEngine(), and ClipDescriptor::ClipParameterController::setClip().
|
override |
| juce::String getDescription | ( | ) | const |
Returns a human readable description of this clip.
This is initially set to the file name of wrapped clip.
| void setDescription | ( | const juce::String & | name | ) |
Set the description of this clip.
| double getStart | ( | ) | const |
start of the clip in seconds
Referenced by ClipDescriptor::getClipTimeInDescriptorTime().
| int64_t getStartInSamples | ( | ) | const |
| void setStart | ( | double | start | ) |
| double getLength | ( | ) | const |
length of the clip in seconds
| int64_t getLengthInSamples | ( | ) | const |
| void setLength | ( | double | length | ) |
| double getOffset | ( | ) | const |
offset in seconds into the media
Referenced by ClipDescriptor::getClipTimeInDescriptorTime().
| int64_t getOffsetInSamples | ( | ) | const |
| void setOffset | ( | double | offset | ) |
| void setVideoVisible | ( | bool | shouldBeVisible | ) |
switch video invisible
| bool getVideoVisible | ( | ) | const |
| void setAudioPlaying | ( | bool | shouldPlay | ) |
switch audio muted
| bool getAudioPlaying | ( | ) | const |
| double getClipTimeInDescriptorTime | ( | double | time | ) | const |
Transforms a time relative to the containing clip into a local time in ClipDescriptor.
References ClipDescriptor::getOffset(), and ClipDescriptor::getStart().
Referenced by ClipDescriptor::getCurrentTimeInSeconds().
| void readPluginStatesIntoValueTree | ( | ) |
Read all plugins getStateInformation() and save it into the statusTree as BLOB.
| juce::ValueTree & getStatusTree | ( | ) |
Grants access to the underlying state.
Your GUI may use this to add private data. It is your responsibility to avoid property or child collissions.
| void updateSampleCounts | ( | ) |
References ClipDescriptor::clip.
| ClipDescriptor::ClipParameterController & getAudioParameterController | ( | ) |
| ClipDescriptor::ClipParameterController & getVideoParameterController | ( | ) |
| void addProcessor | ( | juce::ValueTree | tree, |
| int | index = -1 |
||
| ) |
| void addAudioProcessor | ( | std::unique_ptr< ProcessorController > | controller, |
| int | index = -1 |
||
| ) |
| void addAudioProcessor | ( | std::unique_ptr< juce::AudioProcessor > | processor, |
| int | index = -1 |
||
| ) |
References ClipDescriptor::addAudioProcessor().
| void removeAudioProcessor | ( | int | index | ) |
| const std::vector< std::unique_ptr< ProcessorController > > & getAudioProcessors | ( | ) | const |
| void addVideoProcessor | ( | std::unique_ptr< ProcessorController > | controller, |
| int | index = -1 |
||
| ) |
References ComposedClip::getCallbackLock(), and ClipDescriptor::Listener::processorControllerAdded().
Referenced by ClipDescriptor::addVideoProcessor(), and ClipDescriptor::ClipDescriptor().
| void addVideoProcessor | ( | std::unique_ptr< VideoProcessor > | processor, |
| int | index = -1 |
||
| ) |
References ClipDescriptor::addVideoProcessor().
| void removeVideoProcessor | ( | int | index | ) |
| void removeProcessor | ( | ProcessorController * | controller | ) |
| const std::vector< std::unique_ptr< ProcessorController > > & getVideoProcessors | ( | ) | const |
| ComposedClip & getOwningClip | ( | ) |
| const ComposedClip & getOwningClip | ( | ) | const |
| void addListener | ( | Listener * | listener | ) |
Add a listener to the ClipDescriptor.
| void removeListener | ( | Listener * | listener | ) |
Add a listener from the ClipDescriptor.
|
overridevirtual |
Since the automation values are time dependent, every instance, that inherits ControllableBase needs a way to tell the local time (presentation time stamp).
Implements TimeCodeAware.
References ClipDescriptor::getClipTimeInDescriptorTime(), ClipDescriptor::getCurrentTimeInSeconds(), and ClipDescriptor::getOwningClip().
Referenced by ProcessorController::getCurrentPTS(), ClipDescriptor::getCurrentTimeInSeconds(), and ClipDescriptor::triggerTimecodeUpdate().
| void triggerTimecodeUpdate | ( | juce::NotificationType | type | ) |
Sends the current local timecode to it's timecodeListeners.
References ClipDescriptor::getCurrentTimeInSeconds(), and TimeCodeAware::sendTimecode().
| void updateAudioAutomations | ( | double | pts | ) |
| void updateVideoAutomations | ( | double | pts | ) |
| std::shared_ptr<AVClip> clip |