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

PulseAudio volume customized #620

Closed
matthewarmand opened this issue Aug 28, 2019 · 8 comments
Closed

PulseAudio volume customized #620

matthewarmand opened this issue Aug 28, 2019 · 8 comments

Comments

@matthewarmand
Copy link

@matthewarmand matthewarmand commented Aug 28, 2019

Description

When using tizonia on a system with PulseAudio, the output volume of the application in Pulse seems fixed at 75% every time the program starts, regardless of the setting changing at previous runs. Would it be possible to have this setting be remembered once its changed on a previous run, or maybe be configurable? (Or just default to 100% instead of 75%, which would be my setting)

Steps to Reproduce

  1. Run tizonia on a system with PulseAudio
  2. Observe the application volume setting (either in the system tray or with pavucontrol or similar)
  3. Quit tizonia
  4. Run tizonia again and observe the application volume setting again

Expected behavior: The setting is persisted from one run to the next (alternatively, the default application volume is 100%)

Actual behaviour: The setting is 75% for each new run

Reproduces how often: 100% of the time

Versions

# tizonia --version
tizonia 0.18.0. Copyright (C) 2019 Juan A. Rubio
This software is part of the Tizonia project <http://tizonia.org>

# pulseaudio --version
pulseaudio 12.2

# snap --version
snap    2.40-1
snapd   2.40-1
series  16
arch    -
kernel  5.2.9-arch1-1-ARCH

# cat /etc/os-release
NAME="Arch Linux"
PRETTY_NAME="Arch Linux"
ID=arch
BUILD_ID=rolling
ANSI_COLOR="0;36"
HOME_URL="https://www.archlinux.org/"
DOCUMENTATION_URL="https://wiki.archlinux.org/"
SUPPORT_URL="https://bbs.archlinux.org/"
BUG_REPORT_URL="https://bugs.archlinux.org/"
LOGO=archlinux

Installation Method Used

I'm currently using the snap package, although I believe I saw the same behavior with the AUR package (and it seems like a core functionality issue, so I'd imagine probably affects all installation methods)

@tizonia

This comment has been minimized.

Copy link
Owner

@tizonia tizonia commented Sep 1, 2019

Hi!, thanks for taking the time to report issues and provide feedback. This is always welcome.

I think your analysis is correct for the most part. Adding a config file option to set a default volume would be easy (and useful). I think this could be implemented quite quickly.

If anyone wants to help, I could provide some easy-to-folow instructions. Otherwise, I'll implement it when I have some time

@matthewarmand

This comment has been minimized.

Copy link
Author

@matthewarmand matthewarmand commented Sep 12, 2019

@tizonia if no one else picks this up before then, I'll probably have some time to work on this after next week if you want to document some instructions here

@matthewarmand

This comment has been minimized.

Copy link
Author

@matthewarmand matthewarmand commented Oct 4, 2019

@tizonia feel free to document whatever instructions you feel are necessary here and I'll take a crack at it

juanrubio added a commit that referenced this issue Dec 12, 2019
@tizonia

This comment has been minimized.

Copy link
Owner

@tizonia tizonia commented Dec 12, 2019

@matthewarmand

I have to apologize. I was meaning to look at the implementation of this and then provide the details here for you to pick up, but I thought it was more work to detail it than to do it.

Please have a look at this commit:
a10d8e2

Basically, this adds support for this configuration option:

# PulseAudio Audio Renderer
# -------------------------------------------------------------------------
#
# OMX.Aratelia.audio_renderer.pulseaudio.pcm.default_volume = Value from 0
#                                                             to 100 (Default: 75)

The specified volume there will be honoured when the application is started.

It is in the develop, branch. I'm planning to cut a new release in the next few days.

@matthewarmand

This comment has been minimized.

Copy link
Author

@matthewarmand matthewarmand commented Dec 12, 2019

No worries at all @tizonia , just glad it hit the roadmap. Thanks for the reference to the commit for context.

The specified volume there will be honoured when the application is started.

One thing I've noticed is when skipping through a playlist/album using p or n, the volume resets to 75% even if its previously been adjusted. Will this fix apply to that case as well? Basically, is set_initial_component_volume called through that codepath as well or is that effect due to something else?

Thanks again for the enhancement, very much looking forward to it

@tizonia

This comment has been minimized.

Copy link
Owner

@tizonia tizonia commented Dec 12, 2019

Wow!, You're absolutely right. The volume was getting reset to its intial value. This commit fixes that:
51a0984

Thank you for your prompt reply!

@matthewarmand

This comment has been minimized.

Copy link
Author

@matthewarmand matthewarmand commented Dec 13, 2019

Excellent, thanks so much! No worries at all. I use tizonia every day to listen to music at work and am looking forward to this feature getting into a release.

I'll probably leave the Issue open until a release, or you can feel free to close whenever.

Thanks again!

@tizonia

This comment has been minimized.

Copy link
Owner

@tizonia tizonia commented Dec 13, 2019

Closing this issue for now. The code is now in the master branch, to be released soon.

@tizonia tizonia closed this Dec 13, 2019
@tizonia tizonia changed the title PulseAudio volume remembered/customized PulseAudio volume customized Dec 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.