Background Sounds on Android Chrome

Q&A about the latest versions
Post Reply
cbsmail
Posts: 22
Joined: Fri Nov 10, 2017 4:38 pm

Mon Dec 11, 2017 12:46 am

Hi,

Having issues getting a background sound to play on Chrome on my Android devices, I've tried two devices, I've even wiped the cache partition on one but still no dice. Sound plays fine in Firefox on both devices, seems to be an issue only visible with Chrome, is there a workaround? I've tried the
externalize file'/'copy file' options. but no change.

Cheers
Chris
cbsmail
Posts: 22
Joined: Fri Nov 10, 2017 4:38 pm

Mon Dec 11, 2017 4:50 am

So after a bit of researching & testing, turns out Google have done a similar thing as IOS did by disabling autoplay in Chrome.

It works as intended if you change the default behaviour for autoplay in Chrome (chrome://flags) but this is obviously not a real solution. Wondering if the devs could please implement the same solution they did for IOS, whereby a touch on the screen triggers the audio? Thanks!

Cheers
Chris

edit: And bad news on the way, autoplay will be prevented by default on Chrome from Jan 18, even desktop Chrome from what I can tell. https://developers.google.com/web/updat ... cy-changes
User avatar
Hopki
Gnome
Posts: 11134
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Mon Dec 11, 2017 5:36 pm

Hi Chris,
Apple has already done this with Safari on the desktop. :(
However you can right button click in the address bar, select Settings For This Website, then under Auto Play set as required.
Hopki
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
User avatar
360Texas
Moderator
Posts: 3516
Joined: Sat Sep 09, 2006 6:06 pm
Location: Fort Worth, Texas USA
Contact:

Mon Dec 11, 2017 6:47 pm

PC Chrome Autoplay found here: chrome://flags

Drop down menu shows 4 options:

Default
no user gesture required
user gesture is required for cross-origin iframe
document user activation is required

chormeautoplay.JPG
chormeautoplay.JPG (67.99 KiB) Viewed 1353 times
Dave
Pano2VR Forum Global Moderator
Image
Visit 360texas.com
cbsmail
Posts: 22
Joined: Fri Nov 10, 2017 4:38 pm

Wed Dec 13, 2017 6:54 am

Hopki wrote:
Mon Dec 11, 2017 5:36 pm
Apple has already done this with Safari on the desktop. :(
Thanks Hopki, I don't have any Apple devices, but noticed that yesterday when testing at a friends. Works on Safari on an iPhone but not on an iPad or iMac. :roll:

Unfortunately client side solutions aren't going to suffice.

I've changed the autoplay settings to 'document user activation is required' in Chrome and added a play button as this apparently mimics the changes that are due in January. Now I have an error. :(
error.png
error.png (16.88 KiB) Viewed 1338 times
Throws this every time Chrome is initially loaded and refuses to play the sound even after pushing play button, it just throws the above error every time the play button is pressed. The only solution seems to be refreshing the page. Once refreshed the behaviour is as expected, well the autoplay works straight away!

I assume Safari should work like this too? ie once user has pushed play once, subsequent sounds should autoplay? I'm thinking about providing a landing page that has a play tour button, which actually triggers a sound so the autoplay works from there on. A bit dodgy I know, but I figure it should work.
User avatar
Hopki
Gnome
Posts: 11134
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Sun Dec 17, 2017 4:15 pm

Hi,
Yes, a good way is to use a splash screen to welcome people to the tour, on click to close also have an action to play the first sound.
All subsequent sounds should then auto play.
Regards,
Hopki
Hopki
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
Post Reply