Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement volume thresholds #4

Open
ashthespy opened this issue Mar 6, 2020 · 3 comments
Open

Implement volume thresholds #4

ashthespy opened this issue Mar 6, 2020 · 3 comments
Labels
enhancement New feature or request

Comments

@ashthespy
Copy link
Owner

Cross ref: volumio/volumio-plugins#420

There's isn't any threshold on the volume implement for the mixer, so this makes it currently not possible to respect Volumio's volumemax option.

@ashthespy ashthespy added the enhancement New feature or request label Mar 6, 2020
@ashthespy
Copy link
Owner Author

@Rick-T A question -
How should this threshold be maped to 0 -100% range of the client?
Should be a linear map - i.e if you set volumemax=40 as your threshold, then Client 50% = Alsa 20%? Or should it follow the cubic mapping of alsamixer?
Or should it just be a simple hard threshold? Client 50% = Alsa 40%

@Rick-T
Copy link

Rick-T commented Mar 7, 2020

@ashthespy
Thank you asking, but I'm afraid I don't really know what the best solution would be as I don't know about the internal workings of alsa, volumio and your plugin.

Here's my thoughts anyways:

I think a hard limit would be weird. I think it would be more intuitive to have 100% in the client be max volume in alsa.
I also think that the mapping between client volume and alsa volume should respect the settings from volumio, if possible. Afaik there's an option somewhere that lets you switch between linear and logarithmic volume control.

So to pick up your example, max volume at 40 and client volume at 50% would mean "volumio volume" at 20 and then the setting decides if the 20 is interpreted on a linear scale or a logarithmic one. Would that be possible?

@ashthespy
Copy link
Owner Author

I think a hard limit would be weird. I think it would be more intuitive to have 100% in the client be max volume in alsa.

This is where the confusion crept in - As I understand the volume control code, Volumio seems to just set a hard limit. Probably a good idea to check on what the "Audiophile" consensus in on this..

So to pick up your example, max volume at 40 and client volume at 50% would mean "volumio volume" at 20 and then the setting decides if the 20 is interpreted on a linear scale or a logarithmic one. Would that be possible?

Yes - this is how I would like to do it as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants