Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

YouTube 360 video iframe does not work in mobile browser

I am trying to get an embedded iframe for a YouTube 360 video to play on my mobile site - it works fine on a desktop browser but in the mobile browser I just get the flat stereoscopic view playing back. I can confirm it is definitely a HTML5 player

This is clearly an unresolved problem that others are experiencing. See below posts:

  • https://productforums.google.com/forum/#!topic/youtube/7sk92Fs1juk
  • Make Youtube 360 degree Videos work on mobile

So I want help with at least one of these two potential questions / solutions.

1) Is it possible to get this working in a mobile browser at all? Google's documentation suggests that it should

For reference - here is my iframe code

<iframe width="1360" height="500" src="https://www.youtube.com/embed/0x16ngo8xfY?autoplay=1&loop=1&playlist=0x16ngo8xfY" frameborder="0" allowfullscreen></iframe>

2) Assuming not, what is the best way to force my iframe to launch in the YouTube mobile app where the 360 video does work properly

Thanks, Alex

like image 831
AlexHandy1 Avatar asked Feb 10 '16 15:02

AlexHandy1


People also ask

Why is my 360 video not working on YouTube?

If your Android phone has Gyroscope and still the 360-degree videos are not working on it, calibrate the sensor. This should fix 360-degree VR videos not working in YouTube or other channels. To calibrate Gyroscope on Android phones, go to Settings > Accessibility. Select Gyroscope calibration option.

How do I upload a 360 video to YouTube from my iPhone?

To begin the upload to YouTube process, start by tapping on the icon from inside the On iPhone section or choose at the end of the edit flow if you are creating a Clip Capture. Both options will bring up the same system share screen shown in the 2nd image. Next you will want to tap on the YouTube icon.

How do I enable 360 on YouTube?

Open the YouTube app. Search for a VR video or go to the YouTube Virtual Reality house channel by searching for "Virtual Reality." Look for this icon to find the right channel . Select a VR video.


1 Answers

Given lack of other responses and in case anyone else finds this, I resorted to this (unfortunately) slightly hacky solution in the interim which seems to work.

if(window.innerWidth < 760){
     $('.video').on('click', function( e ) {
       e.preventDefault();
       //assumes that by forcing window to go to youtube will kick up option to open in app where experience works - plays my full showreel
       window.location = "https://www.youtube.com/watch?v=0x16ngo8xfY&list=PLzSXIFcDqpiCiKXMtXtVIHnmor9uUsEhC&autoplay=1";
     });
  }
like image 55
AlexHandy1 Avatar answered Oct 19 '22 23:10

AlexHandy1