Sinono3 / souvlaki

A cross-platform library for handling OS media controls and metadata.
MIT License
80 stars 15 forks source link

[docs] `SetVolume` says values will be 0.0 to 1.0, but can actually be more #47

Closed hasezoey closed 9 months ago

hasezoey commented 9 months ago

I have just tried implementing this, and noticed that the documentation says: https://github.com/Sinono3/souvlaki/blob/fc88dfb91b10540aaab390e6af52375d295370a8/src/lib.rs#L45-L46 but actually souvlaki does not clamp the value and the inputted value can be anything above 0, as per the mpris documentation:

Note that the volume may be higher than 1.0, although generally clients should not attempt to set it above 1.0.

source

example: playerctl volume 100 will give float 100.0

Sinono3 commented 9 months ago

During the design I originally intended the user to handle the different cases, but that wasn't included in the documentation. Docs added in 0.7.3 (6abc535). Thanks for reporting this.