Core
XR Blocks SDK is wrapped around a singleton instance of Core exported as xb.core.
The Core object is resposible for:
- Setup of all components such as the renderer, scene, input, depth, physics, simulator, etc.
- Calling lifecycle functions in all
Scriptentities and XR Blocks components.
Init
To initialize the Core object, call xb.init() or xb.init(options) with a provided set of options.
For a set of options, see src/core/Options.ts.
For example:
import * as xb from 'xrblocks';
const options = new xb.Options();
xb.init(options);