index.wxml 933 B

1234567891011121314151617181920
  1. <xr-demo-viewer
  2. title="多光源glTF案例"
  3. intro="组件和页面通信实现资源加载时覆盖加载界面,以及多个进行动画光源(红色spotLight、白色点光源、白色平行光),于glTF光照测试场景中的渲染效果。"
  4. code="{{xmlCode}}"
  5. >
  6. <xr-gltf-light-loading
  7. disable-scroll
  8. id="main-frame"
  9. width="{{renderWidth}}"
  10. height="{{renderHeight}}"
  11. style="width:{{width}}px;height:{{height}}px;top:{{top}}px;left:{{left}}px;display:block;"
  12. loaded="{{loaded}}"
  13. bind:assetsProgress="handleProgress"
  14. bind:assetsLoaded="handleLoaded"
  15. />
  16. <view wx:if="{{!loaded}}" style="position: absolute;display: flex; justify-content: center; align-items: center; left: 0;top: 0;width: {{width}}px;height: {{height}}px;background-color: #6aa; text-align: center;line-height: 24px;">
  17. <text style="color: white;font-size: 18px;">{{progressInfo}}</text>
  18. </view>
  19. </xr-demo-viewer>