Google VR视频无法加载 [英] Google VR video doesn't load
问题描述
我正在使用Google
这是控制台显示的内容:
当我从Google的网址加载示例视频时,它就像一个魅力: https://storage.googleapis.com/vrview/examples/video/congo_2048.mp4
这是我正在使用的代码(使用相同的视频,但存储在我的网站上):
< 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>
即使我的域名视频的完整链接,视频仍然没有这是文件结构:
- css
- img
- js
- video
- congo.mp4
- index.html
感谢您帮助我!
编辑:
设置CORS标题 - 请参阅 http://enable-cors.org/server.html用于特定于服务器的详细信息
I'm using Google VR View for the web to load in a 360 video. But when I load the video, it says Error, Render: video load error: [object event]
This is what the console shows:
When I load the example video from Google's 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 stored 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 the full link to the video on 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 out!
EDIT:
Set CORS headers - see http://enable-cors.org/server.html for server specific details
这篇关于Google VR视频无法加载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!