Description
Supported Script Types: Interface Scripts • Client Entity Scripts • Avatar Scripts
TheRender
API enables you to configure the graphics engine.Properties
Name | Type | Summary |
---|---|---|
renderMethod | Render.RenderMethod |
The render method being used. |
shadowsEnabled | boolean |
|
ambientOcclusionEnabled | boolean |
|
antialiasingMode | integer |
The active anti-aliasing mode. |
viewportResolutionScale | number |
The view port resolution scale, |
Methods
Name | Return Value | Summary |
---|---|---|
getAmbientOcclusionEnabled
|
boolean |
Gets whether or not ambient occlusion is enabled. |
getAntialiasingMode
|
AntialiasingMode |
Gets the active anti-aliasing mode. |
getConfig
|
object |
Gets the configuration for a rendering job by name. Warning: For internal, debugging purposes. Subject to change. |
getFullScreenScreen
|
string |
Gets the screen used when switching to full screen mode. |
getRenderMethod
|
Render.RenderMethod |
Gets the render method being used. |
getRenderMethodNames
|
Array.<string> |
Gets the names of the possible render methods, per Render.RenderMethod. |
getScreens
|
Array.<string> |
Returns the list of screens |
getShadowsEnabled
|
boolean |
Gets whether or not shadows are enabled. |
getVerticalFieldOfView
|
number |
Gets the vertical field of view in degrees. |
getViewportResolutionScale
|
number |
Gets the view port resolution scale. |
setAmbientOcclusionEnabled
|
None |
Sets whether or not ambient occlusion is enabled. |
setAntialiasingMode
|
None |
Sets the active anti-aliasing mode. |
setFullScreenScreen
|
bool |
Sets the screen used when switching to full screen mode. This function will only succeed if the name passed is one of the entries from Render.getScreens. Otherwise, it will return False and have no effect. |
setRenderMethod
|
None |
Sets the render method to use. |
setShadowsEnabled
|
None |
Sets whether or not shadows are enabled. |
setVerticalFieldOfView
|
None |
Sets the vertical field of view in degrees. |
setViewportResolutionScale
|
None |
Sets the view port resolution scale. |
Signals
Name | Summary |
---|---|
settingsChanged
|
Triggered when one of the |
Type Definitions
RenderMethod Type: number |
|||||||||
---|---|---|---|---|---|---|---|---|---|
The rendering method is specified by the following values:
|
Method Details
(static) getAmbientOcclusionEnabled( ) → {boolean}
Returns: true if ambient occlusion is enabled, false if it's disabled.
|
---|
Gets whether or not ambient occlusion is enabled. |
(static) getAntialiasingMode( ) → {AntialiasingMode}
Returns: The active anti-aliasing mode. |
---|
Gets the active anti-aliasing mode. |
(static) getConfig( name ) → {object}
Returns: The configuration for the rendering job. |
||||||
---|---|---|---|---|---|---|
Gets the configuration for a rendering job by name. Warning: For internal, debugging purposes. Subject to change. Parameters
|
(static) getFullScreenScreen( ) → {string}
Returns: The name of the screen used for full screen mode. |
---|
Gets the screen used when switching to full screen mode. |
(static) getRenderMethod( ) → {Render.RenderMethod}
Returns: The render method being used. |
---|
Gets the render method being used. Example
|
(static) getRenderMethodNames( ) → {Array.<string>}
Returns: The names of the possible render methods. |
---|
Gets the names of the possible render methods, per Render.RenderMethod. Example
|
(static) getScreens( ) → {Array.<string>}
Returns: The names of the available screens. |
---|
Returns the list of screens |
(static) getShadowsEnabled( ) → {boolean}
Returns: true if shadows are enabled, false if they're disabled.
|
---|
Gets whether or not shadows are enabled. |
(static) getVerticalFieldOfView( ) → {number}
Returns: The vertical field of view in degrees. |
---|
Gets the vertical field of view in degrees. |
(static) getViewportResolutionScale( ) → {number}
Returns: The view port resolution scale, > 0.0 .
|
---|
Gets the view port resolution scale. |
(static) setAmbientOcclusionEnabled( enabled ) | ||||||
---|---|---|---|---|---|---|
Sets whether or not ambient occlusion is enabled. Parameters
|
(static) setAntialiasingMode( The ) | ||||||
---|---|---|---|---|---|---|
Sets the active anti-aliasing mode. Parameters
|
(static) setFullScreenScreen( ) → {bool}
Returns: True if the setting was successful. |
---|
Sets the screen used when switching to full screen mode. This function will only succeed if the name passed is one of the entries from Render.getScreens. Otherwise, it will return False and have no effect. |
(static) setRenderMethod( renderMethod ) | ||||||
---|---|---|---|---|---|---|
Sets the render method to use. Parameters
|
(static) setShadowsEnabled( enabled ) | ||||||
---|---|---|---|---|---|---|
Sets whether or not shadows are enabled. Parameters
|
(static) setVerticalFieldOfView( fieldOfView ) | ||||||
---|---|---|---|---|---|---|
Sets the vertical field of view in degrees. Parameters
|
(static) setViewportResolutionScale( resolutionScale ) | ||||||
---|---|---|---|---|---|---|
Sets the view port resolution scale. Parameters
|
Signal Details
settingsChanged(
)
Returns: Signal |
---|
Triggered when one of the Example
|