configRoute method

void configRoute(
  1. SynthizerObject output,
  2. SynthizerObject input, {
  3. double gain = 1.0,
  4. double fadeTime = 0.01,
  5. BiquadConfig? filter,
})

Configure an fx send.

Implementation

void configRoute(
  final SynthizerObject output,
  final SynthizerObject input, {
  final double gain = 1.0,
  final double fadeTime = 0.01,
  final BiquadConfig? filter,
}) {
  synthizer
      .check(synthizer.synthizer.syz_initRouteConfig(synthizer.routeConfig));
  if (filter != null) {
    synthizer.routeConfig.ref.filter = filter.config.ref;
  }
  synthizer.routeConfig.ref
    ..gain = gain
    ..fade_time = fadeTime;
  synthizer.check(
    synthizer.synthizer.syz_routingConfigRoute(
      handle.value,
      output.handle.value,
      input.handle.value,
      synthizer.routeConfig,
    ),
  );
}