{"_id":"primitive-quad","_rev":"5-da029a7cad4f090e45cab071870cd4b3","name":"primitive-quad","description":"an indexed quad mesh with normals and UVs","dist-tags":{"latest":"2.0.0"},"versions":{"1.0.0":{"name":"primitive-quad","version":"1.0.0","description":"an indexed quad mesh with normals and UVs","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"browserify":"^10.2.4","budo":"^4.1.0","garnish":"^2.1.3","uglify-js":"^2.4.23"},"scripts":{"test":"node test.js","start":"budo demo.js:bundle.js --live --verbose -- | garnish","build":"browserify demo.js | uglifyjs -cm > bundle.js"},"keywords":["glo","js","glo-js","stackgl","gl","glsl","webgl","primitive","mesh","meshes","quad","plane","flat","floor","complex","simplicial","cells","indexed"],"repository":{"type":"git","url":"git://github.com/glo-js/primitive-quad.git"},"homepage":"https://github.com/glo-js/primitive-quad","bugs":{"url":"https://github.com/glo-js/primitive-quad/issues"},"gitHead":"9a3dd520c0b6270892bddcd7c140d05b637de7dc","_id":"primitive-quad@1.0.0","_shasum":"75d0c3ee2630dc162a2f7cd5627335c60e9699f1","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"75d0c3ee2630dc162a2f7cd5627335c60e9699f1","tarball":"https://registry.npmjs.org/primitive-quad/-/primitive-quad-1.0.0.tgz","integrity":"sha512-hZ+iv+ztMMud2aFT+TC+dvbXFRDHdV0JDyi1r2srap7Z4SJQWDG7F1AoEBlJ3f317CDPImrKgNzpgzOxd1cIDg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEUIplOVyWMs+7dyOWw/pekjWEztWVVJYFD3ciXFPAOqAiEA7G1YzD5Cty19gcUJLc81eQJQ5v8p2jnuxO4NMyWklpY="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}]},"1.0.1":{"name":"primitive-quad","version":"1.0.1","description":"an indexed quad mesh with normals and UVs","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"browserify":"^10.2.4","budo":"^4.1.0","garnish":"^2.1.3","uglify-js":"^2.4.23"},"scripts":{"test":"node test.js","start":"budo demo.js:bundle.js --live --verbose -- | garnish","build":"browserify demo.js | uglifyjs -cm > bundle.js"},"keywords":["glo","js","glo-js","stackgl","gl","glsl","webgl","primitive","mesh","meshes","quad","plane","flat","floor","complex","simplicial","cells","indexed"],"repository":{"type":"git","url":"git://github.com/glo-js/primitive-quad.git"},"homepage":"https://github.com/glo-js/primitive-quad","bugs":{"url":"https://github.com/glo-js/primitive-quad/issues"},"gitHead":"fa60d00661374410a72dd3c88e960ec3df617fd0","_id":"primitive-quad@1.0.1","_shasum":"802a221f2b134b078fbd42d84ef45d516b5f3ae6","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.32","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"802a221f2b134b078fbd42d84ef45d516b5f3ae6","tarball":"https://registry.npmjs.org/primitive-quad/-/primitive-quad-1.0.1.tgz","integrity":"sha512-8yDCdXbc5QzIj7yOHPXuw/CaJcGd0EDLMDhlB2ctTGJyEjGI7XuIP5GOu+4bP0O6g3HHej5XDLO4jb7LNL/SvQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDPIauqvMUomelPF7FtBl+Gi485ToH5gR5R6EZFeO0GeAiAPbbu0DA3m4VPcm5NXiHK7g7Qot4OncoYFN74mg9x4IQ=="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}]},"2.0.0":{"name":"primitive-quad","version":"2.0.0","description":"an indexed quad mesh with normals and UVs","main":"index.js","license":"MIT","author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"dependencies":{},"devDependencies":{"browserify":"^10.2.4","budo":"^4.1.0","garnish":"^2.1.3","uglify-js":"^2.4.23","glo-demo-primitive":"^2.0.1"},"scripts":{"test":"node test.js","start":"budo demo.js:bundle.js --live --verbose -- | garnish","build":"browserify demo.js | uglifyjs -cm > bundle.js"},"keywords":["glo","js","glo-js","stackgl","gl","glsl","webgl","primitive","mesh","meshes","quad","plane","flat","floor","complex","simplicial","cells","indexed"],"repository":{"type":"git","url":"git://github.com/glo-js/primitive-quad.git"},"homepage":"https://github.com/glo-js/primitive-quad","bugs":{"url":"https://github.com/glo-js/primitive-quad/issues"},"gitHead":"3954845511aac717e08e9591b089ecfc124d1574","_id":"primitive-quad@2.0.0","_shasum":"c20993e4f9600238926bb500e529053043ef8aeb","_from":".","_npmVersion":"3.10.10","_nodeVersion":"6.9.4","_npmUser":{"name":"mattdesl","email":"dave.des@gmail.com"},"dist":{"shasum":"c20993e4f9600238926bb500e529053043ef8aeb","tarball":"https://registry.npmjs.org/primitive-quad/-/primitive-quad-2.0.0.tgz","integrity":"sha512-JlPRH5x3QEqoIeHvxHY6ePLhpjSG7FEGxitR8sbfkfCjJK+OEVODTE4j6US12gMqvQqXzRGkkmuYYvJCozifMA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBZmPaDRkew+M3T3UK6cP0ZurJQhG2b3Sl3TDaJwIHVUAiEA056jjrdgs0BuygHNigVpU14Tj8EeuQGEQ1SEleSHLrs="}]},"maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}],"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/primitive-quad-2.0.0.tgz_1491571571846_0.8509559889789671"}}},"readme":"# primitive-quad\n\n[![stable](http://badges.github.io/stability-badges/dist/stable.svg)](http://github.com/badges/stability-badges)\n\n[![screen](http://i.imgur.com/pp1CRXf.png)](http://glo-js.github.io/primitive-quad/)\n\n[(demo)](http://glo-js.github.io/primitive-quad/)\n\n<!-- iframe: http://glo-js.github.io/primitive-quad/index.html -->\n\nCreates an indexed quad mesh (two triangles), with normals and UVs. It sits on the XY plane with `Z=0`, and positions ranging from `-1.0` to `1.0`.\n\n## Example\n\n```js\nvar mesh = require('primitive-quad')()\n\n// the simplicial complex\nconsole.log(mesh.positions, mesh.cells)\n\n// rendering attributes\nconsole.log(mesh.uvs)\nconsole.log(mesh.normals)\n```\n\n## Usage\n\n[![NPM](https://nodei.co/npm/primitive-quad.png)](https://www.npmjs.com/package/primitive-quad)\n\n#### `mesh = quad([scale])`\n\nCreates a new indexed quad along the XY plane, with an optional `scale` number (defaults to 1).\n\n`scale` can also be an `[x, y]` array to scale each axes independently.\n\nThe vertices are in counter-clockwise order, the UV origin is top-left (0 - 1 range), and the normals are negative along the Z axis.\n\nThe returned mesh is an object with the following data:\n\n```\n{\n  positions: [ [x, y, z], [x, y, z], ... ],\n  cells: [ [a, b, c], [a, b, c], ... ],\n  uvs: [ [u, v], [u, v], ... ],\n  normals: [ [x, y, z], [x, y, z], ... ]\n}\n```\n\n## License\n\nMIT, see [LICENSE.md](http://github.com/glo-js/primitive-quad/blob/master/LICENSE.md) for details.\n","maintainers":[{"name":"mattdesl","email":"dave.des@gmail.com"}],"time":{"modified":"2022-06-24T15:43:38.705Z","created":"2015-06-27T21:25:01.420Z","1.0.0":"2015-06-27T21:25:01.420Z","1.0.1":"2015-06-27T21:26:28.585Z","2.0.0":"2017-04-07T13:26:12.116Z"},"homepage":"https://github.com/glo-js/primitive-quad","keywords":["glo","js","glo-js","stackgl","gl","glsl","webgl","primitive","mesh","meshes","quad","plane","flat","floor","complex","simplicial","cells","indexed"],"repository":{"type":"git","url":"git://github.com/glo-js/primitive-quad.git"},"author":{"name":"Matt DesLauriers","email":"dave.des@gmail.com","url":"https://github.com/mattdesl"},"bugs":{"url":"https://github.com/glo-js/primitive-quad/issues"},"license":"MIT","readmeFilename":"README.md"}