I’ve read all the documentation on attaching aux effects to AudioTrack but can’t understand how I can attach more than one effect.
Attaching an effect seems simple enough.
But how does the setAuxEffectSendLevel
know which effect to apply the level to as there is no parameter identifying the related effect?
Does it simply refer to the last added effect?
Also how can one of the effects be detached. In my code below, by attaching a null effect, which of my effects would be removed?
PresetReverb reverb = new PresetReverb(1, 0);
reverb.setPreset(PresetReverb.PRESET_LARGEHALL);
reverb.setEnabled(true);
audioTrack.attachAuxEffect(reverb.getId());
audioTrack.setAuxEffectSendLevel(1.0f);
BassBoost bb = new BassBoost(0, 0);
bb.setStrength(1000);
bb.setEnabled(true);
audioTrack.attachAuxEffect(bb.Id);
audioTrack.setAuxEffectSendLevel(1.0f);
//this code detaches which effect?
audioTrack.AttachAuxEffect(0);