Usage of the SDK constitutes your agreement with the Matterport SDK Agreement. Email developers@matterport.com with any questions.
Hierarchy
- IComponentContext
Index
Properties
camera
The main camera. It is read-only.
See https://threejs.org/docs/#api/en/cameras/Camera
renderer
The showcase three.js renderer.
See https://threejs.org/docs/#api/en/renderers/WebGLRenderer
scene
The showcase scene.
See https://threejs.org/docs/#api/en/scenes/Scene
three
The three.js module.
Component Context
The context object contains the three.js module and the main aspects of the rendering engine.
The camera, scene, or renderer may will likely be replaced in the future with an sdk module.
function Cylinder() { this.onInit = function() { var THREE = this.context.three; var geometry = new THREE.CylinderGeometry( 5, 5, 20, 32 ); var material = new THREE.MeshBasicMaterial( {color: 0xffff00} ); var cylinder = new THREE.Mesh( geometry, material ); }; }