Video display and composing engine for JUCE
Loading...
Searching...
No Matches
VideoParameterAutomation Class Reference

Controls the ProcessorParameters of a VideoProcessor. More...

#include <foleys_ParameterAutomation.h>

+ Inheritance diagram for VideoParameterAutomation:

Public Member Functions

 VideoParameterAutomation (ControllableBase &controller, ProcessorParameter &parameter, const juce::ValueTree &state, juce::UndoManager *)
 
 ~VideoParameterAutomation () override
 
juce::String getName () const override
 
int getParameterIndex () const override
 
juce::NamedValueSet & getParameterProperties () override
 
int getNumSteps () const override
 
juce::StringArray getAllValueStrings () const override
 
void updateProcessor (double pts) override
 This updates the parameter to match the state at a certain timepoint.
 
double getRealValueForTime (double pts) const override
 Returns the unnormalised value at a certain time.
 
void setRealValue (double value) override
 Set the value from an unnormalised value.
 
void setRealValue (double pts, double value) override
 Set the value from an unnormalised value at a certain timepoint.
 
void addRealKeyframe (double pts, double value) override
 This will add a keyframe with an unnormalised value at the given position.
 
void setKeyframesWithRealValues (std::map< double, double > keys) override
 Replace all keyframes specifying the value in unnormalised values.
 
void valueChanged (ProcessorParameter &parameter, double newValue) override
 
void gestureStarted (ProcessorParameter &parameter) override
 
void gestureFinished (ProcessorParameter &parameter) override
 
juce::String getText (float normalisedValue, int numDigits=0) const override
 
double getValueForText (const juce::String &text) const override
 
bool isVideoParameter () override
 
- Public Member Functions inherited from ParameterAutomation
 ParameterAutomation (ControllableBase &, double defaultValue, const juce::ValueTree &state, juce::UndoManager *)
 The ParameterAutomation holds the information about keyframes / automation points and takes care of updating the processor values.
 
void setValue (double value)
 This sets the value of the parameter.
 
void setValue (double pts, double value)
 Set the value at a certain timepoint.
 
void addKeyframe (double pts, double value)
 This will add a keyframe at the given position.
 
void setKeyframe (int index, double pts, double value)
 
void deleteKeyframe (int index)
 
double getValueForTime (double pts) const
 Returns the normalised value at a certain time.
 
double getValue () const
 
double getPreviousKeyframeTime (double time) const
 
double getNextKeyframeTime (double time) const
 
void startAutomationGesture ()
 Call this before calling setValue commands (e.g.
 
void finishAutomationGesture ()
 Call this to finish user interaction to give back controll to the playing automation.
 
const std::map< double, double > & getKeyframes () const
 Give reading access to the keyframes.
 
void setKeyframes (std::map< double, double > keys)
 Replace all keyframes.
 
virtual bool isAudioParameter ()
 
ControllableBasegetControllable ()
 

Additional Inherited Members

- Protected Attributes inherited from ParameterAutomation
ControllableBasecontrollable
 
bool gestureInProgress = false
 

Detailed Description

Controls the ProcessorParameters of a VideoProcessor.

Constructor & Destructor Documentation

◆ VideoParameterAutomation()

VideoParameterAutomation ( ControllableBase controller,
ProcessorParameter parameter,
const juce::ValueTree &  state,
juce::UndoManager *  undo 
)

◆ ~VideoParameterAutomation()

Member Function Documentation

◆ getName()

juce::String getName ( ) const
overridevirtual

◆ getParameterIndex()

int getParameterIndex ( ) const
overridevirtual

◆ getParameterProperties()

juce::NamedValueSet & getParameterProperties ( )
overridevirtual

◆ getNumSteps()

int getNumSteps ( ) const
overridevirtual

◆ getAllValueStrings()

juce::StringArray getAllValueStrings ( ) const
overridevirtual

Implements ParameterAutomation.

◆ updateProcessor()

void updateProcessor ( double  pts)
overridevirtual

This updates the parameter to match the state at a certain timepoint.

Call this before you process a block.

Implements ParameterAutomation.

References ParameterAutomation::gestureInProgress, ParameterAutomation::getValueForTime(), and ProcessorParameter::setNormalisedValue().

◆ getRealValueForTime()

double getRealValueForTime ( double  pts) const
overridevirtual

Returns the unnormalised value at a certain time.

Implements ParameterAutomation.

References ParameterAutomation::getValueForTime(), and ProcessorParameter::unNormaliseValue().

◆ setRealValue() [1/2]

void setRealValue ( double  value)
overridevirtual

Set the value from an unnormalised value.

Implements ParameterAutomation.

References ProcessorParameter::normaliseValue(), and ParameterAutomation::setValue().

◆ setRealValue() [2/2]

void setRealValue ( double  pts,
double  value 
)
overridevirtual

Set the value from an unnormalised value at a certain timepoint.

If there was no keyframe recorded yet, this will just call setValue. If there was a keyframe anywhere on the automation, this will add a keyframe at this position.

Implements ParameterAutomation.

References ProcessorParameter::normaliseValue(), and ParameterAutomation::setValue().

◆ addRealKeyframe()

void addRealKeyframe ( double  pts,
double  value 
)
overridevirtual

This will add a keyframe with an unnormalised value at the given position.

Implements ParameterAutomation.

References ParameterAutomation::addKeyframe(), and ProcessorParameter::normaliseValue().

◆ setKeyframesWithRealValues()

void setKeyframesWithRealValues ( std::map< double, double >  keys)
overridevirtual

Replace all keyframes specifying the value in unnormalised values.

Implements ParameterAutomation.

References ProcessorParameter::normaliseValue(), and ParameterAutomation::setKeyframes().

◆ valueChanged()

void valueChanged ( ProcessorParameter parameter,
double  newValue 
)
overridevirtual

◆ gestureStarted()

void gestureStarted ( ProcessorParameter parameter)
overridevirtual

◆ gestureFinished()

void gestureFinished ( ProcessorParameter parameter)
overridevirtual

◆ getText()

juce::String getText ( float  normalisedValue,
int  numDigits = 0 
) const
overridevirtual

◆ getValueForText()

double getValueForText ( const juce::String &  text) const
overridevirtual

◆ isVideoParameter()

bool isVideoParameter ( )
overridevirtual

Reimplemented from ParameterAutomation.


The documentation for this class was generated from the following files: