@clevername27 No sorry, I think I ended up removing the SN network entirely
Posts made by iamlamprey
-
RE: Error loading ScriptNode Voice Killer
-
RE: Smoother Dynamic Crossfades
@HISEnberg NEATBrain doesn't use any crossfading shenanigans, it just loops a single cycle at its fundamental frequency to simulate a wavetable synth
-
RE: Plugin Parameters aren't working (Rhapsody)
@d-healey I just realized a pretty decent workaround is to assign relevant GUI parameters to CC messages, that way the end user can also right-click and bind/unbind whatever they want for automation AND if you stick to conventional CC (like assigning Attack to CC73), most workstations will label them automatically.
-
RE: AHDSR w/ values higher than 20000?
@d-healey Like I said it's not a HUGE requirement, I like to end some songs with a long fade guitar chord to transition into some other sections or whatever, I can always just max the Sustain and use volume automation before the amp :)
-
RE: Plugin Parameters aren't working (Rhapsody)
So you would have to compile Rhapsody with
HISE_MACROS_ARE_PLUGIN_PARAMETERS=1 HISE_NUM_MACROS=8 (or whatever)
I've implemented this for a particular project, but I tried to enable the use-case of Rhapsody (or other Full-Instrument players) with this too so let me know if there are some issues.
@d-healey have you gotten around to this? ran into this issue again today
-
RE: AHDSR w/ values higher than 20000?
@iamlamprey ah just found this comment at the top of the cpp file:
/*// This is an automatically generated GUI class created by the Introjucer! Be careful when adding custom code to these files, as only the code within the "//[xyz]" and "//[/xyz]" sections will be retained when the file is loaded and re-saved. */
edit: appending the code there compiles, but crashes HISE when I add an envelope. it's not too important of a feature so i don't really care to test any more ¯_(ツ)_/¯
-
RE: AHDSR w/ values higher than 20000?
@orange I only see these:
addAndMakeVisible (decaySlider = new HiSlider ("Decay")); decaySlider->setRange (1, 20000, 1);
The rest of the results seem to be related to Scriptnode, dsp unit tests or otherwise commented out
-
RE: AHDSR w/ values higher than 20000?
@orange Just tried modifying it and it doesn't seem to change anything (limit still capped at 20000), plus I'm not sure if source code changes will propagate down to the exported Rhapsody Library, since I think that depends on the HISE settings that originally compiled it.
Unless I'm wrong? @d-healey
-
AHDSR w/ values higher than 20000?
Is this possible? Can't find a preprocessor or anything for it, ideally I would avoid ScriptNode because it's a Rhapsody library and some networks can be a bit weird in it
-
RE: LFO slower than 0.5Hz?
@d-healey are sub 0.5hz LFOs supported in Rhapsody? also should the default not just be 0.01hz? Is there any reason why we should need the preprocessor flag?
-
RE: Need help with importing samples via script
Another error related to this line:
var importedSamples = Sampler1.asSampler().importSamples([path], false);
Exception thrown: read access violation. std::_Atomic_address_as<long,std::_Atomic_padded<int> >(...) returned 0xFFFFFFFFFFFFFFFF.
This Atomic file is part of VS2022 so I'm in uncharted waters now I think
-
RE: Need help with importing samples via script
okay nope, still crashing, now with a different jassert:
// if this hits, you're using multiple writer threads. consider the ScopedMultiWriteLock instead jassert(lock.writer == thisId || lock.writer == i);
@Christoph-Hart is this a drive-related error? its an old dying HDD so I'm assuming it's related
-
RE: Need help with importing samples via script
Okay I've moved
Sampler1.setAttribute(Sampler1.RRGroupAmount, NUM_ROUNDROBINS);
out of the internal function so it's only being called once, silly me -
RE: Need help with importing samples via script
@dannytaurus Yeh I pasted that hastily, it's part of a larger function but includes the important parts.
I just debugged it and got a seemingly unrelated error so I'm thinking the problem is actually due to this line:
Sampler1.setAttribute(Sampler1.RRGroupAmount, NUM_ROUNDROBINS);
I'll keep digging
-
Need help with importing samples via script
I have a backend script that has to import some 1600 (small) samples, set various sample attributes (root, velocity, RRgroup etc) then save the sampleMap but every time I run it it crashes HISE.
What are the best practices for batch importing like this? Tried:
- Background worker with
killAllVoicesAndCall
which made it worse - Switching from HDD to SSD (lol)
- inline vs regular function, inline seems to be a bit more stable but still crashy
- using less (200) samples, still crashes just as often
samples = FileSystem.findFiles(samplesFolder, "*.wav", false); for (i=0; i<samples.length; i++) { // Get sample name as string prefix = "{PROJECT_FOLDER}" + samplesFolder.toString(1) + "/"; name = samples[i].toString(3); path = prefix + name; // Set the RR Group Amount & Import Samples Sampler1.setAttribute(Sampler1.RRGroupAmount, NUM_ROUNDROBINS); var importedSamples = Sampler1.asSampler().importSamples([path], false); for (s in importedSamples) { sT = s.get(Sampler.FileName); idx = sT.indexOf("root") + 4; subString = sT.substring(idx, sT.length); idxEnd = subString.indexOf("_"); subString = subString.substring(0, idxEnd); rootNote = Math.round(subString); //s.set(Sampler.LoKey, 64); // doesn't work // Low Key Fix for (x = 3; x < 5; x++) { s.set(x, lowKey); } s.set(Sampler.Root, rootNote); s.set(Sampler.HiKey, highKey); // etc Sampler1.asSampler().saveCurrentSampleMap(sampleMapName); }
- Background worker with
-
RE: Loris processCustom with Lambda arguments?
@iamlamprey Okay a simple workaround is to just call another inline function inside the Loris one:
inline function adjustHarmonicGain(partial, freq, target, tolerance, multiplier) { // Adjusts the gains of any partials that lie within the tolerance of a target frequency local spectralDistance = freq > target ? freq - target : target - freq; if (spectralDistance < tolerance) partial.gain *= multiplier; } inline function myCoolFunction(obj) { adjustHarmonicGain(obj, obj.frequency, 440.0, 50.0, 0.0); // works } lorisManager.processCustom(file, myCoolFunction);
-
RE: Loris processCustom with Lambda arguments?
Yeah that works for regular functions but Loris is a bit different:
// works function myCoolFunction(obj) { // even Console.print(obj.frequency) here crashes HISE obj.frequency = 440.0; // works } // doesn't work function myLessCoolFunction(obj, f) { obj.frequency = f; } // obj is already defined by a separate Loris process: lorisManager.analyse(file, f0); // this is our obj, we don't need to declare it or pass it to the function // works lorisManager.processCustom(file, myCoolFunction); // no parameters, just the function name // breaks lorisManager.processCustom(file, myLessCoolFunction(obj, 440.0)); // standard lambdas also break lorisManager.processCustom(file, function [obj, 440.0](myLessCoolFunction)); // "can't capture anonymous expression"
It's not a huge deal, I can just make a few variants of the function ¯_(ツ)_/¯
-
Loris applyFilter doesn't seem to work
Unless I'm not shaping the
data
object correctly for the filter?// using time in seconds (default) // pitch shift works (example from the Loris docs) var pitchShiftData = [[0.0, 0], [0.2, 0], [0.4, 300], [0.4, -300], [0.6, 0]]; lorisManager.process(file, "shiftPitch", data); // doesn't work, just mutes the output var filterData = [[0.0, 0], [0.2, 0], [0.4, 1], [0.4, .5], [0.6, 0]]; lorisManager.process(file, "applyFilter", filterData); // also doesn't work, same result var filterData = [[0.0, 0], [0.2, 0], [0.4, 20000], [0.4, 10000], [0.6, 0]]; lorisManager.process(file, "applyFilter", filterData);
Edit - here's the source code for it:
if (command == ProcessIds::applyFilter) { juce::ScopedValueSetter<TimeDomainType> svs(options.currentDomainType, TimeDomainType::Frequency); auto env = createEnvelopeFromJSON(data); for (auto& l : list) // for each partial { for (auto& p : *l) // i assume this is the envelope { for (auto& b : p) // for each breakpoint in the envelope { auto freq = breakpoint_getFrequency(&b); // "returns the frequency of the specified breakpoint" auto gain = linearEnvelope_valueAt(env, freq); // "returns the interpolated value of this linearEnvelope at the specified time" gain *= breakpoint_getAmplitude(&b); // "returns the absolute amplitude of the specified breakpoint" breakpoint_setAmplitude(&b, gain); // "assigns a new (absolute) amplitude to the specified breakpoint" } } } destroyLinearEnvelope(env); return true; }
Shouldn't the
linearEnvelope_valueAt
function be taking a time value, not a frequency? Or is that being handled by the ScopedValueSetter? -
Loris processCustom with Lambda arguments?
Pretty sure I've asked something like this before but I can't find the thread, is there a way to pass arguments to the processCustom lambda function?
inline function myCoolFunction(obj, f) { obj.frequency = f; } lorisManager.processCustom(audio, myCoolFunction(440.0)); // ?
Inline function call myCoolFunction: parameter amount mismatch: 1 (Expected: 2)