src/program/glowramp.js
/**
   * Use this program to draw
   *
   * Sets up the proper blending modes, etc
   * @param  {Function} fn The draw function
   * @return {void}
   */
Use this program to draw
Sets up the proper blending modes, etc
@param  {Function} fn The draw function
@return {void}
Use this program to draw Sets up the proper blending modes etc @param { Function } fn The draw function @return { void }
use(fn) {
    if(!this.program)
    {
      this.init();
    }
    var gl = this._gl;
    gl.useProgram(this.program);
    gl.disable(gl.CULL_FACE);
    gl.enable(gl.BLEND);
    gl.depthMask(false);
    gl.blendEquation(gl.FUNC_ADD);
    gl.blendFuncSeparate(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA, gl.ONE, gl.ONE_MINUS_SRC_ALPHA);
    fn(this.attributes, this.uniforms);
    resetGL(gl);
  }
use ( fn ) { if ( ! this . program ) { this . init ( ) ; } var gl = this . _gl ; gl . useProgram ( this . program ) ; gl . disable ( gl . CULL_FACE ) ; gl . enable ( gl . BLEND ) ; gl . depthMask ( false ) ; gl . blendEquation ( gl . FUNC_ADD ) ; gl . blendFuncSeparate ( gl . SRC_ALPHA , gl . ONE_MINUS_SRC_ALPHA , gl . ONE , gl . ONE_MINUS_SRC_ALPHA ) ; fn ( this . attributes , this . uniforms ) ; resetGL ( gl ) ; }
Use this program to draw
 Sets up the proper blending modes, etc
 @param  {Function} fn The draw function
 @return {void}
Use this program to draw Sets up the proper blending modes etc @param { Function } fn The draw function @return { void }
// init stuffs. //gl.blendFunc(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA); //gl.useProgram(0);