62 "All Notes",
"C3",
"C#3",
"D3",
"D#3",
"E3",
"F3",
"F#3",
"G3",
"G#3",
"A3",
"A#3",
"B3",
63 "C4",
"C#4",
"D4",
"D#4",
"E4",
"F4",
"F#4",
"G4",
"G#4",
"A4",
"A#4",
"B4"};
79 if (embeddingsFile.exists())
83 std::make_unique<NearestNeighbourSearch>(embeddingsFile.getFullPathName().toStdString());
100 newSample.muteChanged = [
this, &newSample]() {
111 param.valueChanged = [
this](
const var& value) {
112 auto files = StringArray::fromLines(value.toString());
118 AudioFormatManager formatManager;
119 formatManager.registerBasicFormats();
120 for (
auto file : files)
124 File directoryPath(convertedFile);
126 if (directoryPath.isDirectory())
129 auto foundFiles = directoryPath.findChildFiles(
130 File::findFiles,
true, formatManager.getWildcardForAllFormats() +
";*" +
".kaf");
131 for (
auto f : foundFiles)
133 samplesTree->updateSample(f.getFileNameWithoutExtension(), f.getFullPathName());
138 samplesTree->updateSample(convertedFile.getFileNameWithoutExtension(), file);
143 samplesTree->dropCompleted();
150 midimodeParam->valueChanged = [
this](
const var& value) {
151 String newMode = value;
178 const int oldNumberOfModes(5);
179 MIDIMode activeMode =
static_cast<MIDIMode>(newValue *
static_cast<float>(oldNumberOfModes));
224 Array<File> filesToLoad;
234 if (!filesToLoad.isEmpty())
241#ifdef ENABLE_COREENGINE_ANALYSIS
244 if (!filesToLoad.isEmpty())
329 bool activeChild =
false;
334 activeChild = child->isActive(voiceIdx);
350 child->noteOn(voiceIdx, midiNote, velocity);
387 bool noteNORFlagMatchesMode = noteNORFlag ==
m_enableNOR;
396 if (((midiNote &
MIDI_NOTE_MASK) == triggerNote) && noteNORFlagMatchesMode)
411 child->noteOff(voiceIdx, velocity);
430 child->noteCleared(voiceIdx);
522 return std::make_unique<KwidgetProcessor_CoreEngine>(*
this,
m_soSound);
527 return std::make_unique<KwidgetGUI_CoreEngine>(*
this,
m_soSound);
554 if (midiParameter !=
nullptr)
static Array< File > loadFiles(const StringArray &, const bool, const bool willLoadSpecificFiles)
Definition AssetManager.cpp:475
static File getMLEmbeddingsFile()
Definition AssetManager.cpp:413
static File convertFilePath(const String &)
Definition AssetManager.cpp:604
static void alertNonSubscriber()
Definition AssetManagerUI.cpp:17
A wrapper around juce::ValueTree designed to store custom plugin state (strings, arrays,...
Definition CustomParameter.h:9
void setValue(const var &newValue, bool selfUpdate=false)
Definition CustomParameter.cpp:46
const ValueTree & getParameterTree() const
Definition CustomParameterTree.h:55
ValueTree getChild(int index) const
Definition CustomParameterTree.cpp:54
static const float defaultSliderSkew
Definition constants.h:26
An exception for asset manager, specifc to encrypted assets.
Definition AssetManager.h:167
@ Unipolar
Definition KAttachment.h:122
float get() const
Definition KParameter.cpp:126
void set(float newValue)
Definition KParameter.cpp:128
void setTrackingCycles(float newValue)
Definition KrotosAudioBufferDSP.h:482
void analyse()
analyse Analyses the audio waveform stored in the buffer according to the selected scheme This method...
Definition KrotosAudioBufferDSP.cpp:35
void setTrackingValue(float newValue)
Definition KrotosAudioBufferDSP.h:480
void setAnalysisScheme(AnalysisScheme scheme)
Definition KrotosAudioBufferDSP.h:506
void canReadSpecificFiles(bool canRead)
Definition KrotosSynthesiserSound.h:46
SampleEngine * getSampleEngine() override
Definition KrotosSynthesiserSound.h:44
int loadSounds(juce::Array< File > audioSampleFiles, bool getNearest)
Definition KrotosSynthesiserSound.cpp:139
ValueTree addModulation(const String &sourceID, int modulatorIdx, const String &destinationID, const String ¶mID, float depth=DefaultModDepth, KAttachment::Polarity=KAttachment::Polarity::Bipolar)
Definition ParameterManager.cpp:159
static const float OnOffThreshold
The threshold at which a toggle, or "on/off" parameter should change from on to off stage.
Definition ParameterManager.h:45
void setGranularOscillatorTypeIndicator(GranularPlaybackMode newType)
Definition SampleEngine.h:133
void setSegmentMuted(int segmentIndex, bool isMuted)
'Mutes' an audio segment in the sampler. In effect, this just means the sample is skipped in the roun...
Definition SampleEngine.cpp:372
void setSelectionRanges(const std::vector< Range< int > > &selectionRanges)
Sets the selection ranges of the audio segments.
Definition SampleEngine.cpp:106
std::vector< Range< int > > getSelectionRanges()
Returns an array of segment selection ranges.
Definition SampleEngine.cpp:96
void setGranularOscillatorMIDIMode(MIDIMode newMode)
Definition SampleEngine.h:141
A wrapper around an individual sample in the tree, with parameters for mute, solo,...
Definition SampleDataTree.h:38
void setSampleIndex(int index)
Set the current index of the sample playback queue.
Definition SampleDataTree.cpp:193
std::function< void()> dropCompleted
Assign this to do something once a "drop" action has been completed. This is called internally by the...
Definition SampleDataTree.h:175
std::function< void(Sample &newSample)> sampleAdded
Assign this to do something when a sample has been added to the tree.
Definition SampleDataTree.h:151
void setSampleSelections(const std::vector< Range< int > > &selections)
Set the selection ranges for all samples in the tree. The index of the selection range in the vector ...
Definition SampleDataTree.cpp:157
std::vector< Range< int > > getSampleSelections() const
Get the selection ranges for all samples in the tree. The index of the selection range in the vector ...
Definition SampleDataTree.cpp:145
std::function< void(ValueTree &childWhichHasBeenRemoved, int indexFromWhichChildWasRemoved)> sampleRemoved
Assign this to do something when a sample has been removed from the tree.
Definition SampleDataTree.h:155
const StringArray getFiles() const
Compatibility method for KrotosSampleOscillatorSound which requires samples to be loaded all at once ...
Definition SampleDataTree.cpp:122
Definition AirAbsorptionFilter.cpp:2
static const int MIDI_NOTE_MASK
Definition OscillatorUtils.h:21
static const int NUM_VOICES_POLY
Definition OscillatorUtils.h:32
static const int NUM_VOICES_DRONE
Definition OscillatorUtils.h:33
GranularPlaybackMode
Definition SampleEngine.h:46
static const int MIDI_NOTE_FLAG_FLUSH
Definition OscillatorUtils.h:24
static const int MIDI_NOTE_FLAG_NOR
Definition OscillatorUtils.h:25
static const int MIDI_NOTE_FLAG_DRONE_NOTEUP
Definition OscillatorUtils.h:23
static const int MIDI_NOTE_NUMBER_C3
Definition OscillatorUtils.h:26
MIDIMode
Definition SampleEngine.h:54
static const Identifier Mute
Definition SampleDataTree.h:22
static const Identifier Samples
Definition SampleDataTree.h:13