{"name":"webgl-context","version":"2.1.2","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":"npm run test-browser && npm run test-node","test-browser":"browserify test/test.js | tap-closer | smokestack | faucet","test-node":"node test/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":"ce97109282f9388b12e22d5ca47c779ab0377ff1","_id":"webgl-context@2.1.2","_shasum":"4e8dc3dc78b33a05b63852e7283a6662b4bc102d","_from":".","_npmVersion":"1.4.28","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}],"dist":{"shasum":"4e8dc3dc78b33a05b63852e7283a6662b4bc102d","tarball":"http://registry-npm.ywwl.com/webgl-context/download/webgl-context-2.1.2.tgz","integrity":"sha512-U7atd2arrPjbnfoSnClBxo8g8PErW7mJLMRLHPnsQfw7sMCSqRQHSaFJmP4/Xn9pIjoMPwyvnob6YGrz6V+A/Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCE+aGJViSlIShFoNTjFO1Lc0By25wRqQdGBngxq0rKFQIgJnnOHkblpb7yNl/X3rUtq6VXrnARij6FMsLfFgtexeg="}],"size":2237,"noattachment":false,"key":"/webgl-context/-/webgl-context-2.1.2.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":1427932325369,"_cnpm_publish_time":1427932325369,"dist-tags":{"latest":"2.2.0"}}