Skip to content

wolfboyyang/dt-bim-xr

Repository files navigation

dt-bim-xr

Digital Twins Prototyping for BIM with WebXR.

Live Demo

Github Pages:

Or on fly.io:

Development

npm i
cd demo
npm i
npm run dev

Build

cd demo
npm run build

Deploy to fly.io

flyctl deploy

Debug Inspector

change the condition to true, and press clt+shift+I.

// hide/show the Inspector
  if (true) {
    window.addEventListener("keydown", async (ev) => {
      // Shift+Ctrl+I
      if (ev.shiftKey && ev.ctrlKey && ev.code === "KeyI") {
        await import("@babylonjs/core/Debug/debugLayer");
        await import("@babylonjs/inspector");
        if (scene.debugLayer.isVisible()) {
          scene.debugLayer.hide();
        } else {
          scene.debugLayer.show();
        }
      }
    });
  }

change position of MainCanvas in style.css to relative to see the scene explorer.

#MainCanvas {
  position: relative; left: 0; top: 0; width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0);
}

About

Digital Twins Prototyping for BIM with WebXR.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages