{"name":"webgl-context","version":"2.1.0","description":"gets a WebGLRenderingContext","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com"},"dependencies":{},"devDependencies":{"browserify":"^8.0.2","faucet":"0.0.1","smokestack":"^3.1.0","tap-closer":"^1.0.0","tape":"^3.0.3"},"scripts":{"test":"browserify test.js | tap-closer | smokestack | faucet","test-node":"node test-node.js | faucet"},"testling":{"files":"test.js","browsers":["ie/6..latest","chrome/22..latest","firefox/16..latest","safari/latest","opera/11.0..latest","iphone/6","ipad/6","android-browser/latest"]},"repository":{"type":"git","url":"git://github.com/mattdesl/webgl-context.git"},"homepage":"https://github.com/mattdesl/webgl-context","bugs":{"url":"https://github.com/mattdesl/webgl-context/issues"},"keywords":["webgl","glsl","context","glcontext","gl","webglrenderingcontext","webglcontext"],"gitHead":"7b3496bcc57419258005f9c9662a49529325f5e0","_id":"webgl-context@2.1.0","_shasum":"a29fd089c9063cc02ef3716e72995c3387587271","_from":".","_npmVersion":"2.2.0","_nodeVersion":"0.10.35","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}],"dist":{"shasum":"a29fd089c9063cc02ef3716e72995c3387587271","tarball":"http://registry-npm.ywwl.com/webgl-context/download/webgl-context-2.1.0.tgz","integrity":"sha512-7BN3cM07GVBeo2xihu4DAZkGYqz43ur9/FwZSEg/UOXbg5eR4WNZDB9c00IvqLNOxrZ0lmUAHaTUXq2++V9ALw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB7Fx3zw00eLTiwfpaG7qenPhjt+W7QJnYZT6JW+a4xnAiBjilzB7VaPcE0bU67wbW1rBb3Q0XDhWHjlE932D0IJGA=="}],"size":2272,"noattachment":false,"key":"/webgl-context/-/webgl-context-2.1.0.tgz"},"directories":{},"readme":"# webgl-context\n\n[![stable](http://badges.github.io/stability-badges/dist/stable.svg)](http://github.com/badges/stability-badges)\n\nGrabs a WebGLRenderingContext, returning null if it doesn't exist. Similar to [2d-context](https://nodei.co/npm/2d-context/).\n\n```js\n//get a webgl context, will be null if not found\nvar gl = require('webgl-context')()\n\nif (gl) {\n    document.body.appendChild(gl.canvas)\n    //do something...\n}\n```\n\nOr, with options:\n\n```js\n//or with optional settings...\nvar gl = require('webgl-context')({\n    canvas: canvas, //the canvas DOM element to use\n    width: 400, //resizes the canvas..\n    height: 200, \n    antialias: true //can specify custom attributes here\n})\n```\n\n## Usage\n\n[![NPM](https://nodei.co/npm/webgl-context.png)](https://nodei.co/npm/webgl-context/)\n\n#### `ctx = require('webgl-context')([opt])`\n\nGets a new canvas context with optional parameters:\n\n- `canvas` a canvas element to use, otherwise creates a new element\n- `width` a width to set, otherwise no change\n- `height` a height to set, otherwise no change\n- other attributes are passed to the getContext call, like `alpha` and `antialias`\n\nYou can then get a reference of the canvas element with `ctx.canvas`. \n\n## See Also\n\n- [get-canvas-context](https://www.npmjs.com/package/get-canvas-context)\n- [2d-context](https://www.npmjs.com/package/2d-context)\n\n## License\n\nMIT, see [LICENSE.md](http://github.com/mattdesl/webgl-context/blob/master/LICENSE.md) for details.\n","publish_time":1421253204776,"_cnpm_publish_time":1421253204776,"dist-tags":{"latest":"2.2.0"}}