Intent to implement: per-tab audio focus (Android)

155 views
Skip to first unread message

Mounir Lamouri

unread,
May 12, 2015, 4:12:21 PM5/12/15
to Chromium-dev, ava...@chromium.org, da...@opera.com, phi...@opera.com, ri...@opera.com
== Contact emails ==
Anton Vayvod <ava...@chromium.org>
David Vest <da...@opera.com>
Mounir Lamouri <mlam...@chromium.org>
Philip Jägenstedt <phi...@opera.com>
Rich Tibbett <ri...@opera.com>

== Summary ==
This change is Android specific.

Chromium is currently getting ducking audio focus for each playing media
source to allow multiple media being played at the same time. As a
consequence, media being played in Chromium is played over other
applications and also over other tabs. The very basic flow of having a
music player whether native or web-based to automatically pause when
starting a video/audio in a Chromium-based browser is broken while it is
working fine between native applications.

In order to fix that, we would like to have each tab grabbing its own
exclusive audio focus. That means that all media sources in a tab will
not pause each other but a tab playing media will pause another tab or
application. The same way a native application grabbing audio focus will
pause other applications. Short media (e.g. shorter than 5 seconds)
would grab transient audio focus allowing any other media to be resumed
automatically.

This is the first step of many changes. The next step will be to show
proper media controls in the lockscreen/notification bar for media
played by Chromium (see https://crbug.com/470600). Then we would like to
expose the behaviour to web applications and allow them to control it,
as described in this work in progress specification:
https://mediasession.spec.whatwg.org/.

A high level overview of the project (including next steps) can be found
here: https://goo.gl/wm0KSm

Tracking bug: https://crbug.com/486878
Implementation: https://codereview.chromium.org/1110833004

-- Mounir

Mounir Lamouri

unread,
Jun 1, 2015, 12:06:46 PM6/1/15
to Chromium-dev, ava...@chromium.org, da...@opera.com, phi...@opera.com, ri...@opera.com
FYI, the change has landed last week.

-- Mounir
> --
> --
> Chromium Developers mailing list: chromi...@chromium.org
> View archives, change email options, or unsubscribe:
> http://groups.google.com/a/chromium.org/group/chromium-dev
>
> To unsubscribe from this group and stop receiving emails from it, send an
> email to chromium-dev...@chromium.org.
Reply all
Reply to author
Forward
0 new messages