1
0
Fork 0

Default both offsets to 0 dB again

Otherwise the UI just looks weird.
This commit is contained in:
Robbert van der Helm 2022-07-24 19:01:28 +02:00
parent 692b1051ad
commit 6b26828839

View file

@ -273,13 +273,7 @@ impl CompressorParams {
// As explained above, these offsets are relative to the target curve // As explained above, these offsets are relative to the target curve
threshold_offset_db: FloatParam::new( threshold_offset_db: FloatParam::new(
format!("{name_prefix} Offset"), format!("{name_prefix} Offset"),
// TODO: Bit of a hacky way to set the default values differently for upwards and 0.0,
// downwards compressors
if param_id_prefix == UPWARDS_NAME_PREFIX {
-20.0
} else {
0.0
},
FloatRange::Linear { FloatRange::Linear {
min: -50.0, min: -50.0,
max: 50.0, max: 50.0,
@ -303,6 +297,8 @@ impl CompressorParams {
.with_string_to_value(formatters::s2v_compression_ratio()), .with_string_to_value(formatters::s2v_compression_ratio()),
high_freq_ratio_rolloff: FloatParam::new( high_freq_ratio_rolloff: FloatParam::new(
format!("{name_prefix} Hi-Freq Rolloff"), format!("{name_prefix} Hi-Freq Rolloff"),
// TODO: Bit of a hacky way to set the default values differently for upwards and
// downwards compressors
if param_id_prefix == UPWARDS_NAME_PREFIX { if param_id_prefix == UPWARDS_NAME_PREFIX {
0.75 0.75
} else { } else {