Open3

Babylon.jsでWebAR名刺を作りたい

https://doc.babylonjs.com/divingDeeper/webXR/webXRARFeatures
var createScene = async function () {
    var scene = new BABYLON.Scene(engine);
    var camera = new BABYLON.FreeCamera("camera1", new BABYLON.Vector3(0, 5, -10), scene);
    camera.setTarget(BABYLON.Vector3.Zero());
    camera.attachControl(canvas, true);
    var light = new BABYLON.HemisphericLight("light1", new BABYLON.Vector3(0, 1, 0), scene);
    light.intensity = 0.7;
    var sphere = BABYLON.Mesh.CreateSphere("sphere1", 16, 2, scene);
    sphere.position.y = 2;
    sphere.position.z = 5;
  
    const xr = await scene.createDefaultXRExperienceAsync({
      // ask for an ar-session
      uiOptions: {
        sessionMode: "immersive-ar",
      },
    });
  
    return scene;
  };

localhostだと成功するが、Network IPv4のアドレスだと成功しない

Uncaught (in promise) Error: WebXR can only be served over HTTPS
    at new e (babylon.js:1:2767482)
    at Function.e.CreateAsync (babylon.js:1:2791833)
    at t.gn.createDefaultXRExperienceAsync (babylon.js:1:2795644)
    at createScene (index.js:27:28)
    at eval (index.js:36:21)
    at eval (index.js:46:3)
    at Module../src/index.js (main.js:276:1)
    at __webpack_require__ (main.js:305:33)
    at main.js:1378:37
    at main.js:1380:12
ログインするとコメントできます