收藏
回答

xr-scene ar-system="modes:Plane" 在华为nova8E启动失败

框架类型 问题类型 终端类型 微信版本 基础库版本
小程序 Bug 微信安卓客户端 8.0.32 2.30.0
<xr-scene ar-system="modes:Plane" bind:ready="handleReady">
  <xr-env env-data="xr-frame-team-workspace-day" />
  <xr-light type="ambient" color="1 1 1" intensity="1" />
  <xr-light type="directional" rotation="40 70 0" color="1 1 1" intensity="3" cast-shadow />
  <xr-assets bind:loaded="handleAssetsLoaded">
    <xr-asset-load type="gltf" asset-id="anchor" src="https://mmbizwxaminiprogram-1258344707.cos.ap-guangzhou.myqcloud.com/xr-frame/demo/ar-plane-marker.glb" />
    <xr-asset-load type="gltf" asset-id="Plate" src="{{modelData.path}}" />
  </xr-assets>
  <xr-ar-tracker mode="Plane">
    <xr-gltf model="anchor"></xr-gltf>
  </xr-ar-tracker>
  <xr-node node-id="setitem">
    <xr-gltf model="Plate" node-id='Plate' anim-autoplay  position="0 0 0" scale="{{modelData.scale}}" rotation="{{modelData.rotation}}" />
  </xr-node>
  <xr-camera clear-color="0.4 0.8 0.6 1" background="ar" 
    is-ar-camera
  />
</xr-scene>


data: {
    loaded: false,
    modelData: {
      path: 'https://houtaicdn.alva.com.cn/medias/resources/wechat/baikeWebview/gltfModels/Dinosaur/Plate/Plate.gltf',
      // path: "https://houtaicdn.alva.com.cn/medias/resources/wechat/baikeWebview/gltfModels/HT/42_haiwangxing/42_haiwangxing.gltf"
      scale: '0.5 0.5 0.5',
      rotation: '0 0 0'
    }
  },
methods: {
    handleAssetsLoaded: function({detail}) {
      this.scene.event.add('touchstart', () => {
        this.scene.ar.placeHere('setitem'true);
      });
    },
    handleReady: function ({detail}) {
      this.scene = detail.value;
    },

    handleShare: function() {
      const supported = this.scene.share.supported;
      if (supported) {
        const options = {
          type: 'jpg',
          quality: 0.8
        };
        const base64 = this.scene.share.captureToDataURL(options);
        const buffer = this.scene.share.captureToArrayBuffer(options);
        this.triggerEvent('showPhoto',base64)
      }
      
    }
  }

华为nova8E  8.0.32微信版本报错(其他手机型号均正常):

[xr-frame] <Error: AR system start error(Plane,1,Back): 2000004>

Error: AR system start error(Plane,1,Back): 2000004

    at https://lib/WAXRFrameRenderContext.js:1:1198904

    at https://lib/WAXRFrameRenderContext.js:1:1199489

回答关注问题邀请回答
收藏

1 个回答

  • Roam
    Roam
    2023-02-21

    这个是底层算法 VK 平面识别的问题,错误码是 2000004。

    目前已经反馈给 VK 相关同学,等修复会统一反馈~

    2023-02-21
    有用
    回复
登录 后发表内容