Constructor
new RenderCanvas(canvas, options)
Constructor
Parameters:
Name | Type | Description |
---|---|---|
canvas |
string | Id of the container |
options |
Object | Options |
Extends
Members
Methods
clear(colornullable)
Clear the canvas
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
color |
Color |
<nullable> |
A Color instance |
createTask() → {number}
Create a new task
- Inherited From:
RenderTask's index
number
display()
Display
- Inherited From:
getHeight() → (non-null) {number}
Get height
- Inherited From:
Height in pixels
number
getSize() → {Array.<number>}
Get size
- Inherited From:
A array with size on x and y
Array.<number>
getWidth() → (non-null) {number}
Get width
- Inherited From:
Width in pixels
number
removeTasks()
Remove all the tasks in memory
- Inherited From:
render(scene, camera)
Render the given scene
Parameters:
Name | Type | Description |
---|---|---|
scene |
Scene | A Scene instance |
camera |
Camera | A Camera instance |
- Inherited From:
setActiveTask(index)
Set the task with the given index active
Parameters:
Name | Type | Description |
---|---|---|
index |
number | An integer representing task's index |
- Inherited From: