pixi-gl-core
Version:
A set of tidy little pixi objects that make working with WebGL simpler
26 lines (23 loc) • 775 B
JavaScript
var gl = {
createContext: require('./createContext'),
setVertexAttribArrays: require('./setVertexAttribArrays'),
GLBuffer: require('./GLBuffer'),
GLFramebuffer: require('./GLFramebuffer'),
GLShader: require('./GLShader'),
GLTexture: require('./GLTexture'),
VertexArrayObject: require('./VertexArrayObject'),
shader: require('./shader')
};
// Export for Node-compatible environments
if (typeof module !== 'undefined' && module.exports)
{
// Export the module
module.exports = gl;
}
// Add to the browser window pixi.gl
if (typeof window !== 'undefined')
{
// add the window object
window.PIXI = window.PIXI || {};
window.PIXI.glCore = gl;
}