How do you Tempo Sync ADSR?
-
@Delamere I've had a play around, I haven't been able to solve it, yet, but I'm going to bed. I don't think you need the split node.
I think you need a sig2mod before the ahdsr node, and the mod2sig after it.
There's still something missing but I don't know what - forum search might help.
HiseSnippet 2003.3oc6Z0zaaajFdnrG6XmD2FfhBTfdPnHXQ5h.CI4OhM5Aq3uRLRjiPni6dZMFSNxZfImQkbjs0tn.8Xus60dq.8WwdZWf8zdq+D7Og7On66vOLGZQJSIKaWTXmKgyGbdded+dDa5Irn99BOjwr60qCEY7HrYOtr8FsILNZmMQFygaP7kTuxgCsduNDeepMxvXhWoFvXlIQA+8w0Vm3P3VzjgPn8ELK5aYtLYxnMq+Fliy1Da5dLWsUuX8crD7MDNht.dl.WA0gXcL4H5tD0xJgQul32FY7mwUVZ0Uqb3JuX0JsVtZUxJqtxxGRpT0dQK5JUI0VsU0WT6vCsrPFSskMSJ7LkDI0GYL45B6dlsEmxCOf8Y9rCcnpGphLgSNb3sEN1JQTMJZi1LG6lwDkOBYfalPaSDRaeFtAylcw3Iz2mFLQ4jcnSfFkRCuIRAup5vqhF7x.RFZPZxPH8DrokGqiLYFEddHdGNnMaQ.8jNTBWKx3ei2P.KfKm2kbLcaO3gK1vyVd4JOu7Kp70eSqtbKISvKK36Jjz2we1WO6ee1Yl86ms7kmpUqLmScJdBGGpWlSqrL7FzFeFuq6gTumW9DhSW5EKDj9zTJNeJUWiaEJzZKTv2gyjuqCkmmc.JhoTVDQnBVpLf7mKh7McX1TODC33owugKNrJJ.vIV8+o5nBu4ZWmMuv0YyKlZy+7uT570J9lWJiS9C6rIQRTVtQrHvrcndRlRoYrI8DHtQnc7L3Mo9GKEcBnY2NBthyMl6JI5yRNvmVum9CtLaaGZSgOSYTkLyWUGhz0wj82n5g0bIZuoZ06DaBrCbVeYzwWdK9ITGPBJ2PX20g.VfUgvWdPjKv4QsxGfeoTBwyPtBapxObOJHKPvVKjjdlTaAmxrksSNw+Z81T1Qs0BftScaZKRWG49YnPKLAUSif9Axc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7bRYuaLdTbHzfr2CeAEWsoEuI14MEy7o33tgmOb194l38U3nK3A1P7mf2sqqFwEg4vqK.Ydp5lZShCURefzwk7uzx6eV0ES3POK9mZbSleGGRu061pUjFK0HJ7wsomovxuA+sk6gTaPlB1tRDSqtmYnCu8i+2h4QTe2F+u.08EsRWPegmVeXBwMNLHebDBeKELhFsXb2PbWTaSEj4VLel6FBew0gVL.9e7tt.bnUsI+Nawdn3JyuTN724qcayeIUcb8Uw2vNGaz06j9f44qkGSdKT.vCwIWhcAouQoDfgFWSgeEneFBHkQoqoKG.RoWCRsmY4.wykU4.wy8GrxARgP7vivgs.87xfkSE5WJAdNcgj5dxuTy8g8Cft4krryubsjqzWW4ckfkShowljUarIYW6LZIeMaoksvLcESzxok33S5VPgkalvZiKU1B4nxVWHN1kD76JNReQeikueiIJz2uwX+WFez+VNFOP48htRF+nFDHOtpkEnoJSHKkU7OCqebKUQOWIN+kIkaWItGmnIqpd1HZxpwSdqbFtDKOwAQW2kxb7AAi.xMOJUbC0yk66KmEgbY1rCTel25up91XsQciKLpabwQciKMpab4QciuXT23JW8FUe2JQkbqbYgPcM2JrWZi3qeB7NP+er6Wt7D
-
@d-healey I just took out the last 'mod2sig' and it seems to work as desired....
@Delamere
check this...HiseSnippet 2003.3oc6ZszaaarEdnrG6XmD2FffBTftP3hhhzf.A8v1MAcgT7qTiV4HD536cUMFSNxZfImQkjx1pO.5xt61scW2zeDcUu.2Uc2cycu61Bzh7On8L7g4PIRYJ4WoE1Zi4Lygy24aNOGoVNBCpqqvAoM+186RQZ2Aq2m60Y0NDFGs4ZHsEvMItdTmhACsR+tDWWpIRSapmIGPatoQ9+8p5qPrHbCZ7PHzNBlA8SX1Lu3Qa03iYVVaPLoayrUV8hM1zPvWUXI5A3YJbYTWhwAj8oaQjKq.F8QD2NHsGhqVsswiKW9w0psTYBolIgrXEZsmPaubaikJ+jxl6sTY3yxHsYV2j4Ibz8HdTWj1zqHL6q2QbDOXC1g4x1yhJenBRG14fg2P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m0BmrRzjWI6gMwvQra30ZIM6tk+HfdyCS41T9bwg9kvhP1LS1tFFIeUCIX0IUvZSpfKNoBtzjJ3xSpfevjJ3iOaAk+NTBKsV5ZBgzZsdPOyZQWyD3Qf9SDUcmDA
-
@Chazrox @d-healey thanks a lot guys, this works. I’ve just realised there’s an issue in doing this though, the fastest tempo the tempo sync can reach is 1/16T and say for example you were making a pluck, there doesn’t seem to be a way to change the Attack, Hold & Release to be 0ms to turn them off. Any idea if there’s a way?
-
@Delamere I was gonna say that but I figured you had thought it through after all that so I didn't mention that. Thats a pretty crucial aspect. Its possible to script some case switches or something. Not impossible but definitely complicates the script a tad.
-
@Delamere compile with
HISE_USE_EXTENDED_TEMPO_VALUES=1
-
@d-healey Sorry how do I do that? Thanks.
-
@Delamere Have you compiled HISE before?
-
@d-healey I'm not sure, I think so. Do you mean in Projucer? I have searched how to compile in HISE and the steps it's saying to take I have already done, not sure I've done them 100% correct. Do you mean to open, HISE Standalone.jucer? Then if I select Exporters > Xcode (macOS) there is a section to add Extra Preprocessor Definitions? Or am I misunderstanding? Thanks again.
-
@Delamere Yes, it's the Extra Preprocessor Definitions where you need to add it. Then recompile HISE
You also need to add it in your project preferences within HISE.
-
@d-healey when you say "Then recompile HISE" do you mean to do this?
And is this what you mean by adding it in my project preferences?
-
@Delamere yes and yes and you'll also need to add it to the script node extra definitions, also in project preferences
-
@d-healey okay thanks, I can't see the script node extra definitions in the project preferences, is it called something else?
-
@Delamere Extra Definitions Network Dll - you may as well add it to all the extra definitions boxes except iOS.
-
@d-healey Okay thanks, I thought it may be that and I've now added it to the others. There is now a difference but it's still not working. Say for example I change the knobs maximum value to be 20 instead of 18, the tempo knob goes past 1/64t, but the beats values no longer appear and the value in ms still doesn't go any further than 20ms.
-
@Delamere Did you recompile HISE?
-
@d-healey Yeah, just done it after you said but there's still no difference.
The value of the attack in the first screenshot is at 19.0, but it hasn't gone past 1/64t (20ms) despite moving.
In the second screenshot, I have changed the value from 18 to 20 in tempo sync mode expecting the attack to go past 1/64t?
-
@Delamere said in How do you Tempo Sync ADSR?:
but it hasn't gone past 1/64t (20ms) despite moving
tempo_sync node faster than 1/64t
I would like to know if there is a trick to set the node 'tempo_sync' faster than 1/64t? Intuitively I think I should use .getHostBPM and .setHostBPM or is t...
Forum (forum.hise.audio)
it is not possible without modifying the HISE source code and recompiling it. The solution is in the link.
-
@Delamere said in How do you Tempo Sync ADSR?:
In the second screenshot, I have changed the value from 18 to 20 in tempo sync mode expecting the attack to go past 1/64t?
23 is the top value I think. But yeah 1/64t is the highest.
-
@Mighty23 thanks, I'm fairly new to HISE so I'm not sure I understand. Do you mean, to replace this..
with..
Then Recompile?
Thanks.
-
@Delamere
hi_tools/hi_tools/MiscToolClasses.cpp
in HISE source code.Find this line and edit as you need, adding tempo values:
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; }
and this:
MiscToolClasses.h
/** 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 };
once you find these lines in the HISE source code, you will need to add the timing parameters you want to add, something like this: .cpp
// (..........) setTempo(ThirtyTwo, "1/32", 0.125f); setTempo(ThirtyTwoTriplet, "1/32T", 0.25f / 3.0f); setTempo(SixtyForthDuet, "1/64D", 0.125f * 0.5f * 1.5f); setTempo(SixtyForth, "1/64", 0.125f * 0.5f); setTempo(SixtyForthTriplet, "1/64T", 0.125f / 3.0f); // new tempos setTempo(HundredTwentyEighthDuet, "1/128D", 0.125f * 0.25f * 1.5f); setTempo(HundredTwentyEighth, "1/128", 0.125f * 0.25f); setTempo(HundredTwentyEighthTriplet, "1/128T", 0.0625f / 3.0f); setTempo(TwoHundredFiftySixthDuet, "1/256D", 0.125f * 0.125f * 1.5f); setTempo(TwoHundredFiftySixth, "1/256", 0.125f * 0.125f); setTempo(TwoHundredFiftySixthTriplet, "1/256T", 0.03125f / 3.0f); setTempo(FiveHundredTwelfthDuet, "1/512D", 0.125f * 0.0625f * 1.5f); setTempo(FiveHundredTwelfth, "1/512", 0.125f * 0.0625f); setTempo(FiveHundredTwelfthTriplet, "1/512T", 0.015625f / 3.0f);
in .h:
SixtyForthDuet, ///< a 64th duole (1/64D) SixtyForth, ///< a 64th note (1/64) SixtyForthTriplet, ///> a 64th triplet 1/64T) // add those lines for faster tempos: HundredTwentyEighthDuet, ///< a 128th note with dot HundredTwentyEighth, ///< a 128th note HundredTwentyEighthTriplet, ///< a 128th note triplet TwoHundredFiftySixthDuet, ///< a 256th note with dot TwoHundredFiftySixth, ///< a 256th note TwoHundredFiftySixthTriplet, ///< a 256th note triplet FiveHundredTwelfthDuet, ///< a 512th note with dot FiveHundredTwelfth, ///< a 512th note FiveHundredTwelfthTriplet, ///< a 512th note triplet numTempos };
I suggest a double check of the values but it should work.
Once you have modified the two files (.cpp and .h) you will have to recompile HISE again from its source code.