{"_id":"bresenham","_rev":"1927754","name":"bresenham","description":"Bresenham's line algorithm","dist-tags":{"latest":"0.0.4"},"maintainers":[{"name":"lennon","email":"madbence@gmail.com"}],"time":{"modified":"2021-12-09T13:55:02.000Z","created":"2014-05-05T20:15:25.478Z","0.0.4":"2016-01-14T10:49:53.999Z","0.0.3":"2014-06-11T20:14:46.988Z","0.0.2":"2014-05-21T12:10:07.531Z","0.0.1":"2014-05-05T20:30:14.231Z","0.0.0":"2014-05-05T20:15:25.478Z"},"users":{"nelix":true,"fabian.moron.zirfas":true},"author":{"name":"Bence Dányi","email":"madbence@gmail.com"},"repository":{"type":"git","url":"git+ssh://git@github.com/madbence/node-bresenham.git"},"versions":{"0.0.4":{"name":"bresenham","version":"0.0.4","description":"Bresenham's line algorithm","main":"index.js","scripts":{"test":"mocha -R spec -r should test/**/*.js"},"repository":{"type":"git","url":"git+ssh://git@github.com/madbence/node-bresenham.git"},"keywords":["line","bresenham","math"],"author":{"name":"Bence Dányi","email":"madbence@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/madbence/node-bresenham/issues"},"homepage":"https://github.com/madbence/node-bresenham","devDependencies":{"mocha":"^1.18.2","semver":"^5.1.0","should":"^8.1.1"},"gitHead":"9ea42fad151034fba7cf23244cc55532fa8dc6bb","_id":"bresenham@0.0.4","_shasum":"157ff5cb6340b9c54add3b765c50869e8c759193","_from":".","_npmVersion":"2.14.6","_nodeVersion":"4.2.1","_npmUser":{"name":"lennon","email":"madbence@gmail.com"},"dist":{"shasum":"157ff5cb6340b9c54add3b765c50869e8c759193","size":3074,"noattachment":false,"key":"/bresenham/-/bresenham-0.0.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/bresenham/download/bresenham-0.0.4.tgz"},"maintainers":[{"name":"lennon","email":"madbence@gmail.com"}],"directories":{},"publish_time":1452768593999,"_cnpm_publish_time":1452768593999,"_hasShrinkwrap":false},"0.0.3":{"name":"bresenham","version":"0.0.3","description":"Bresenham's line algorithm","main":"index.js","scripts":{"test":"mocha -R spec -r should test/**/*.js"},"repository":{"type":"git","url":"git@github.com:madbence/node-bresenham.git"},"keywords":["line","bresenham","math"],"author":{"name":"Bence Dányi","email":"madbence@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/madbence/node-bresenham/issues"},"homepage":"https://github.com/madbence/node-bresenham","devDependencies":{"should":"^3.3.1","mocha":"^1.18.2"},"_id":"bresenham@0.0.3","_shasum":"abdab9e5b194e27c757cd314d8444314f299877a","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"lennon","email":"madbence@gmail.com"},"maintainers":[{"name":"lennon","email":"madbence@gmail.com"}],"dist":{"shasum":"abdab9e5b194e27c757cd314d8444314f299877a","size":2618,"noattachment":false,"key":"/bresenham/-/bresenham-0.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/bresenham/download/bresenham-0.0.3.tgz"},"directories":{},"publish_time":1402517686988,"_cnpm_publish_time":1402517686988,"_hasShrinkwrap":false},"0.0.2":{"name":"bresenham","version":"0.0.2","description":"Bresenham's line algorithm","main":"index.js","scripts":{"test":"mocha -R spec -r should test/**/*.js"},"repository":{"type":"git","url":"git@github.com:madbence/node-bresenham.git"},"keywords":["line","bresenham","math"],"author":{"name":"Bence Dányi","email":"madbence@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/madbence/node-bresenham/issues"},"homepage":"https://github.com/madbence/node-bresenham","devDependencies":{"should":"^3.3.1","mocha":"^1.18.2"},"_id":"bresenham@0.0.2","_shasum":"91b445508eb27fe8f5eab46def551750b97ad99a","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"lennon","email":"madbence@gmail.com"},"maintainers":[{"name":"lennon","email":"madbence@gmail.com"}],"dist":{"shasum":"91b445508eb27fe8f5eab46def551750b97ad99a","size":2560,"noattachment":false,"key":"/bresenham/-/bresenham-0.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/bresenham/download/bresenham-0.0.2.tgz"},"directories":{},"publish_time":1400674207531,"_cnpm_publish_time":1400674207531,"_hasShrinkwrap":false},"0.0.1":{"name":"bresenham","version":"0.0.1","description":"Bresenham's line algorithm","main":"index.js","scripts":{"test":"mocha -R spec -r should test/**/*.js"},"repository":{"type":"git","url":"git@github.com:madbence/node-bresenham.git"},"keywords":["line","bresenham","math"],"author":{"name":"Bence Dányi","email":"madbence@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/madbence/node-bresenham/issues"},"homepage":"https://github.com/madbence/node-bresenham","devDependencies":{"should":"^3.3.1","mocha":"^1.18.2"},"_id":"bresenham@0.0.1","dist":{"shasum":"6b4bb88e806942f7842b5a4ab54cea43487f0b8e","size":2218,"noattachment":false,"key":"/bresenham/-/bresenham-0.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/bresenham/download/bresenham-0.0.1.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"lennon","email":"madbence@gmail.com"},"maintainers":[{"name":"lennon","email":"madbence@gmail.com"}],"directories":{},"publish_time":1399321814231,"_cnpm_publish_time":1399321814231,"_hasShrinkwrap":false},"0.0.0":{"name":"bresenham","version":"0.0.0","description":"Bresenham's line algorithm","main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"git@github.com:madbence/node-bresenham.git"},"keywords":["line","bresenham","math"],"author":{"name":"Bence Dányi","email":"madbence@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/madbence/node-bresenham/issues"},"homepage":"https://github.com/madbence/node-bresenham","_id":"bresenham@0.0.0","dist":{"shasum":"d6fe1e681fc026b6e7563c79348d38c19a32fcea","size":1938,"noattachment":false,"key":"/bresenham/-/bresenham-0.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/bresenham/download/bresenham-0.0.0.tgz"},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"lennon","email":"madbence@gmail.com"},"maintainers":[{"name":"lennon","email":"madbence@gmail.com"}],"directories":{},"publish_time":1399320925478,"_cnpm_publish_time":1399320925478,"_hasShrinkwrap":false}},"readme":"# node-bresenham [![Build Status](https://travis-ci.org/madbence/node-bresenham.svg?branch=master)](https://travis-ci.org/madbence/node-bresenham)\n\n[Bresenham's line algorithm](http://en.wikipedia.org/wiki/Bresenham%27s_line_algorithm)\nin node. ES6 generators are supported! \\o/\n\n## Install\n\n```\n$ npm install bresenham\n```\n\n## API\n\n#### bresenham(x0, y0, x1, y1[, fn])\n\nCalls `fn` with points between `(x0, y0)` and `(x1, y1)`.\nThe points have integer coordinates.\n\nIf `fn` is omitted, an array of points is returned.\n\nThe algorithm uses no floating point arithmetics,\nso it's considered to be fast. But JS numbers are not\nintegers, so I'm not sure whether this is a faster\napproach than the naive algorithm or not.\n\n## ES6 API\n\nIf you `require('bresenham/generator')`, you can use the generator API.\n\n#### bresenham(x0, y0, x1, y1)\n\nCreates a generator that yields every point between `(x0, y0)` and `(x1, y1)`.\n\n```js\nvar line = bresenham(1, 2, 3, 4);\ndo {\n  var point = line.next().value;\n  // do something\n} while(point);\n```\n\n## License\n\nMIT\n","_attachments":{},"homepage":"https://github.com/madbence/node-bresenham","bugs":{"url":"https://github.com/madbence/node-bresenham/issues"},"license":"MIT"}