Hi faust users! This might be a very low-level question, but I've been struggling with this for a long time now, so I hope you might be able to help me out. I'm trying to build a guitar amp simulator in pure faust which is basically using two impulse responses to set the profile
_ : fi.conv(pre_ir) : some_amp_stuff : fi.conv(post_ir) : _ In order to utilize different amp profiles I need to change pre_ir and post_ir, which are about a hundred decimal values each, at runtime. I don't want to add any additional control code for portability reasons (should run on different platforms and hardware sooner or later), and because I am not a good programmer in any language but bash and hopefully faust soon ;) Since I could not find a way to change the variables at runtime, I currently use parallel channels to achieve this, so for the convolution gets replaced by this profile_pre = _<:fi.conv(pre_ir_0)*(chan==0) ,fi.conv(pre_ir_1)*(chan==1) ,fi.conv(pre_ir_2)*(chan==2) ,fi.conv(pre_ir_3)*(chan==3) ,fi.conv(pre_ir_4)*(chan==4) ,fi.conv(pre_ir_5)*(chan==5) ,fi.conv(pre_ir_6)*(chan==6) :>_; Alternatively I tried a serial approach, bypassing the unneeded convolutions: profile_pre = ba.bypass1((chan!=0),fi.conv(pre_ir_0)):ba.bypass1((chan!=1),fi.conv(pre_ir_1)); where chan is a variable setting the selected channel, obviously. Both approaches work quite ok on my PC, but both of them seem to actually calculate at least some of the parallel/bypassed filters all the time. Because of that I get higher CPU load when using different profiles, and buffer underruns whenever I try to use it on lower-grade hardware such as Teensy or Bela, which is basically the goal of this project. Single convolution filters work fine on both. Is there a better way of doing this? Really looking forward to any hints! Best regards, Robin Rosenberger
_______________________________________________ Faudiostream-users mailing list Faudiostream-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/faudiostream-users