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

Playing sounds dampens music from other app #462

Closed
pizzapim opened this issue Jan 2, 2021 · 2 comments
Closed

Playing sounds dampens music from other app #462

pizzapim opened this issue Jan 2, 2021 · 2 comments
Labels
always-fresh Issues that will never become stale enhancement New feature or request priority/low

Comments

@pizzapim
Copy link

pizzapim commented Jan 2, 2021

Describe the bug

I wanted to have music playing and sounds from the Noice app simultaneously, but it dampens the music of the other app. It only happens the first time I play a sound. If I stop and then restart the sound, the music is not dampened.

To Reproduce

Steps to reproduce the behavior:

  1. Play some music from another app (Spotify in this case)
  2. Stop and start the Noice app
  3. Press a sound to make it play
  4. The music in the background is now dampened
  5. Stop and start the sound again
  6. The music in the background is not dampened this time

Expected behavior

I expect the music in the background to continue playing at the same volume at all times.

Others

  • Device: Motorola Moto 5
  • Android Version: 8.1.0
  • App version: F-Droid 0.14.0
@pizzapim pizzapim added the bug Something isn't working label Jan 2, 2021
@ashutoshgngwr ashutoshgngwr added always-fresh Issues that will never become stale priority/medium labels Jan 4, 2021
@ashutoshgngwr
Copy link
Member

ashutoshgngwr commented Jan 4, 2021

I am able to reproduce the issue. I'll investigate it further.

ashutoshgngwr added a commit that referenced this issue Jan 31, 2021
connects to #462

It resolves the underlying bug referenced in the issue
although the requirements for the linked issue differ.
@ashutoshgngwr ashutoshgngwr added enhancement New feature or request priority/low and removed bug Something isn't working priority/medium labels Jan 31, 2021
@ashutoshgngwr
Copy link
Member

I have fixed the underlying bug, and it doesn't satisfy your specific requests. The dampening of sound is the expected behaviour. Noice requests partial audio focus before playing any media. The Android framework dampens the sound of the other player to comply with this request. The issue was that once Noice abandoned the audio focus, it wasn't re-requesting it again. Hence, the other music player was not dampening the second time. I've addressed this issue.

As for your concern, it is an enhancement to the project at this stage. In future, we can give users the ability to disable audio focus management. The Android framework doesn't complain when an app plays media without requesting the audio focus, but it isn't the right way of doing things.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
always-fresh Issues that will never become stale enhancement New feature or request priority/low
Projects
None yet
Development

No branches or pull requests

2 participants