Skip to content

Commit

Permalink
Address PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
bialpio authored and toji committed Jan 31, 2020
1 parent 15000a4 commit 9a9eced
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions hit-test.html
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@
let xrViewerSpace = null;
let xrHitTestSource = null;

const sessionInit = {requiredFeatures: ['local', 'hit-test']};

// WebGL scene globals.
let gl = null;
let renderer = null;
Expand Down Expand Up @@ -99,15 +97,15 @@
document.querySelector('header').appendChild(xrButton.domElement);

if (navigator.xr) {
navigator.xr.isSessionSupported('immersive-ar', sessionInit)
navigator.xr.isSessionSupported('immersive-ar')
.then((supported) => {
xrButton.enabled = supported;
});
}
}

function onRequestSession() {
return navigator.xr.requestSession('immersive-ar', sessionInit)
return navigator.xr.requestSession('immersive-ar', {requiredFeatures: ['local', 'hit-test']})
.then((session) => {
xrButton.setSession(session);
onSessionStarted(session);
Expand Down

0 comments on commit 9a9eced

Please sign in to comment.