If you have a problem or need to report a bug please email : support@dsprobotics.com
There are 3 sections to this support area:
DOWNLOADS: access to product manuals, support files and drivers
HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects
USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here
NEW REGISTRATIONS - please contact us if you wish to register on the forum
Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright
Mix
10 posts
• Page 1 of 1
Re: Mix
hello mit2
not sure what you want -
a switch: would be your described if else scenario
a crossfade: fades from A to B mixing the signals
here are the 2 modules (for stream as code)
not sure what you want -
a switch: would be your described if else scenario
a crossfade: fades from A to B mixing the signals
here are the 2 modules (for stream as code)
- Attachments
-
- crossfade_n_switch.fsm
- (1.42 KiB) Downloaded 835 times
-
Nubeat7 - Posts: 1347
- Joined: Sat Apr 14, 2012 9:59 am
- Location: Vienna
Re: Mix
you mean
if mix == 0 then dry input
if mix > 0 then wet *mix
would be like this then
you just need to change 'b' to '(b*mix)' in the switch module
btw are you sure you didn`t confuse > (greater then) and < (less then)
also where is the double stream?
if this doesn`t help,you better post a schematic..
if mix == 0 then dry input
if mix > 0 then wet *mix
would be like this then
- Code: Select all
streamin a; //dry in
streamin b; //wet in
streamin mix;
streamout out;
out = (a&(mix<=0))|((b*mix)&(mix>0));
you just need to change 'b' to '(b*mix)' in the switch module
btw are you sure you didn`t confuse > (greater then) and < (less then)
also where is the double stream?
if this doesn`t help,you better post a schematic..
-
Nubeat7 - Posts: 1347
- Joined: Sat Apr 14, 2012 9:59 am
- Location: Vienna
Re: Mix
- Code: Select all
streamin dry;
streamin wet;
streamout out;
streamin mix;
out=wet*mix+dry*(1-mix);
- KG_is_back
- Posts: 1196
- Joined: Tue Oct 22, 2013 5:43 pm
- Location: Slovakia
Re: Mix
KG_is_back wrote:
- Code: Select all
streamin dry;
streamin wet;
streamout out;
streamin mix;
out=wet*mix+dry*(1-mix);
this is also a crossfade...
i just use this instead:
- Code: Select all
out = a - (a - b) * fade;
because of less multiplication - it should be with better performance if i`m right and it has no extra float value for 1, but KG`s is easier to understand?
so you want:
if mix == 0 then dry input
and if mix < 0 (less then zero) it mixes the wet signal(with the filters) without input signal
so 0..-1 should mix the wet signal?
then just xchange the > and < signs in the code above
- Code: Select all
streamin a;
streamin b;
streamin mix;
streamout out;
out = (a&(mix==0))|((b*mix)&(mix<0));
note that the mix signal then needs to be 0..-1 and not like you wrote before 0..1
if mix range would be 0..1 in your scenario:
mit2 wrote:i want doit this if mix = 0
http://i61.tinypic.com/286toa8.jpg
and if mix < 0
http://i62.tinypic.com/1zovvde.jpg
this is schematic how has a look
it never can get the second signalway because mix is never < 0
-
Nubeat7 - Posts: 1347
- Joined: Sat Apr 14, 2012 9:59 am
- Location: Vienna
10 posts
• Page 1 of 1
Who is online
Users browsing this forum: Google [Bot] and 79 guests