Muted autoplay videos should not show a media notification |
||||||||||
Issue descriptionMuted autoplay videos can be used as a design element, while scrolling through a stream, etc. Currently, these result in a media notification being shown, but it seems unlikely that the user would want to pause a video they weren't actively looking at. It's preferable to show the notification only for video that's audible, or *possibly* silent video that's played explicitly by the user.
,
Aug 17 2016
,
Aug 17 2016
,
Sep 22 2016
I'm starting looking into this. It will also affect MediaSession on desktop I think. Now the logic is getting complex. For desktop, there's no autoplay restriction, so checking user gesture does not help, and we don't want a muted video join MediaSession. Maybe we should pass the muted flag in _DidPlay message, and fire another message for _Unmute? (seems not very clean) Any idea Mounir?
,
Oct 4 2016
Finally got around to clean up the fix I had: https://codereview.chromium.org/2251073003
,
Oct 7 2016
,
Oct 31 2016
Issue 660482 has been merged into this issue.
,
Nov 4 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/910111369092ad1c3432833491eae73b87a6c33d commit 910111369092ad1c3432833491eae73b87a6c33d Author: mlamouri <mlamouri@chromium.org> Date: Fri Nov 04 11:28:24 2016 Pretend the video has no audio track if it is playing as part of autoplay muted. This is to prevent autoplay muted videos to behave as audible videos because they might never be audible as far as the user is concerned. These will avoid taking an audio power blocker for them and also prevent showing a media notification. BUG= 638463 R=sandersd@chromium.org,foolip@chromium.org,zqzhang@chromium.org Review-Url: https://codereview.chromium.org/2251073003 Cr-Commit-Position: refs/heads/master@{#429859} [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/chrome/android/java_sources.gni [add] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/chrome/android/javatests/src/org/chromium/chrome/browser/media/ui/AutoplayMutedNotificationTest.java [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/content/renderer/media/webmediaplayer_ms_unittest.cc [add] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/content/test/data/media/session/autoplay-muted.html [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/media/blink/webmediaplayer_impl.cc [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/media/blink/webmediaplayer_impl.h [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/media/blink/webmediaplayer_impl_unittest.cc [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/third_party/WebKit/LayoutTests/media/autoplay-muted.html [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/third_party/WebKit/Source/core/html/HTMLMediaElement.h [modify] https://crrev.com/910111369092ad1c3432833491eae73b87a6c33d/third_party/WebKit/public/platform/WebMediaPlayerClient.h
,
Nov 4 2016
Requesting M55 merge because it is solving a complaints that we've heard many times from developers and users.
,
Nov 4 2016
Yes please, it's very annoying, not just for the notification but because it steals audio focus so in M54 it's almost impossible to surf the web while listening to say Spotify.
,
Nov 4 2016
Your change meets the bar and is auto-approved for M55 (branch: 2883)
,
Nov 4 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9 commit f2f93aa0a8ae4539e6d1499e7f0497c8925504d9 Author: Mounir Lamouri <mlamouri@chromium.org> Date: Fri Nov 04 13:41:23 2016 Pretend the video has no audio track if it is playing as part of autoplay muted. This is to prevent autoplay muted videos to behave as audible videos because they might never be audible as far as the user is concerned. These will avoid taking an audio power blocker for them and also prevent showing a media notification. BUG= 638463 R=sandersd@chromium.org,foolip@chromium.org,zqzhang@chromium.org Review-Url: https://codereview.chromium.org/2251073003 Cr-Commit-Position: refs/heads/master@{#429859} (cherry picked from commit 910111369092ad1c3432833491eae73b87a6c33d) Review URL: https://codereview.chromium.org/2471373005 . Cr-Commit-Position: refs/branch-heads/2883@{#450} Cr-Branched-From: 614d31daee2f61b0180df403a8ad43f20b9f6dd7-refs/heads/master@{#423768} [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/chrome/android/java_sources.gni [add] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/chrome/android/javatests/src/org/chromium/chrome/browser/media/ui/AutoplayMutedNotificationTest.java [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/content/renderer/media/webmediaplayer_ms_unittest.cc [add] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/content/test/data/media/session/autoplay-muted.html [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/media/blink/webmediaplayer_impl.cc [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/media/blink/webmediaplayer_impl.h [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/media/blink/webmediaplayer_impl_unittest.cc [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/third_party/WebKit/LayoutTests/media/autoplay-muted.html [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/third_party/WebKit/Source/core/html/HTMLMediaElement.h [modify] https://crrev.com/f2f93aa0a8ae4539e6d1499e7f0497c8925504d9/third_party/WebKit/public/platform/WebMediaPlayerClient.h
,
Nov 4 2016
,
Nov 5 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/949c8b5ab4c5ea959f13aebe9ef5eb6982da01a6 commit 949c8b5ab4c5ea959f13aebe9ef5eb6982da01a6 Author: John Budorick <jbudorick@chromium.org> Date: Sat Nov 05 01:23:36 2016 [M55] Fix EmbeddedTestServer use. createAndStartServer was added in M56. BUG= 638463 TBR=mlamouri@chromium.org Review URL: https://codereview.chromium.org/2478703005 . Cr-Commit-Position: refs/branch-heads/2883@{#469} Cr-Branched-From: 614d31daee2f61b0180df403a8ad43f20b9f6dd7-refs/heads/master@{#423768} [modify] https://crrev.com/949c8b5ab4c5ea959f13aebe9ef5eb6982da01a6/chrome/android/javatests/src/org/chromium/chrome/browser/media/ui/AutoplayMutedNotificationTest.java
,
Nov 9 2016
Verified in 55.0.2883.45 with mutes video-http://tinyurl.com/grukg24
,
Jul 30
This issue still happen. The media notification is shown, and Android shifts the sound from other apps (Spotify/SoundCloud/etc.) to the browser, even if the video is muted.
,
Jul 30
Which version of Chrome are you using? There was a regression in Chrome 67 that was fixed in Chrome 69.
,
Jul 31
67, will update once I check on 69.
,
Jul 31
I confirmed it works as expected on Chrome Canary 70. Thanks for your response. |
||||||||||
►
Sign in to add a comment |
||||||||||
Comment 1 by mlamouri@chromium.org
, Aug 17 2016Components: Internals>Media>Session Blink>Media
Labels: M-54
Status: Assigned (was: Available)