Factory which creates SKARF.Renderer
NOTE: This is meant for internal usage only as the created instance needs some manual variable assignments and initializations before they are usable. These are done internally by a
NOTE: This is meant for internal usage only as the created instance needs some manual variable assignments and initializations before they are usable. These are done internally by a
Skarf instance.Methods
-
<static> create(type, options)
-
Function to create a SKARF.Renderer instance
Parameters:
Name Type Description typestring Type of ArLib to create: 'threejs' (only choice available now) optionsobject Options Properties
Name Type Description rendererTHREE.WebGLRenderer Three.js renderer sceneTHREE.Scene Three.js scene cameraTHREE.Camera Three.js camera markersJsonFilestring Path to a JSON file that specifies markers and models to load -
<static> register(mappingName, mappingClass)
-
Registers a type string to a class
Parameters:
Name Type Description mappingNamestring Name of the mapping which is used to identify the type when creating instances e.g. 'threejs' mappingClassSKARF.Renderer Renderer class that will be created when the associated type is used