new ThreeJsRenderer()
Renderer class for Three.js
Please do not instantiate this class on your own. Use the
Please do not instantiate this class on your own. Use the
RendererFactory instead.
Extends
Methods
-
addCallback(type, callbackFn)
-
Adds a callback function that will be called during specific events
Parameters:
Name Type Description typestring Type of callback: 'render' (only choice available now) callbackFnfunction Callback function to call - Inherited From:
- Source:
-
getMainMarkerId() → {number}
-
Returns the designated main marker ID
- Inherited From:
- Source:
Returns:
main marker ID- Type
- number
-
hideAllModels()
-
Hides all models that have been loaded
-
init()
-
Initializes the instance
- Inherited From:
- Source:
-
initCameraProjMatrix(camProjMatrixArray)
-
Initializes the camera projection matrix
Parameters:
Name Type Description camProjMatrixArrayThree.Matrix4 Camera projection matrix -
setLocalAxisVisible(isVisible)
-
Sets visibility of local axis
Parameters:
Name Type Description isVisibleboolean Visibility of local axis -
setWireframeVisible(isVisible)
-
Sets visibility of wireframe
Parameters:
Name Type Description isVisibleboolean Visibility of wireframe -
showChildrenOfMarker(markerId, visible)
-
Shows all children of marker
Parameters:
Name Type Description markerIdnumber ID of marker visibleboolean Whether to show or hide the children - Inherited From:
- Source:
-
update(dt)
-
Updates the renderer
Parameters:
Name Type Description dtnumber Time elapsed since previous frame