Methods
# addEffect(effect)
Add post-processing effect
Parameters:
Name | Type | Description |
---|---|---|
effect |
Object
|
Effect configuration |
# applyEffect(effect, inputTexture)
Apply single effect
Parameters:
Name | Type | Description |
---|---|---|
effect |
Object
|
Effect to apply |
inputTexture |
WebGLTexture
|
Input texture |
# bindFrameBuffer(index)
Bind framebuffer
Parameters:
Name | Type | Description |
---|---|---|
index |
number
|
Framebuffer index |
# createFrameBuffer(index)
Create framebuffer
Parameters:
Name | Type | Description |
---|---|---|
index |
number
|
Framebuffer index |
# render(renderCallback)
Render with effects
Parameters:
Name | Type | Description |
---|---|---|
renderCallback |
function
|
Main render function |
# renderToScreen(texture)
Render texture to screen
Parameters:
Name | Type | Description |
---|---|---|
texture |
WebGLTexture
|
Texture to render |