Instruments WebGL shaders to keep track of updates and modify existing shaders on the fly.
hook = require('gl-shader-hook')(gl)
Takes a WebGL canvas context
gl, instrumenting that context and returning an
An object listing all of the currently discovered shaders. Each of these are wrapped in a class to provide you with some extra information and functionality. Unless otherwise specified, "shaders" and "programs" in these docs from here on out refer to wrapped shaders and wrapped programs.
An object listing all of the currently discovered programs.
Emitted when a new shader is created.
Emitted when a new program is created.
Emitted whenever a shader's source is successfully compiled.
Emitted whenever a program is successfully linked.
Emitted whenever that shader has been successfully compiled.
Updates a shader's source and recompiles it.
MIT. See LICENSE.md for details.