D12156: implement reading of rating tag
Stefan BrĂ¼ns
noreply at phabricator.kde.org
Thu Apr 19 17:56:45 UTC 2018
bruns added inline comments.
INLINE COMMENTS
> astippich wrote in taglibextractor.cpp:222-234
> The thing here is that the most common implementation don't allow half star ratings. Only Mediamonkey does it and that diverges from the rest. Also, the values are not distributed equidistantly, but I'll look into a more flexible solution.
There is a "half interval" at the bottom and the top, every other interval is 64.
rating = temp * 10 / 255 + 0.5;
should work reasonably well, or, if you prefer a smaller `0` interval:
rating = temp * 9.5 / 255 + 0.99;
REPOSITORY
R286 KFileMetaData
REVISION DETAIL
https://phabricator.kde.org/D12156
To: astippich, mgallien, michaelh
Cc: bruns, #frameworks, ashaposhnikov, michaelh, astippich, spoorun
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180419/4419df40/attachment.html>
More information about the Kde-frameworks-devel
mailing list