src/filter.js
/*
 * Create a fullscreen shader layer.
 *
 * Modifies the argument and returns it.
 *
 * Existing properties:
 * obj.shader: Fragment shader name, not including .frag extension
 * obj.uniforms: List of shader uniforms
 * obj.updateUniforms: Method to update program uniforms
 *
 * New properties:
 * obj.prog: Shader program (has uniform locations as attributes)
 * obj.init: Initialize filter
 * obj.destroy: Destroy filter
 * obj.render Render the filter
 */
Create a fullscreen shader layer.
Modifies the argument and returns it.

Existing properties:
obj.shader: Fragment shader name, not including .frag extension
obj.uniforms: List of shader uniforms
obj.updateUniforms: Method to update program uniforms

New properties:
obj.prog: Shader program (has uniform locations as attributes)
obj.init: Initialize filter
obj.destroy: Destroy filter
obj.render Render the filter
Create a fullscreen shader layer . Modifies the argument and returns it . Existing properties : obj . shader : Fragment shader name not including . frag extension obj . uniforms : List of shader uniforms obj . updateUniforms : Method to update program uniforms New properties : obj . prog : Shader program ( has uniform locations as attributes ) obj . init : Initialize filter obj . destroy : Destroy filter obj . render Render the filter
function makeFilter(obj) {
	obj.prog = null;
	obj.init = filterInit;
	obj.destroy = filterDestroy;
	obj.render = filterRender;
	return obj;
}
function makeFilter ( obj ) { obj . prog = null ; obj . init = filterInit ; obj . destroy = filterDestroy ; obj . render = filterRender ; return obj ; }
Create a fullscreen shader layer.
Create a fullscreen shader layer .