Acrobat ·
A small application of conditionals in the code component: Plug 2 inputs and a gate controls which input goes to the output... ...at audio rate!! 😈
http://www.blank-media.it/synthmaker/stream_selector.zip
A.
From the original SynthMaker forum (2004–2014), with its members’ names and dates.
Acrobat ·
A small application of conditionals in the code component: Plug 2 inputs and a gate controls which input goes to the output... ...at audio rate!! 😈
http://www.blank-media.it/synthmaker/stream_selector.zip
A.
sunsynth ·
hi Acrobat,
what are the pros 4 this?
Why should i use this instead of the 'normal' selector in SM?
SUNsynth
Acrobat ·
the boolean input is stream, not green integer, so it works faster, you can connect gate informations at maximum speed and choose between 2 streams in real time, for example.. or can be used in an arpeggiator to switch almost everything at audio rate..
🙂
TheAudiophileDutchman ·
Really interesting, but
"This schematic was made with a newer version of Synthmaker" - is the error I got, while trying to open the file. I'm using SM 1.1. beta 4 😕
sunsynth ·
Thanks Acrobat 4 your Info! Sounds good - will try it in my Project...
@TheAudiophileDutchman: my 'synthmaker.exe' date: 04/11/2008 12:38 works ok!
Acrobat ·
TheAudiophileDutchman wrote: Really interesting, but
"This schematic was made with a newer version of Synthmaker" - is the error I got, while trying to open the file. I'm using SM 1.1. beta 4 😕
😮 I still use 1.0.9 official version, so maybe you are discovering a beta4' bug! 😮
TheAudiophileDutchman ·
Loads just fine in SM 1.1 RC1 🙂
sunsynth ·
Hi Code-Freaks,
inspired by Acrobat's Code i changed and expanded it by 1 In/Out because i need it:
3xStream Selector:
streamin in1; streamin in2; streamin in3; streamin select; streamout out;
out = (select == 0 & in1)|(select == 1 & in2) | (select == 2 & in3);
3xStream MultiPlexer:
streamin in; streamin select; streamout out1; streamout out2; streamout out3;
float silent;
out1 = (select == 0 & in) | (select != 0 & silent); out2 = (select == 1 & in) | (select != 1 & silent); out3 = (select == 2 & in) | (select != 2 & silent);
4 any optimization i'm very thankfull!
@exo: ASM convertion needed?
Walter
exonerate ·
ASM convertion needed?
No I wouldn't bother with such small pieces of code, best to keep them as they are in case in future you what to add more inputs/outputs. You could probably only reduce the CPU by one or two cycles converting to ASM.
Anyway the multiplexer code can be reduced....
streamin in; streamin select; streamout out1; streamout out2; streamout out3;
out1 = (select == 0) & in; out2 = (select == 1) & in; out3 = (select == 2) & in;
The setting to zero is not needed because if the first comparison is false then that output will be set to zero anyway.
Cheers 😉
Exo
sunsynth ·
i KNEW IT 🙂
I like the reduce 2 the max thing 😉
Thanks exo
cheers, Walter
Klentock1 ·
I've added more channels to the selector but i'm having a problem. i can only get 6 different streams to select at the max before the selector stops outputting audio.
any ideas why this is happening?
streamin in1; streamin in2; streamin in3; streamin in4; streamin in5; streamin in6; streamin in7; streamin select; streamout out;
out = (select == 0 & in1) |(select == 1 & in2) | (select == 2 & in3) | (select == 3 & in4) | (select == 4 & in5) | (select == 5 & in6) | (select == 6 & in7);
exonerate ·
Klentock1 wrote: I've added more channels to the selector but i'm having a problem. i can only get 6 different streams to select at the max before the selector stops outputting audio.
any ideas why this is happening?
You need to break it up, because you will be running out of SSE registers...
streamin in1; streamin in2; streamin in3; streamin in4; streamin in5; streamin in6; streamin in7; streamin select; streamout out;
out = (select == 0 & in1) |(select == 1 & in2) | (select == 2 & in3) | (select == 3 & in4) out = out + (select == 4 & in5) | (select == 5 & in6) | (select == 6 & in7);
That should work.
Cheers 😉
Exo
Wrote something here? To have a post removed or your name hidden, write to [email protected].