pub fn gain_db2coef(gain_db: f32) -> f32
Expand description

Converts gain in decibels to a factor/coeffient

use synfx_dsp::gain_db2coef;

assert!((gain_db2coef(-6.0) - 0.501187).abs() < 0.00001);
assert!((gain_db2coef(-3.0) - 0.707945).abs() < 0.00001);
assert!((gain_db2coef(0.0) - 1.0).abs() < 0.00001);
assert!((gain_db2coef(6.0) - 1.99526).abs() < 0.00001);