Corrected a math mistake in obs_source.c calc_volume_levels.
This commit is contained in:
parent
e03f34de9f
commit
336c3821fc
@ -565,8 +565,8 @@ static void calc_volume_levels(struct obs_source *source, float *array,
|
||||
max_val = fmaxf(max_val, val_pow2);
|
||||
}
|
||||
|
||||
rms_val = to_db(sqrtf(sum_val / (float)count * volume));
|
||||
max_val = to_db(sqrtf(max_val * volume));
|
||||
rms_val = to_db(sqrtf(sum_val / (float)count) * volume);
|
||||
max_val = to_db(sqrtf(max_val) * volume);
|
||||
|
||||
if (max_val > source->vol_max)
|
||||
source->vol_max = max_val;
|
||||
|
Loading…
x
Reference in New Issue
Block a user