Deluge Firmware 1.3.0
Build date: 2025.04.16
Loading...
Searching...
No Matches
MelodicInstrument Class Referenceabstract
Inheritance diagram for MelodicInstrument:
Collaboration diagram for MelodicInstrument:

Classes

struct  EarlyNoteInfo
 

Public Member Functions

 MelodicInstrument (OutputType newType)
 
virtual void sendNote (ModelStackWithThreeMainThings *modelStack, bool isOn, int32_t noteCode, int16_t const *mpeValues, int32_t fromMIDIChannel=MIDI_CHANNEL_NONE, uint8_t velocity=64, uint32_t sampleSyncLength=0, int32_t ticksLate=0, uint32_t samplesLate=0)=0
 
virtual void ccReceivedFromInputMIDIChannel (int32_t cc, int32_t value, ModelStackWithTimelineCounter *modelStack)
 
bool writeMelodicInstrumentAttributesToFile (Serializer &writer, Clip *clipForSavingOutputOnly, Song *song)
 
void writeMelodicInstrumentTagsToFile (Serializer &writer, Clip *clipForSavingOutputOnly, Song *song)
 
bool readTagFromFile (Deserializer &reader, char const *tagName) override
 
void offerReceivedNote (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, bool on, int32_t channel, int32_t note, int32_t velocity, bool shouldRecordNotes, bool *doingMidiThru) override
 
void receivedNote (ModelStackWithTimelineCounter *modelStack, MIDICable &cable, bool on, int32_t midiChannel, MIDIMatchType match, int32_t note, int32_t velocity, bool shouldRecordNotes, bool *doingMidiThru)
 
void offerReceivedPitchBend (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, uint8_t channel, uint8_t data1, uint8_t data2, bool *doingMidiThru) override
 
void receivedPitchBend (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, MIDIMatchType match, uint8_t channel, uint8_t data1, uint8_t data2, bool *doingMidiThru)
 
void offerReceivedCC (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, uint8_t channel, uint8_t ccNumber, uint8_t value, bool *doingMidiThru) override
 
void receivedCC (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, MIDIMatchType match, uint8_t channel, uint8_t ccNumber, uint8_t value, bool *doingMidiThru)
 
void offerReceivedAftertouch (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, int32_t channel, int32_t value, int32_t noteCode, bool *doingMidiThru) override
 
void receivedAftertouch (ModelStackWithTimelineCounter *modelStackWithTimelineCounter, MIDICable &cable, MIDIMatchType match, int32_t channel, int32_t value, int32_t noteCode, bool *doingMidiThru)
 
bool setActiveClip (ModelStackWithTimelineCounter *modelStack, PgmChangeSend maySendMIDIPGMs) override
 
bool isNoteRowStillAuditioningAsLinearRecordingEnded (NoteRow *noteRow) final
 
void stopAnyAuditioning (ModelStack *modelStack) final
 
bool isNoteAuditioning (int32_t noteCode)
 
bool isAnyAuditioningHappening () final
 
void beginAuditioningForNote (ModelStack *modelStack, int32_t note, int32_t velocity, int16_t const *mpeValues, int32_t fromMIDIChannel=MIDI_CHANNEL_NONE, uint32_t sampleSyncLength=0)
 
void endAuditioningForNote (ModelStack *modelStack, int32_t note, int32_t velocity=kDefaultLiftValue)
 
virtual ModelStackWithAutoParamgetParamToControlFromInputMIDIChannel (int32_t cc, ModelStackWithThreeMainThings *modelStack)
 
void processParamFromInputMIDIChannel (int32_t cc, int32_t newValue, ModelStackWithTimelineCounter *modelStack) override
 
void polyphonicExpressionEventPossiblyToRecord (ModelStackWithTimelineCounter *modelStack, int32_t newValue, int32_t expressionDimension, int32_t channelOrNoteNumber, MIDICharacteristic whichCharacteristic)
 
ArpeggiatorSettingsgetArpSettings (InstrumentClip *clip=nullptr)
 
virtual void polyphonicExpressionEventOnChannelOrNote (int32_t newValue, int32_t expressionDimension, int32_t channelOrNoteNumber, MIDICharacteristic whichCharacteristic)=0
 
void offerBendRangeUpdate (ModelStack *modelStack, MIDICable &cable, int32_t channelOrZone, int32_t whichBendRange, int32_t bendSemitones) override
 
ModelStackWithAutoParamgetModelStackWithParam (ModelStackWithTimelineCounter *modelStack, Clip *clip, int32_t paramID, deluge::modulation::params::Kind paramKind, bool affectEntire, bool useMenuStack) override
 
- Public Member Functions inherited from Instrument
 Instrument (OutputType newType)
 
bool matchesPreset (OutputType otherType, int32_t channel, int32_t channelSuffix, char const *otherName, char const *otherPath) override
 
virtual bool doAnySoundsUseCC (uint8_t channel, uint8_t ccNumber, uint8_t value)
 
virtual void beenEdited (bool shouldMoveToEmptySlot=true)
 
virtual void setupPatching (ModelStackWithTimelineCounter *modelStack)
 
void deleteAnyInstancesOfClip (InstrumentClip *clip)
 
bool writeDataToFile (Serializer &writer, Clip *clipForSavingOutputOnly, Song *song) override
 
virtual void compensateInstrumentVolumeForResonance (ModelStackWithThreeMainThings *modelStack)
 
char const * getNameXMLTag () override
 
virtual char const * getSlotXMLTag ()
 
virtual char const * getSubSlotXMLTag ()
 
- Public Member Functions inherited from Output
 Output (OutputType newType)
 
ClipgetActiveClip () const
 
virtual void renderOutput (ModelStack *modelStack, std::span< StereoSample > outputBuffer, int32_t *reverbBuffer, int32_t reverbAmountAdjust, int32_t sideChainHitPending, bool shouldLimitDelayFeedback, bool isClipActive)=0
 
virtual void setupWithoutActiveClip (ModelStack *modelStack)
 
void pickAnActiveClipForArrangementPos (ModelStack *modelStack, int32_t arrangementPos, PgmChangeSend maySendMIDIPGMs)
 
void pickAnActiveClipIfPossible (ModelStack *modelStack, bool searchSessionClipsIfNeeded=true, PgmChangeSend maySendMIDIPGMs=PgmChangeSend::ONCE, bool setupWithoutActiveClipIfNeeded=true)
 
void detachActiveClip (Song *currentSong)
 
virtual ModControllabletoModControllable ()
 
virtual bool isSkippingRendering ()
 
bool clipHasInstance (Clip *clip)
 
bool isEmpty (bool displayPopup=true)
 
void clipLengthChanged (Clip *clip, int32_t oldLength)
 
virtual void cutAllSound ()
 
virtual void getThingWithMostReverb (Sound **soundWithMostReverb, ParamManager **paramManagerWithMostReverb, GlobalEffectableForClip **globalEffectableWithMostReverb, int32_t *highestReverbAmountFound)
 
ClipgetClipFromName (String *name)
 If there's a clip matching the name on this output, returns it.
 
virtual bool offerReceivedPitchBendToLearnedParams (MIDICable &cable, uint8_t channel, uint8_t data1, uint8_t data2, ModelStackWithTimelineCounter *modelStack)
 Pitch bend is available in the mod matrix as X and shouldn't be learned to params anymore (post 4.0)
 
virtual void offerReceivedCCToLearnedParams (MIDICable &cable, uint8_t channel, uint8_t ccNumber, uint8_t value, ModelStackWithTimelineCounter *modelStack)
 
virtual int32_t doTickForwardForArp (ModelStack *modelStack, int32_t currentPos)
 
void endAnyArrangementRecording (Song *song, int32_t actualEndPos, uint32_t timeRemainder)
 
virtual bool wantsToBeginArrangementRecording ()
 
virtual Error readFromFile (Deserializer &reader, Song *song, Clip *clip, int32_t readAutomationUpToPos)
 
void writeToFile (Clip *clipForSavingOutputOnly, Song *song)
 
virtual Error loadAllAudioFiles (bool mayActuallyReadFiles)
 
virtual void loadCrucialAudioFilesOnly ()
 
virtual void resyncLFOs ()
 
virtual void sendMIDIPGM ()
 
virtual void deleteBackedUpParamManagers (Song *song)
 
virtual void prepareForHibernationOrDeletion ()
 
virtual char const * getXMLTag ()=0
 
virtual ParamManagergetParamManager (Song *song)
 
Error possiblyBeginArrangementRecording (Song *song, int32_t newPos)
 
void endArrangementPlayback (Song *song, int32_t actualEndPos, uint32_t timeRemainder)
 
virtual bool needsEarlyPlayback () const
 
bool hasRecorder ()
 
bool shouldRenderInSong ()
 
void setRenderingToAudioOutput (bool monitoring, Output *output)
 disable rendering to the song buffer if this clip is the input to an audio output that's monitoring
 
bool addRecorder (SampleRecorder *newRecorder)
 
bool removeRecorder ()
 
OutputgetOutputRecordingThis ()
 

Public Attributes

Arpeggiator arpeggiator
 
deluge::fast_map< int16_t, EarlyNoteInfoearlyNotes
 
deluge::fast_map< int16_t, EarlyNoteInfonotesAuditioned
 
- Public Attributes inherited from Instrument
String dirPath
 
bool editedByUser = false
 
bool existsOnCard = false
 
bool shouldHibernate {true}
 
uint8_t defaultVelocity = FlashStorage::defaultVelocity
 
LearnedMIDI midiInput
 
- Public Attributes inherited from Output
ClipInstanceVector clipInstances
 
String name
 
Outputnext
 
const OutputType type
 
bool mutedInArrangementMode
 
bool mutedInArrangementModeBeforeStemExport
 
bool exportStem
 
bool soloingInArrangementMode
 
bool inValidState
 
bool wasCreatedForAutoOverdub
 
bool armedForRecording
 
int16_t colour {0}
 
uint8_t modKnobMode
 
bool alreadyGotItsNewClip
 
bool isGettingSoloingClip
 
bool nextClipFoundShouldGetArmed
 
bool recordingInArrangement
 

Private Member Functions

void possiblyRefreshAutomationEditorGrid (int32_t ccNumber)
 

Additional Inherited Members

- Protected Member Functions inherited from Instrument
ClipcreateNewClipForArrangementRecording (ModelStack *modelStack) final
 
Error setupDefaultAudioFileDir ()
 
- Protected Member Functions inherited from Output
virtual void clearRecordingFrom ()
 
- Protected Attributes inherited from Output
bool recorderIsEchoing {false}
 
OutputoutputRecordingThisOutput {nullptr}
 
ClipactiveClip {nullptr}
 
SampleRecorderrecorder {nullptr}
 

Member Function Documentation

◆ getModelStackWithParam()

ModelStackWithAutoParam * MelodicInstrument::getModelStackWithParam ( ModelStackWithTimelineCounter * modelStack,
Clip * clip,
int32_t paramID,
deluge::modulation::params::Kind paramKind,
bool affectEntire,
bool useMenuStack )
overridevirtual

Implements Output.

◆ isAnyAuditioningHappening()

bool MelodicInstrument::isAnyAuditioningHappening ( )
finalvirtual

Implements Instrument.

◆ isNoteRowStillAuditioningAsLinearRecordingEnded()

bool MelodicInstrument::isNoteRowStillAuditioningAsLinearRecordingEnded ( NoteRow * noteRow)
finalvirtual

Implements Instrument.

◆ offerBendRangeUpdate()

void MelodicInstrument::offerBendRangeUpdate ( ModelStack * modelStack,
MIDICable & cable,
int32_t channelOrZone,
int32_t whichBendRange,
int32_t bendSemitones )
overridevirtual

Reimplemented from Output.

◆ offerReceivedAftertouch()

void MelodicInstrument::offerReceivedAftertouch ( ModelStackWithTimelineCounter * modelStackWithTimelineCounter,
MIDICable & cable,
int32_t channel,
int32_t value,
int32_t noteCode,
bool * doingMidiThru )
overridevirtual

Reimplemented from Output.

◆ offerReceivedCC()

void MelodicInstrument::offerReceivedCC ( ModelStackWithTimelineCounter * modelStackWithTimelineCounter,
MIDICable & cable,
uint8_t channel,
uint8_t ccNumber,
uint8_t value,
bool * doingMidiThru )
overridevirtual

Reimplemented from Output.

◆ offerReceivedNote()

void MelodicInstrument::offerReceivedNote ( ModelStackWithTimelineCounter * modelStackWithTimelineCounter,
MIDICable & cable,
bool on,
int32_t channel,
int32_t note,
int32_t velocity,
bool shouldRecordNotes,
bool * doingMidiThru )
overridevirtual

Reimplemented from Output.

◆ offerReceivedPitchBend()

void MelodicInstrument::offerReceivedPitchBend ( ModelStackWithTimelineCounter * modelStackWithTimelineCounter,
MIDICable & cable,
uint8_t channel,
uint8_t data1,
uint8_t data2,
bool * doingMidiThru )
overridevirtual

Reimplemented from Output.

◆ processParamFromInputMIDIChannel()

void MelodicInstrument::processParamFromInputMIDIChannel ( int32_t cc,
int32_t newValue,
ModelStackWithTimelineCounter * modelStack )
overridevirtual

Implements Instrument.

◆ readTagFromFile()

bool MelodicInstrument::readTagFromFile ( Deserializer & reader,
char const * tagName )
overridevirtual

Reimplemented from Instrument.

◆ setActiveClip()

bool MelodicInstrument::setActiveClip ( ModelStackWithTimelineCounter * modelStack,
PgmChangeSend maySendMIDIPGMs )
overridevirtual

Reimplemented from Output.

◆ stopAnyAuditioning()

void MelodicInstrument::stopAnyAuditioning ( ModelStack * modelStack)
finalvirtual

Reimplemented from Output.


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