Public Member Functions | List of all members
SamplerSoundWaveform Class Reference

A component that displays the waveform of a sample. More...

Inheritance diagram for SamplerSoundWaveform:
AudioDisplayComponent

Public Member Functions

void drawSampleStartBar (Graphics &g)
 draws a vertical ruler at the position where the sample was recently started. More...
 
 SamplerSoundWaveform (const ModulatorSampler *ownerSampler)
 Creates a new SamplerSoundWaveform. More...
 
void setSoundToDisplay (const ModulatorSamplerSound *s, int multiMicIndex=0)
 Sets the currently displayed sound. More...
 
void timerCallback () override
 used to display the playing positions / sample start position. More...
 
void toggleRangeEnabled (AreaTypes type)
 enables the range (makes it possible to drag the edges). More...
 
void updateRanges (SampleArea *areaToSkip=nullptr) override
 Call this whenever the sample ranges change. More...
 
- Public Member Functions inherited from AudioDisplayComponent
void addAreaListener (Listener *l)
 Adds an AreaListener that will be informed whenever a Area was dragged. More...
 
void drawPlaybackBar (Graphics &g)
 draws a vertical ruler to display the current playing position. More...
 
void setCurrentArea (SampleArea *area)
 Sets the current Area . More...
 
void setPlaybackPosition (double normalizedPlaybackPosition)
 Sets the playback position for (0 ... More...
 
virtual ~AudioDisplayComponent ()
 Removes all listeners. More...
 

Detailed Description

A component that displays the waveform of a sample.

It uses a thumbnail data to display the waveform of the selected ModulatorSamplerSound and has some SampleArea objects that allow changing of its sample ranges (playback range, loop range etc.)

See also
SampleArea.

It uses a timer to display the current playbar.

Constructor & Destructor Documentation

SamplerSoundWaveform ( const ModulatorSampler ownerSampler)

Creates a new SamplerSoundWaveform.

Parameters
ownerSamplerthe ModulatorSampler that the SamplerSoundWaveform should use.

Member Function Documentation

void drawSampleStartBar ( Graphics &  g)

draws a vertical ruler at the position where the sample was recently started.

void setSoundToDisplay ( const ModulatorSamplerSound s,
int  multiMicIndex = 0 
)

Sets the currently displayed sound.

It listens for the global sound selection and displays the last selected sound if the selection changes.

void timerCallback ( )
override

used to display the playing positions / sample start position.

void toggleRangeEnabled ( AreaTypes  type)

enables the range (makes it possible to drag the edges).

void updateRanges ( SampleArea areaToSkip = nullptr)
overridevirtual

Call this whenever the sample ranges change.

If you only want to refresh the sample area (while dragging), use refreshSampleAreaBounds() instead.

Implements AudioDisplayComponent.

©2017 HISE. This documentation is autogenerated from the HISE source code using Doxygen.