Created
June 20, 2019 12:28
-
-
Save positlabs/1a9e00e39fc98509b8be3b50f9d1ecc0 to your computer and use it in GitHub Desktop.
Spark AR script to resize plane to match screen size
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Resize plane to match screen size | |
*/ | |
const Scene = require('Scene') | |
const camera = Scene.root.find('Camera') | |
const plane = Scene.root.find('plane0') | |
plane.width = camera.focalPlane.width | |
plane.height = camera.focalPlane.height |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment