index.wxml 1.1 KB

12345678910111213141516171819202122232425
  1. <xr-scene id="xr-scene" bind:ready="handleReady" bind:assetsLoaded="handleLoaded">
  2. <xr-assets>
  3. <xr-asset-load type="texture" asset-id="particle-texture" src="https://mmbizwxaminiprogram-1258344707.cos.ap-guangzhou.myqcloud.com/xr-frame/demo/particles/point.png" />
  4. </xr-assets>
  5. <xr-node>
  6. <xr-mesh node-id="mesh-plane" position="0 -1 0" rotation="0 0 0" scale="5 0.2 5"
  7. geometry="cube" material="blue-mat" uniforms="u_baseColorFactor:0.48 0.78 0.64 1"
  8. ></xr-mesh>
  9. <xr-env sky-map="sky" is-sky2d/>
  10. <xr-particle id="human-face" position="0 0 2" capacity="3000" emit-rate="2000" size="0.1" start-color="1 1 1 0" start-color2="1 1 1 0" texture="particle-texture"></xr-particle>
  11. <xr-camera
  12. id="camera" node-id="camera" position="0 6 -6" clear-color="0.1 0.1 0.1 1"
  13. target="mesh-plane" background="skybox"
  14. camera-orbit-control=""
  15. ></xr-camera>
  16. </xr-node>
  17. <xr-node node-id="lights">
  18. <xr-light type="ambient" color="1 1 1" intensity="0.3" />
  19. <xr-light type="directional" rotation="90 0 0" color="1 1 1" intensity="2.5" />
  20. </xr-node>
  21. </xr-scene>