Skip to content

drumath2237/babylon-webar-sandbox

Repository files navigation

babylon-webar-sandbox

github pages

About

HoloLens2のOSアプデ(21H1)でChromium-based Edgeが使えるようになり、 WebXRができるようになったのでBabylon.jsで試すために作った。

HandTrackingだったりHolographic Buttonだったりが使える。

https://twitter.com/ninisan_drumath/status/1393625116660043785

Demo

img

(QRコード使うとHoloLensで表示するのに便利なので)

img

Install

yarn install

Usage

WebXR APIを使うので、LAN内であってもhttpsで通信する必要がある。 ターミナルで秘密鍵、公開鍵を作成するために以下を実行する。(Windowsの場合はwslを使う)

openssl req -newkey rsa:2048 -new -nodes -x509 -days 3650 -keyout key.pem -out cert.pem

途中にPCのIPアドレスを指定する箇所がある。

HoloLens2のEdgeでedge://flagsにアクセスして

  • WebXR Incubation
  • WebXR experience with joint tracking

を有効にする。

そのあとターミナルに戻って以下を実行し、IPを指定してHoloLens2からアクセスする。

yarn dev

Contact

何かございましたらにー兄さんまでお願いします。