Bug 361604

Summary: Volume (keyframeable) not migrated correctly from previous version to current release candidate 16.03.90
Product: [Applications] kdenlive Reporter: chris
Component: User InterfaceAssignee: Vincent PINON <vpinon>
Status: RESOLVED FIXED    
Severity: normal CC: chris, simonandric5
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Use log10 rather than natural logarithm to convert from levels to db

Description chris 2016-04-10 18:18:25 UTC
I have migrated a project created with 0.9.10 to the latest release candidate 16.03.90 (latest Ubuntu PPA) with the "Volume (keyframeable)" effect and noted some strange/incorrect behavior:

1. Whenever the clip was faded out to 0 in version 0.9.10 document version 0.88, this was obviously migrated to -60 db in the new version document version 0.94. However, in the Project Monitor and Rendering outputs, this was not silent, but quite loud.

2. The mix between background music and foreground was not correct any more. Background music which was at levels 10 - 30 in the old version were almost not hearable any more in the new version (converted to too low volume levels).

Reproducible: Always
Comment 1 chris 2016-04-11 20:03:46 UTC
I think I have probably found the bug. On line 1485 in documentvalidator.cpp, is says:
v = log(v) * 20;
This calculates the natural logarithm, not decimal logarithm.

This should probably be:
v = log10(v) * 20;
Comment 2 chris 2016-04-11 20:18:28 UTC
Created attachment 98345 [details]
Use log10 rather than natural logarithm to convert from levels to db

I understand that to convert from levels to db, log10 shall be used, not natural logarithm. Please use some care before applying as I wasn't able to test this due to the lack of a build environment.
Comment 3 chris 2016-04-14 02:54:52 UTC
Fixed in commit 693cc9a1a356e324b25fb993e892393ccec36797