Gin
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Knob Class Reference

Slider + editable text for showing a param. More...

Inheritance diagram for Knob:

Public Member Functions

 Knob (Parameter *parameter, bool fromCentre=false)
 
 ~Knob () override
 
void setDisplayName (const juce::String &)
 
void setLiveValuesCallback (std::function< juce::Array< float >()> cb)
 
PluginSlidergetSlider ()
 
ReadoutgetReadout ()
 
void paint (juce::Graphics &g) override
 
void resized () override
 
void parentHierarchyChanged () override
 
void mouseEnter (const juce::MouseEvent &e) override
 
void mouseDown (const juce::MouseEvent &e) override
 
void mouseDrag (const juce::MouseEvent &e) override
 
bool isInterestedInDragSource (const SourceDetails &dragSourceDetails) override
 
void itemDragEnter (const SourceDetails &dragSourceDetails) override
 
void itemDragExit (const SourceDetails &dragSourceDetails) override
 
void itemDropped (const SourceDetails &dragSourceDetails) override
 
- Public Member Functions inherited from ParamComponent
 ParamComponent (Parameter *parameter)
 
juce::String getUid ()
 
void setTooltip (const juce::String &newTooltip) override
 

Protected Member Functions

void timerCallback () override
 
void learnSourceChanged (ModSrcId) override
 
void modMatrixChanged () override
 
void showModMenu ()
 

Protected Attributes

juce::Label name
 
Readout value
 
PluginSlider knob
 
bool learning = false
 
float modDepth = 0.0f
 
bool dragOver = false
 
gin::CoalescedTimer modTimer
 
gin::CoalescedTimer shiftTimer
 
juce::Array< float > modValues
 
std::function< juce::Array< float >)> liveValuesCallback
 
gin::ModulationDepthSlider modDepthSlider
 
- Protected Attributes inherited from ParamComponent
Parameterparameter = nullptr
 

Additional Inherited Members

- Public Types inherited from ParamComponent
using Ptr = ParamComponent *
 

Detailed Description

Slider + editable text for showing a param.

Constructor & Destructor Documentation

◆ Knob()

Knob::Knob ( Parameter parameter,
bool  fromCentre = false 
)

◆ ~Knob()

Knob::~Knob ( )
override

Member Function Documentation

◆ setDisplayName()

void Knob::setDisplayName ( const juce::String &  )

◆ setLiveValuesCallback()

void Knob::setLiveValuesCallback ( std::function< juce::Array< float >()>  cb)

◆ getSlider()

PluginSlider& Knob::getSlider ( )

References knob.

◆ getReadout()

Readout& Knob::getReadout ( )

References value.

◆ paint()

void Knob::paint ( juce::Graphics &  g)
override

◆ resized()

void Knob::resized ( )
override

◆ parentHierarchyChanged()

void Knob::parentHierarchyChanged ( )
override

◆ mouseEnter()

void Knob::mouseEnter ( const juce::MouseEvent &  e)
override

◆ mouseDown()

void Knob::mouseDown ( const juce::MouseEvent &  e)
override

◆ mouseDrag()

void Knob::mouseDrag ( const juce::MouseEvent &  e)
override

◆ isInterestedInDragSource()

bool Knob::isInterestedInDragSource ( const SourceDetails &  dragSourceDetails)
override

◆ itemDragEnter()

void Knob::itemDragEnter ( const SourceDetails &  dragSourceDetails)
override

◆ itemDragExit()

void Knob::itemDragExit ( const SourceDetails &  dragSourceDetails)
override

◆ itemDropped()

void Knob::itemDropped ( const SourceDetails &  dragSourceDetails)
override

◆ timerCallback()

void Knob::timerCallback ( )
overrideprotected

◆ learnSourceChanged()

void Knob::learnSourceChanged ( ModSrcId  )
overrideprotectedvirtual

Reimplemented from ModMatrix::Listener.

◆ modMatrixChanged()

void Knob::modMatrixChanged ( )
overrideprotectedvirtual

Reimplemented from ModMatrix::Listener.

Referenced by setLiveValuesCallback().

◆ showModMenu()

void Knob::showModMenu ( )
protected

Member Data Documentation

◆ name

juce::Label Knob::name
protected

◆ value

Readout Knob::value
protected

Referenced by getReadout().

◆ knob

PluginSlider Knob::knob
protected

Referenced by getSlider().

◆ learning

bool Knob::learning = false
protected

◆ modDepth

float Knob::modDepth = 0.0f
protected

◆ dragOver

bool Knob::dragOver = false
protected

◆ modTimer

gin::CoalescedTimer Knob::modTimer
protected

◆ shiftTimer

gin::CoalescedTimer Knob::shiftTimer
protected

◆ modValues

juce::Array<float> Knob::modValues
protected

◆ liveValuesCallback

std::function<juce::Array<float>)> Knob::liveValuesCallback
protected

Referenced by setLiveValuesCallback().

◆ modDepthSlider

gin::ModulationDepthSlider Knob::modDepthSlider
protected

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