2016-08-08 24 views

回答

0

使用position部件定位和scale組分按比例繪製。

<!-- 360 video, rotated 180-degrees to select an initial view. --> 
    <a-videosphere src="#cityVideo" rotation="0 180 0"></a-videosphere> 

    <!-- Video controls. --> 
    <a-entity 
    video-controls="src: #cityVideo; backgroundColor: #333; barColor: #EF2D5E; textColor: #DADADA; infoTextTop: Gaze and click on the icon or progress bar.; infoTextBottom: Double-click outside of the player to toggle it." 
    position="0 1 -2" scale="1 1.5 1"></a-entity> 

https://aframe.io/docs/0.2.0/components/position.html https://aframe.io/docs/0.2.0/components/scale.html

+0

非常感謝。也許我沒有清楚地描述這個問題。我的問題是,當我使用這些代碼時,視頻將充滿整個屏幕。我不想要它。例如,我需要視頻佔據屏幕的一半(瀏覽器)。視頻位於指定的位置(如html,左側,頂部,底部或右側屬性)。我怎樣才能實現這個功能? –

+0

您可以創建一個半球體 https://aframe.io/docs/0.2.0/components/geometry.html#sphere – ngokevin

+0

我爲你創建了一個問題:http://stackoverflow.com/questions/38857027/how-to-create-a-180-degree-semisphere-segment-partial-video-sphere-in-a-frame/38857090# 38857090 – ngokevin

相關問題