LMMS
Loading...
Searching...
No Matches
water::SynthesiserSound Class Referenceabstract

#include <Synthesiser.h>

Inheritance diagram for water::SynthesiserSound:
water::ReferenceCountedObject sfzero::Sound

Public Types

typedef ReferenceCountedObjectPtr< SynthesiserSoundPtr

Public Member Functions

virtual ~SynthesiserSound ()
virtual bool appliesToNote (int midiNoteNumber)=0
virtual bool appliesToChannel (int midiChannel)=0
Public Member Functions inherited from water::ReferenceCountedObject
void incReferenceCount () noexcept
void decReferenceCount () noexcept
bool decReferenceCountWithoutDeleting () noexcept
int getReferenceCount () const noexcept

Protected Member Functions

 SynthesiserSound ()
Protected Member Functions inherited from water::ReferenceCountedObject
 ReferenceCountedObject ()
virtual ~ReferenceCountedObject ()
void resetReferenceCount () noexcept

Detailed Description

Describes one of the sounds that a Synthesiser can play.

A synthesiser can contain one or more sounds, and a sound can choose which midi notes and channels can trigger it.

The SynthesiserSound is a passive class that just describes what the sound is - the actual audio rendering for a sound is done by a SynthesiserVoice. This allows more than one SynthesiserVoice to play the same sound at the same time.

See also
Synthesiser, SynthesiserVoice

Member Typedef Documentation

◆ Ptr

The class is reference-counted, so this is a handy pointer class for it.

Constructor & Destructor Documentation

◆ SynthesiserSound()

water::SynthesiserSound::SynthesiserSound ( )
protected

◆ ~SynthesiserSound()

water::SynthesiserSound::~SynthesiserSound ( )
virtual

Destructor.

Member Function Documentation

◆ appliesToChannel()

virtual bool water::SynthesiserSound::appliesToChannel ( int midiChannel)
pure virtual

Returns true if the sound should be triggered by midi events on a given channel.

The Synthesiser will use this information when deciding which sounds to trigger for a given note.

Implemented in sfzero::Sound.

◆ appliesToNote()

virtual bool water::SynthesiserSound::appliesToNote ( int midiNoteNumber)
pure virtual

Returns true if this sound should be played when a given midi note is pressed.

The Synthesiser will use this information when deciding which sounds to trigger for a given note.

Implemented in sfzero::Sound.


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