LFO Sync Speeds - make slower
-
How would I go about making LFO speeds of 2/1, 4/1 etc?
-
Scriptnode perhaps
-
I have one question about LFO. I have tried to make Tremolo type of Plugins but Unfortunately inside DAW LFO is out of sync.
If I stop and start from beginning it is synced but if I tweak or change some parameters of GAIN > LFO it is out of SYNC with HOST. Is it a Flaw of HISE/Bug or am I missing something?
-
@DabDab Not sure, start looking through these threads though and I'll think you'll find an answer - https://forum.hise.audio/search?term=lfo sync&in=titlesposts
-
@DanH If you convert your tempo value to frequency, then you can go as low as you want. Even if the min value of the parameter is 0.5Hz, you can go lower with no issues. The module's slider just won't be able to display the value.
-
This post is deleted! -
@d-healey Uuha... Found the answer . It is impossible to make Tremolo or Xfer Records LFO Tools kind of plugins with HISE. :)
Tada... Only with JUCE? I can't make it ;) -
@ustk So this isn't very tricky to achieve via the source code (seemed better to follow Christoph's sample accurate calculations contained there!).
So in hi_tools/hi_tools/MiscToolClasses.cpp - line 805 is where you can add in your own sync time calcs (see the other entries for a guide)
And then in MiscToolClasses.h - line 2029 add in the names for the TempoSync knob (make sure the names you use correspond to the new entries you put into the .cpp file).
Example below (I've had to invent some names )
void TempoSyncer::initTempoData() { tempoNames.add("32/1"); tempoFactors[ThirtyTwouple] = 128.0f; tempoNames.add("16/1"); tempoFactors[Sixteenthuple] = 64.0f; tempoNames.add("8/1"); tempoFactors[Octuple] = 32.0f; tempoNames.add("4/1"); tempoFactors[Quadruple] = 16.0f; tempoNames.add("2/1"); tempoFactors[Double] = 8.0f; tempoNames.add("1/1"); tempoFactors[Whole] = 4.0f; tempoNames.add("1/2D"); tempoFactors[HalfDuet] = 2.0f * 1.5f; tempoNames.add("1/2"); tempoFactors[Half] = 2.0f; tempoNames.add("1/2T"); tempoFactors[HalfTriplet] = 4.0f / 3.0f; tempoNames.add("1/4D"); tempoFactors[QuarterDuet] = 1.0f * 1.5f; tempoNames.add("1/4"); tempoFactors[Quarter] = 1.0f; tempoNames.add("1/4T"); tempoFactors[QuarterTriplet] = 2.0f / 3.0f; tempoNames.add("1/8D"); tempoFactors[EighthDuet] = 0.5f * 1.5f; tempoNames.add("1/8"); tempoFactors[Eighth] = 0.5f; tempoNames.add("1/8T"); tempoFactors[EighthTriplet] = 1.0f / 3.0f; tempoNames.add("1/16D"); tempoFactors[SixteenthDuet] = 0.25f * 1.5f; tempoNames.add("1/16"); tempoFactors[Sixteenth] = 0.25f; tempoNames.add("1/16T"); tempoFactors[SixteenthTriplet] = 0.5f / 3.0f; tempoNames.add("1/32D"); tempoFactors[ThirtyTwoDuet] = 0.125f * 1.5f; tempoNames.add("1/32"); tempoFactors[ThirtyTwo] = 0.125f; tempoNames.add("1/32T"); tempoFactors[ThirtyTwoTriplet] = 0.25f / 3.0f; tempoNames.add("1/64D"); tempoFactors[SixtyForthDuet] = 0.125f * 0.5f * 1.5f; tempoNames.add("1/64"); tempoFactors[SixtyForth] = 0.125f * 0.5f; tempoNames.add("1/64T"); tempoFactors[SixtyForthTriplet] = 0.125f / 3.0f; }
/** The note values. */ enum Tempo { ThirtyTwouple = 0, Sixteenthuple, Octuple, Quadruple, Double, Whole, ///< a whole note (1/1) HalfDuet, ///< a half note duole (1/2D) Half, ///< a half note (1/2) HalfTriplet, ///< a half triplet note (1/2T) QuarterDuet, ///< a quarter note duole (1/4D) Quarter, ///< a quarter note (1/4) QuarterTriplet, ///< a quarter triplet note (1/4T) EighthDuet, ///< a eight note duole (1/8D) Eighth, ///< a eighth note (1/8) EighthTriplet, ///< a eighth triplet note (1/8T) SixteenthDuet, ///< a sixteenth duole (1/16D) Sixteenth, ///< a sixteenth note (1/16) SixteenthTriplet, ///< a sixteenth triplet (1/16T) ThirtyTwoDuet, ///< a 32th duole (1/32D) ThirtyTwo, ///< a 32th note (1/32) ThirtyTwoTriplet, ///< a 32th triplet (1/32T) SixtyForthDuet, ///< a 64th duole (1/64D) SixtyForth, ///< a 64th note (1/64) SixtyForthTriplet, ///> a 64th triplet 1/64T) numTempos };
Is this worth making a pull request? I'm not familiar with the process.
TBH it would probably take @Christoph-Hart all of two minutes to implement
... So far the issues I've found are with the Delay not using the new sync times, and the potentially destructive scenario for existing projects as currently the TempoSync knob's values will be different to before. A potential way around this would be to make the TempoSync knob more like the Pan knob, in that it has a negative value, and store the new (slower) sync times on the negative side.
Works nicely on the arp.
-
@DanH It's a nice solution, but it'll break compatibility. enum is index base, and tempo knobs are index-based too (0 to 18). So even if you set tempo-like knob ranges to 23 (18+5), old projects will be shifted down by 5...
The only way not to break compatibility would be to put them at the end of the enum (but it's dirty), or somehow make a dedicated function...Although negative value as you said might be a solution, but I don't know C++ enough to tell if it works with enum. But it's a nice idea ;) Try it and tell :)
-
@ustk Right - so what is an enum exactly? Can they be negative too?
-
@DanH A search online will give you much more info on enum than I can...
Apparently, enum can be negative as it is just an integer. So try -5, so "Whole will still begins at 0... -
@ustk It shouldn't break compatibility, that's what enums are for... so each enum is a named constant with a value assigned, all you should have to do is reassign the values. Unless people have used "magic numbers" in their scripts instead of the enums.
-
@ustk oh yeah lol, good idea trying now
-
ThirtyTwouple = -5,
didn't work, anything other than '0' and HISE will build but crash upon opening
I tried keeping 'Whole = 0,' earlier and that sets whole as the first position on the knob (so nothing below). Obviously the '0' designates the start position of the knob but it doesn't look at anything below it
-
@DanH @Christoph-Hart would you consider implementing the slower LFO speeds into HISE? I reckon its a reasonable request, electronic producers have a need for these :)
-
@DanH You can already do this with scriptnode I think
-
@d-healey I haven't tried but it's more about getting the continuity with the TempoSync knob and existing projects. I've got a load of Global Modulators!
-
@DanH said in LFO Sync Speeds - make slower:
MiscToolClasses.cpp
Dan
on what commit you did these changes?
latest Layout doesn't export Instruments :/
do you have a stable version? -
-
@d-healey Going to build now
Just made the Changes on A version of New layout to check if Things going Good Here with temmpo Knob.