Skip to content

Conversation

craigliesinger
Copy link
Contributor

per request from Marcos - I've added a couple base VR controller functionalities to the ifc-viewer library. This includes movement / fly around using right controller 'squeeze' and element highlighting use left controller 'select' (and clear with 'squeeze').

@agviegas
Copy link
Collaborator

Hey @craigliesinger if you solve the merge conflicts, I'll merge! Thanks a lot for the contribution

@craigliesinger
Copy link
Contributor Author

Thanks @agviegas ; I'm a github novice so having way to hard of a time figuring out how to resolve it without the write access to do it directly in Github. I'll try to figure it out soon. The code for context in PR is right and not sure why it gets hung up with a conflict:
`private render = () => {
if (this.isThisBeingDisposed) return;
if (this.stats) this.stats.begin();
const isWebXR = this.options.webXR || false;
if (isWebXR) {
document.body.appendChild(VRButton.createButton(this.getRenderer()));
this.getRenderer().xr.enabled = true;
this.renderForWebXR();
} else {
requestAnimationFrame(this.render);
}
this.updateAllComponents();
if (this.stats) this.stats.end();
};

private renderForWebXR = () => {
const newAnimationLoop = () => {
this.webXrMoveTracking();
this.getRenderer().render(this.getScene(), this.getCamera());
};
this.getRenderer().setAnimationLoop(newAnimationLoop);
};

webXrMoveTracking = () => {}; `

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants