本地存储的视频无法在WebVR中呈现

时间:2016-07-20 01:25:38

标签: webvr aframe

基于Github example我的代码已经添加了我自己的360视频,但我在Chrome中遇到控制台错误。

我的代码是:

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Test</title>
    <script src="https://aframe.io/releases/0.2.0/aframe.min.js"></script>  
  </head>
  <body>
    <a-scene>
      <a-assets>
        <video id="video" src="vid.mp4" autoplay loop></video>
      </a-assets>

      <a-videosphere src="#video" rotation="0 180 0"></a-videosphere>
    </a-scene>
  </body>
</html>

我收到以下错误:

Error screenshot

1 个答案:

答案 0 :(得分:1)

想出来:

  1. 确保正确引用文件(从索引文件的位置开始)。

  2. 您的环境安装正确。

  3. 您的本地服务器已启动并正在运行。