# tracking.js Change the way you interact with your browser. ## Getting Started Import the core library: ``` html ``` Import the color module: ``` html ``` Gets the user's camera: ``` javascript var videoCamera = new tracking.VideoCamera().render(); ``` Instantiates tracking by color magenta and displays X, Y and Z positions of the detected area in console: ``` javascript videoCamera.track({ type: 'color', color: 'magenta', onFound: function(track) { console.log(track.x, track.y, track.z); }, onNotFound: function() {} }); ``` [Check the full code of this Hello World example.](https://github.com/eduardolundgren/tracking.js/blob/master/examples/hello_world.html) > **Note:** if you want to run tracking.js examples locally, you're going to need a local server, since `file:///` doesn't work with `getUserMedia()` in some browsers. > 1. Install Grunt and its dependencies: `npm install .` > 2. Run a local server: `grunt server` > 3. Go to: `http://localhost:9001` and have fun :) ## Structure * *tracking.js* : Library's core; * *color.js* : Module for color tracking; * *human.js* : Module for human tracking. ## Methods There are some handy chainable methods that you can use to achieve your goal, for example: * **tracking.VideoCamera()** Requests user's camera using WebRTC's `getUserMedia()`. * **tracking.VideoCamera().render()** Shows user's camera using a `