Google VR video not loading

I use Google VR View for the web to download 360 videos. But when I upload the video, it says Error, Render: error loading video: [event of the object]

enter image description here

Here is what the console shows:

enter image description here

When I download a sample video from a Google URL, it works like a charm: https://storage.googleapis.com/vrview/examples/video/congo_2048.mp4

This is the code I'm using (with the same video but saved on my site):

<div id="vrview"></div>

<script src="//storage.googleapis.com/vrview/2.0/build/vrview.min.js"></script>

<script>
    window.addEventListener('load', onVrViewLoad)
    function onVrViewLoad() {
        var vrView = new VRView.Player('#vrview', {
            video: 'video/congo.mp4',
            is_stereo: true 
        });
    };
</script>

[Edit] Even with a full link to a video in my domain, the video still doesn’t work.

[Edit 2] This is the file structure:

  • CSS
  • IMG
  • Js
  • video
    • congo.mp4
  • index.html

Thanks for helping me!

+4
source share
3
+3

(, ), , CORS.

youbute 360 ​​. .. , 360 . ?

: https://stackoverflow.com/questions/41312283/how-to-play-youtube-360-videos-using-vrview-web

cf. http://vcml.cafe24.com/humble.php

    window.addEventListener('load', onVrViewLoad);

    //It works
    function onVrViewLoad() {

      var vrView = new VRView.Player('#vrview', {
    	width: '100%',
    	height: 600,
    	video: 'http://storage.googleapis.com/vrview/examples/video/congo_2048.mp4',
    	
    	is_stereo: true,
      });
      
      //Now I'm struggling. Not working
      var vrView1 = new VRView.Player('#vrview1', {
    	width: '100%',
    	height: 600,
    	
    	video: 'https://www.youtube.com/embed/OkLa7jkFXpU',
    	//video: 'http://vcml.cafe24.com/video.mp4',
    	
    	is_stereo: false,
      });
    }
	Congo Video
  <div id="vrview"></div>
  
	Youtubu Video
  <div id="vrview1"></div>
Hide result
+2

script <script src="//storage.googleapis.com/vrview/2.0/build/vrview.min.js"></script>, <script src="vrview-master/build/vrview.js"></script> zip .

0

Source: https://habr.com/ru/post/1663450/


All Articles