AudioLoop Player/Granulator File Handling
-
hey all, so i have a granulator in a scriptfx module and an audio loop player in my project. i would like the file dropped into the audio loop player to also populate in the granulator. this code makes sense in my head but its not working. can anyone tell what im doing wrong?
const var synth = Synth.getAudioSampleProcessor("Script FX2"); const var AudioWaveform1 = Content.getComponent("AudioWaveform1"); const var AudioLoopPlayer1 = Synth.getAudioSampleProcessor("Audio Loop Player1"); inline function onAudioWaveform1Control(component, value) { AudioLoopPlayer1.getAudioFile(0); synth.setFile(AudioLoopPlayer1.getAudioFile(0)); }; Content.getComponent("AudioWaveform1").setControlCallback(onAudioWaveform1Control);
-
@Adam_G Actually you can use a broadcaster.
HiseSnippet 1769.3oc6X0saaTDEd13rIMtEDEJRb4JKtvUJ3eJkBhJTc9wIXQbhUV2.HTUzjcGaOJ6NyxriSrA0G.tCIdA3wgK4QfK3Af2.3Lyrq20INoIglTToNRQ672Y9Nm4b9NmY5H3dj3Xt.YsT2wQDj0crcGyjCVa.lxPsVGY811swwRhvwz0piivwwDejkUgMUcXsz7H8u+5IqhCvLORVWHzdbpGYKZHUl0amFeEMHXCrOoKML2reXiVdb1Z7.9P.OErqghvdGh6S1Fql1b1HqEZ5SkbgqDKIwHq4Wk6O1c.+XlY96QioGDPTMpibAAY5dCdfuBwpuQqMfF32IUuiQfP6jYEJXrB2ytM0mNo+Lqw6nGvIaE4sGVyMM7JLE7peVvaFPxJGjrMP5t1tdBZjLaDEdtscKFb3zCCl87PY6ggqLzmx2fFnPhskEXfMB.MWgB1qwgkwjUBwGR1P.MlHlxOpVskcf+c+GWDlULOfTwKffEkgNJBGPwRmivBGs32hyi5DfGSD0cVZouvQ66ToOQpG0EGFEPl.3xkz85nVjSxpJABMSlF.x39DkfHwzXkfeghMaYN4VWoow6AdffZx5SYf9HHvIzpBN12S6bW9GKtTIpeoO2ozZbkzG4rNVhc1hBixHhRKCiiE8igY7ckZy8GFPJsrSIeXRsX9jQpFGgCFRJ8rhOWswEOvqBVJwdC5xSDoRhI1.0wRkjy.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6GmKS5JAA7iUOxAMIB.rO595vCFmxeYMmYFondkP3VQxTn+k33tXZfZZtCii.rsCyElrNIrUg8fKhoE7h10p.+AgPaqIrr2.6AF7wcvpG53t1p2wBN2HhJd4HVNCbO0KKCCllv1X8.3FpeyF0KzWH2C8XnzTsfC+4T6vcraEumZTOb.ZOyaXApkRlF6nAqlol8blnSAdAoRtgup3Ck6kYUaetJOx2B7O0uAZp.aB0a3CNh5kk3XzlxRzGybZiGk0V8hXcvB35xRRRgCosfuyVZFyW1xyBZbkjHW5OL07bOjbrw3LUNNv9UztCGB6TNCmR5nye6+imb5sG03Bs8+5uT6O0a+hF1dzozhWvd+vFmdu+oFWNU+11aJ.eZ8BNgn51.c8a5UOoogx6xZ4eYr62x1MRPv9uh170IxgLx4s4p.uU47CCwZ1yqzaEeiv0Gh8D788LWyPE1dKcO.IBS+xWKY2V01YxywaqHcQgPc9664oJh3ipiPydMO3JrlO9JrlGdEVymbEVyitBq4SuBq4yN20nth0JCk7PS5UniNMMrzVSdETqBn+A7TXDkA
-
thank you @ustk ! broadcasters are so cool, i havent had much experience with them yet (none actually). can it be used the same way if the granulator is in a Script FX module?
-
@Adam_G
my example is using a script FX module;)EDIT: Nope sorry it's in a Scriptnode Synth, but it should work the same way with a script FX, the essential thing being adding an "External AudioFile Slot" to the node
-
@ustk im struggling to figure it out :( im trying this but it keeps sayin "Script FX1 not found"
const var ScriptFX1 = Synth.getEffect("Script FX1"); const audio = Engine.createAndRegisterAudioFile(0); const var synth = Synth.getAudioSampleProcessor("Script FX1"); const slot = ScriptFX1.getAudioFile(0);
-
@Adam_G so do you have "ScriptFX 1" in your list of processors?
-
@Lindon I do indeed
-
@Adam_G Please show a screenshot of your module tree including the effect
-
@d-healey its definitely odd
-
can you even do this?
const var synth = Synth.getAudioSampleProcessor("Script FX1");
..and why would you?
-
@Lindon im attempting to figure out how to pass a wav thats loaded into audio loop player into a script fx granulator
and no..
-
@Adam_G as I understand it, if the "Script FX1" is indeed an "Effect module", you can't reference to it as "AudioSampleProcessor", or maybe I'm wrong.synth = Synth.getAudioSampleProcessor("Script FX1");
I think you have to have the Granulator in a "Scriptnode Synthesizer", there you reference to it as AudioSampleProcessor, and useScriptnodeSynthesizer.setFile(String fileName)
-
@ulrik ah so is there no way pass an audio file loaded into an audio loop player slot into the script fx granulator as well? im attempting to use the granulator as an effect on the loop player.
-
@Adam_G I don't know how to do it, I guess it's possible but in another way?
-
@Adam_G Sorry, I was completely wrong, I tried and without the Granulator inside it was not possible as you can see
but as soon as I added the granulator in the ScriptFX, it showed up :)
so you can indeed reference to the ScriptFX like this
const var ScriptFX1 = Synth.getAudioSampleProcessor("Script FX1");
-
If I remember correctly you need to set your granulator to use an external slot.
-
found scriptfx1 @d-healey problem now is im getting function not found for
const slot = ScriptFX1.getAudioFile(0);
-
No problem here
HiseSnippet 1131.3ocwW0saaaCElxNLo1saXEXO.B8JWfr.6sr1ALLTmXG2YrYGgprfdW.CEcLgoHEnnRh2vte658BrGscwd.1av1ghxVx0AdIFsaN.Ah77224vy2gRAZEkklpzHuFmMOgg7dBNbtzLs2TBWhF1G48w3QjTCS661534IjzTVDxyq9qsa30XGT9u+5UGSDDIkUtEBcthSYeOOlaJ2Mn62wEhAjH1Y73JZeX2gTkrmRnx.7TG2FkPnyHWwFSrpUCi718jHtQoCMDCKEz4XUz7vopajN8OmmxuTvrK5fBAG41F0aJWDErHWSQHucBJy75tL+Swi3Q7k6WVA9jbA9kVTsF3UaSPpyC.RdUfzNNH8TbHUySLkRr34w3gR3.YBAJ0UghSWTs88v8TfFRyAwjYrAZXwRKZ8h1s22G92y+5lMgxcpw+Zh12Y6f21w+a7ya.N3Jl4nrHtJjDmHXKQPqm4T0Gz8YfObtHUnLVKW3kkVOfKXsfXMISRMbkzWIGqLrSksddyepYil+bS+2UzjI2oLaJoUBASemhssR5MYXKYV7kL89P5JxXKUDp0qd.t686.j5pvUTTIGJ4lSSXEqGnDQ1CF6yqebiJNhfm9gg8IFhsCnXOPuDl1vsvwqO6ZfB45GZf6yRmYTI.IZslEnMUEkIHlU6csjzBAP8XkFFaSgLkalWkD+.ZnauwF56KDeJNfanSuaLV6NvHTo9Pfwhw.eD9jISXTSI.2AO3saKmu88myicwuIdAKJO3OAWx2VADiyhWxv.Lf87fzoXDf2ufKY.IZVBQyNSEHHyaklSmeC.788uTnnyB4+HacZShCWGa0nEcJQJYhzsgcs66owin2nxLb4UiHFM+VHeg7ODtnfx5UfNaMnlkX4V21t11rDxjQ4K9a3WgvNKKXfvNKDVgSNlYtQomkeFU7LxaO2ARZdQ9hI21AcjPntomJNgWz5BGL46EnDySlpjbpcKmFKP5QwpLHHEv8aIomQ3BaudXVJL8H5TYHnb9Eod0OmoSyc7d31G.+A89iUQfH7.BEJryCHloVRjcfDzwxzGPW14tBVWo4AbwhKZcUI.hw1TO+Z15Ul.4ZRsq.JXMmWGldtUJkHPmaOusfGY8oqd4vmS0qzDoiwiVCvZ1AUDus3yJBZoucwPzJrhpq.d7PYD61EN7DneMBFPmaVQCvHtrHeb5Lhb6JqQADM7tHvUoVeu6xUvyklVNlpz7xwqgFVhkxUUuvYrabEmpZZqeMwAJX3msAXMui1b3+iWsd3QcuWg+2+s1+Yd32yMZFsVV7uD6C6tdr+0tOrT+w3Wqg93bCdGWcVWzG9Ru8tV2EOOzJ+6in+HbHL2lD8+Tv6yLYR1lBtk3crRMKljOkb6dIl+KloGSnZ0ET20TVZ6ix2AFhHy+rhFv22.q86fttfpaGzhhgW4+BJ0d6+mAu+1caymuE17EagMGtE17kagMuXKr4kagMe0Fsw90VGkYTwtqTgMBNwMk16DIAdag7qHP+CvHM0ca
-
@Adam_G What's wrong with my first example if you replace the Scriptnode Synth with a ScriptFX like I suggested?
HiseSnippet 1758.3oc2X8taaTDDeu3bsMtEDEJR7wSV7AWofcLTJHpppyeKVMNwJmanHTUzl6Vauxm28zdqShA0uCeEdA3QhGADhG.dCfY10muyMtoNt+AolJU4c1Ym82L6N+lYuVJY.KIQpHNqzdTLi3bCW+QB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