Fork me on GitHub

API Documentation


Extends GLGE.QuickNotation.
Sets the scene to render
Defined in: glge_renderer.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
GLGE.Renderer(canvas, error, props)
Method Summary
Method Attributes Method Name and Description
 
Clears all viewport data and defaults back to canvas size
 
Gets the clear type for rendering GLGE.C_ALL, GLGE.C_STENCIL, GLGE.C_DEPTH, GLGE.C_COLOR
 
Gets the scene which is set to be rendered
 
Gets the height of the viewport to render
 
Gets the left offset of the viewport to render
 
Gets the top offset of the viewport to render
 
Gets the width of the viewport to render
 
Renders the current scene to the canvas
 
Sets the clear type for rendering GLGE.C_ALL, GLGE.C_STENCIL, GLGE.C_DEPTH, GLGE.C_COLOR
 
setScene(scene)
Sets the scene to render
 
Sets the filter to use for the transition
 
Sets the height of the viewport to render
 
Sets the left offset of the viewport to render
 
Sets the top offset of the viewport to render
 
Sets the width of the viewport to render
 
transitionTo(scene, duration)
Uses the transitions filter to transition to the new scene
Methods borrowed from class GLGE.QuickNotation:
_
Class Detail
GLGE.Renderer(canvas, error, props)
Parameters:
{object} canvas
The canvas element to render to
error
props
Method Detail
clearViewport()
Clears all viewport data and defaults back to canvas size

getClearType()
Gets the clear type for rendering GLGE.C_ALL, GLGE.C_STENCIL, GLGE.C_DEPTH, GLGE.C_COLOR
Returns:
how to clear the viewport for the next render

getScene()
Gets the scene which is set to be rendered
Returns:
the current render scene

getViewportHeight()
Gets the height of the viewport to render
Returns:
the viewport height

getViewportOffsetX()
Gets the left offset of the viewport to render
Returns:
the left viewport offset

getViewportOffsetY()
Gets the top offset of the viewport to render
Returns:
the top viewport offset

getViewportWidth()
Gets the width of the viewport to render
Returns:
the viewport width

render()
Renders the current scene to the canvas

setClearType(type)
Sets the clear type for rendering GLGE.C_ALL, GLGE.C_STENCIL, GLGE.C_DEPTH, GLGE.C_COLOR
Parameters:
type
how to clear the viewport for the next render

setScene(scene)
Sets the scene to render
Parameters:
{GLGE.Scene} scene
The scene to be rendered

setTransitionFilter(filter2d)
Sets the filter to use for the transition
Parameters:
{GLGE.Filter2d} filter2d
the 2d filter to use for transitions

setViewportHeight(height)
Sets the height of the viewport to render
Parameters:
height
the height of the viewport to render

setViewportOffsetX(left)
Sets the left offset of the viewport to render
Parameters:
left
the left offset of the viewport to render

setViewportOffsetY(top)
Sets the top offset of the viewport to render
Parameters:
top
the top offset of the viewport to render

setViewportWidth(width)
Sets the width of the viewport to render
Parameters:
width
the width of the viewport to render

transitionTo(scene, duration)
Uses the transitions filter to transition to the new scene
Parameters:
{GLGE.Scene} scene
The scene to transition to
{Number} duration
The transiton time in ms

Documentation generated by JsDoc Toolkit 2.4.0 on Sun Feb 12 2012 14:20:23 GMT+0000 (GMT)