exokitxr / exokit-web

Exokit WebXR engine for the browser
70 stars 18 forks source link

Canvas viewport transclusion #17

Closed avaer closed 5 years ago

avaer commented 5 years ago

Fixes #16.

This PR fixes that by proxying the top-level canvas viewport into the internal getBoundingClientRect calls.

The viewport is captured during mouseenter, which should be good enough for any case that doesn't animate the <canvas> around the page while the user is interacting with it -- which would be pretty weird.