在视频范围内显示图像
Display a-image within a-videosphere
我想在我的 videosphere 中显示图像,但它不显示图像。
这是我当前的代码,基于在 Whosebug 和 A-Frame 示例展示中找到的示例:
<a-scene>
<a-image src="assets/A.png" height:"100" position:"1 1 1" rotation:"0 90 0" scale:"1 1 1" visible:"true">
</a-image>
<a-videosphere rotation="0 0 0" src="#video"
play-on-window-click
play-on-vrdisplayactivate-or-enter-vr>
</a-videosphere>
<a-camera user-height="0" wasd-controls-enabled="false" arrow-key-rotation>
<a-entity id="msg" position="0 -0.3 -1.5" text="align:center;
width:3;
wrapCount:100;
color:red;
value:Click window to make the video play, if needed."
hide-once-playing="#video">
</a-entity>
</a-camera>
<a-assets>
<!-- Single source video. -->
<video id="video" style="display:none" autoplay loop crossorigin="anonymous" playsinline webkit-playsinline>
<source type="video/mp4" src="assets/360/promo.mp4" />
</video>
</a-assets>
</a-scene>
一切正常,没有任何错误。 AFRAME.registerComponent 文件当然包含在顶部。它根本不显示我的图像。有谁能够帮助我?甚至可以在视频球中显示图像吗?
如果 this 是您想要的,那么唯一的问题是将“:”替换为“=[=23=” ]”这里:
height:"100" position:"1 1 1" rotation:"0 90 0" scale:"1 1 1" visible:"true"
HTML 属性:
<a-entity attribute="data"></data>
属性特性:
<a-entity attribute="propertyOne: data; propertyTwo: data"></data>
我想在我的 videosphere 中显示图像,但它不显示图像。 这是我当前的代码,基于在 Whosebug 和 A-Frame 示例展示中找到的示例:
<a-scene>
<a-image src="assets/A.png" height:"100" position:"1 1 1" rotation:"0 90 0" scale:"1 1 1" visible:"true">
</a-image>
<a-videosphere rotation="0 0 0" src="#video"
play-on-window-click
play-on-vrdisplayactivate-or-enter-vr>
</a-videosphere>
<a-camera user-height="0" wasd-controls-enabled="false" arrow-key-rotation>
<a-entity id="msg" position="0 -0.3 -1.5" text="align:center;
width:3;
wrapCount:100;
color:red;
value:Click window to make the video play, if needed."
hide-once-playing="#video">
</a-entity>
</a-camera>
<a-assets>
<!-- Single source video. -->
<video id="video" style="display:none" autoplay loop crossorigin="anonymous" playsinline webkit-playsinline>
<source type="video/mp4" src="assets/360/promo.mp4" />
</video>
</a-assets>
</a-scene>
一切正常,没有任何错误。 AFRAME.registerComponent 文件当然包含在顶部。它根本不显示我的图像。有谁能够帮助我?甚至可以在视频球中显示图像吗?
如果 this 是您想要的,那么唯一的问题是将“:”替换为“=[=23=” ]”这里:
height:"100" position:"1 1 1" rotation:"0 90 0" scale:"1 1 1" visible:"true"
HTML 属性:
<a-entity attribute="data"></data>
属性特性:
<a-entity attribute="propertyOne: data; propertyTwo: data"></data>