<a-entity>
<a-box>
, <a-sphere>
, <a-plane>
, <a-obj-model>
<a-entity width="2">
width
, height
, depth
, radius
, material
, geometry
, src
, id
, position
, rotation
<a-scene>
<a-box
color="red"
></a-box>
</a-scene>
width="2" height="2" depth="2"
geometry="width: 2; height: 2; depth: 2"
scale="1 1 1"
scale="-1 -1 1"
position="0 0 0"
material="color: red; opacity: .5"
<a-assets>
<img id="texture1" src="texture.png" />
<audio id="coin" src="coin.mp3"></audio>
<video id="rick" src="nggyu.mp4"></video>
<a-mixin id="massive" scale="10 10 10"></a-mixin>
</a-assets>
<a-entity ...>
<a-animation
attribute="rotation"
dur="10000"
fill="forwards"
to="0 360 0"
easing="linear"
repeat="indefinite"
></a-animation>
</a-entity>
.querySelector('a-image')
.getAttribute('opacity')
.setAttribute('material', 'color', 'red')
.addEventListener('collide')
.createElement('a-entity')
// jQuery
$('a-box').attr('width', 5);
// d3
d3.select('a-scene')
.selectAll('a-box.bar')
.data(data);
// Jade/Pug example
a-scene(
fog='type: linear; far: 20; color: #1a1a1a'
)
a-entity(
position='2 2.5 0'
rotation='0 12 0'
)
each foo,index in locals.bar
a-entity(
position=(index * 1.4) + ' 0 ' + (index * -2)
rotation='0 ' + (index * -15) + ' 0'
)