├── .bowerrc ├── .editorconfig ├── .gitignore ├── .jshintrc ├── .travis.yml ├── LICENSE.md ├── README.md ├── assets ├── opencv_haarcascade_converter.html ├── opencv_haarcascade_eye.js ├── opencv_haarcascade_frontalface_alt.js ├── opencv_haarcascade_mouth.js └── opencv_haarcascade_upper_body.js ├── bower.json ├── build ├── data │ ├── eye-min.js │ ├── eye.js │ ├── face-min.js │ ├── face.js │ ├── mouth-min.js │ └── mouth.js ├── tracking-min.js └── tracking.js ├── examples ├── assets │ ├── book1.png │ ├── book2.png │ ├── box1.png │ ├── box2.png │ ├── brief1.png │ ├── brief2.png │ ├── color_camera_gui.js │ ├── demo.css │ ├── draw_frame.png │ ├── faces.jpg │ ├── fast.png │ ├── fish_tank │ │ ├── FishTankRenderer.js │ │ ├── nx.png │ │ ├── ny.png │ │ ├── nz.png │ │ ├── px.png │ │ ├── py.png │ │ └── pz.png │ ├── frame.png │ ├── minions.mp4 │ ├── minions.ogv │ ├── psmove.png │ ├── splines.min.js │ └── stats.min.js ├── brief.html ├── brief_camera.html ├── color_camera.html ├── color_draw_something.html ├── color_fish_tank.html ├── color_hello_world.html ├── color_video.html ├── face_camera.html ├── face_fish_tank.html ├── face_hello_world.html ├── face_tag_friends.html ├── fast.html └── fast_camera.html ├── gulpfile.js ├── package.json ├── src ├── detection │ ├── ViolaJones.js │ └── training │ │ └── haar │ │ ├── eye.js │ │ ├── face.js │ │ └── mouth.js ├── features │ ├── Brief.js │ └── Fast.js ├── math │ ├── Math.js │ └── Matrix.js ├── pose │ └── EPnP.js ├── trackers │ ├── ColorTracker.js │ ├── ObjectTracker.js │ ├── Tracker.js │ └── TrackerTask.js ├── tracking.js └── utils │ ├── Canvas.js │ ├── DisjointSet.js │ ├── EventEmitter.js │ └── Image.js └── test ├── Benchmark.js ├── Brief.js ├── ColorTracker.js ├── Fast.js ├── ObjectTracker.js ├── assets ├── box1.png ├── box2.png ├── faces.png └── psmove.png ├── perf ├── Brief.js ├── ColorTracker.js ├── Fast.js └── ObjectTracker.js └── utils ├── benchmark.js └── sandbox.js /.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "../" 3 | } 4 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = tab 6 | end_of_line = lf 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | insert_final_newline = true 10 | indent_style = space 11 | indent_size = 2 12 | 13 | [*.md] 14 | trim_trailing_whitespace = false 15 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | test/assets/benchmark.json 4 | -------------------------------------------------------------------------------- /.jshintrc: -------------------------------------------------------------------------------- 1 | { 2 | "asi": false, 3 | "bitwise": false, 4 | "curly": true, 5 | "eqeqeq": true, 6 | "esnext": true, 7 | "evil": false, 8 | "forin": false, 9 | "globals": { 10 | "document": true, 11 | "navigator": true, 12 | "tracking": true, 13 | "window": true 14 | }, 15 | "immed": true, 16 | "indent": 2, 17 | "lastsemic": false, 18 | "maxdepth": false, 19 | "multistr": false, 20 | "newcap": true, 21 | "noarg": true, 22 | "node": true, 23 | "onevar": false, 24 | "quotmark": "single", 25 | "regexp": true, 26 | "smarttabs": true, 27 | "trailing": true, 28 | "undef": true, 29 | "unused": true 30 | } 31 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - "0.11" 4 | - "0.10" 5 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | Software License Agreement (BSD License) 2 | 3 | Copyright (c) 2014, Eduardo A. Lundgren Melo. 4 | All rights reserved. 5 | 6 | Redistribution and use of this software in source and binary forms, with or without modification, are 7 | permitted provided that the following conditions are met: 8 | 9 | * Redistributions of source code must retain the above 10 | copyright notice, this list of conditions and the 11 | following disclaimer. 12 | 13 | * Redistributions in binary form must reproduce the above 14 | copyright notice, this list of conditions and the 15 | following disclaimer in the documentation and/or other 16 | materials provided with the distribution. 17 | 18 | * The name of Eduardo A. Lundgren Melo may not be used to endorse or promote products 19 | derived from this software without specific prior 20 | written permission of Eduardo A. Lundgren Melo. 21 | 22 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED 23 | WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A 24 | PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 25 | ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 26 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 27 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR 28 | TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 29 | ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | 31 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # tracking.js 2 | 3 | [![Build Status](http://img.shields.io/travis/eduardolundgren/tracking.js.svg?style=flat)](https://travis-ci.org/eduardolundgren/tracking.js) 4 | [![DevDependencies Status](http://img.shields.io/david/dev/eduardolundgren/tracking.js.svg?style=flat)](https://david-dm.org/eduardolundgren/tracking.js#info=devDependencies) 5 | 6 | The tracking.js library brings different computer vision algorithms and techniques into the browser environment. By using modern HTML5 specifications, we enable you to do real-time color tracking, face detection and much more — all that with a lightweight core (~7 KB) and intuitive interface. 7 | 8 | * [Official website](http://trackingjs.com) 9 | * [Documentation](http://trackingjs.com/docs.html) 10 | * [API Docs](http://trackingjs.com/api/) 11 | 12 | ## Install 13 | 14 | Install via [Bower](http://bower.io/), [npm](https://www.npmjs.com/), or [download as a zip](https://github.com/eduardolundgren/tracking.js/archive/master.zip): 15 | 16 | ``` 17 | bower install tracking 18 | ``` 19 | 20 | ``` 21 | npm install tracking 22 | ``` 23 | 24 | ## Examples 25 | 26 | [![Demo 1](https://cloud.githubusercontent.com/assets/398893/3709347/ec72876c-1453-11e4-8450-149d06d487f2.jpg)](http://trackingjs.com/examples/face_tag_friends.html) 27 | [![Demo 2](https://cloud.githubusercontent.com/assets/398893/3709357/1a1c2e16-1454-11e4-804d-e6ada6c65997.jpg)](http://trackingjs.com/examples/face_fish_tank.html) 28 | [![Demo 3](https://cloud.githubusercontent.com/assets/398893/3709361/38f86e8a-1454-11e4-811d-52bd21b37e85.jpg)](http://trackingjs.com/examples/color_hexgl.html) 29 | [![Demo 4](https://cloud.githubusercontent.com/assets/398893/3709464/5447a302-1456-11e4-96b2-d2fae28e2a01.jpg)](http://trackingjs.com/examples/color_draw_something.html) 30 | [![Demo 5](https://cloud.githubusercontent.com/assets/398893/3709469/6a3e859a-1456-11e4-982a-d46a55890e1e.jpg)](http://trackingjs.com/examples/color_fish_tank.html) 31 | 32 | ## Features 33 | 34 | * [Trackers](http://trackingjs.com/docs.html#trackers) 35 | * [Color Tracker](http://trackingjs.com/docs.html#color-tracker) 36 | * [Object Tracker](http://trackingjs.com/docs.html#object-tracker) 37 | * [Utilities](http://trackingjs.com/docs.html#utilities) 38 | * [Feature Detection (Fast)](http://trackingjs.com/docs.html#feature-detection) 39 | * [Feature Descriptor (Brief)](http://trackingjs.com/docs.html#feature-descriptor) 40 | * [Convolution](http://trackingjs.com/docs.html#convolution) 41 | * [Gray Scale](http://trackingjs.com/docs.html#gray-scale) 42 | * [Image Blur](http://trackingjs.com/docs.html#image-blur) 43 | * [Integral Image](http://trackingjs.com/docs.html#integral-image) 44 | * [Sobel](http://trackingjs.com/docs.html#sobel) 45 | * [Viola Jones](http://trackingjs.com/docs.html#viola-jones) 46 | * [Web Components](http://trackingjs.com/docs.html#web-components) 47 | * [Color Element](http://trackingjs.com/docs.html#color-element) 48 | * [Object Element](http://trackingjs.com/docs.html#object-element) 49 | 50 | ## Browser Support 51 | 52 | You can plug *tracking.js* into some well supported HTML elements such as ``, `