FMOD.DSP lowPass; system.createDSPByType(FMOD.DSP_TYPE.LOWPASS, out lowPass); float cutoff = 5000.0f; // Hz lowPass.setParameterFloat(FMOD.DSP_LOWPASS.CUTOFF, cutoff); channel.addDSP(FMOD.CHANNELCONTROL_DSP_INDEX.HEAD, lowPass);
FMOD.DSP distortion; system.createDSPByType(FMOD.DSP_TYPE.DISTORTION, out distortion); float distortionLevel = 0.5f; // 0 to 1 distortion.setParameterFloat(FMOD.DSP_DISTORTION.LEVEL, distortionLevel); channel.addDSP(FMOD.CHANNELCONTROL_DSP_INDEX.HEAD, distortion);In this code, we create a distortion effect using `createDSPByType()` and set its distortion level using `setParameterFloat()`. We then apply this DSP effect to a channel using `addDSP()`. The FMOD DSP library is included in the FMOD Studio API package for C#.