diff --git a/public_html/index.php b/public_html/index.php
index 45ee7ad..8e038d5 100644
--- a/public_html/index.php
+++ b/public_html/index.php
@@ -14,10 +14,11 @@
-
-
-
-
+
+
+
+
+
diff --git a/public_html/js/action-script.js b/public_html/js/action-script.js
index 9054b48..116da84 100644
--- a/public_html/js/action-script.js
+++ b/public_html/js/action-script.js
@@ -1,86 +1,61 @@
-/* [0] Initialisation
-=========================================================*/
-/* (1) Elements du DOM */
-var DOM = {
- body: $('body'),
- canvas: $('canvas'),
- imageLoader: $('#image-loader')
-};
+{ /* [0] Initialisation
+ =========================================================*/
-/* (2) dat.GUI initialization */
-var Controller = new dat.GUI();
+ /* (1) Elements du DOM */
+ var DOM = {
+ body: $('body'),
+ canvas: $('canvas'),
+ imageLoader: $('#image-loader')
+ };
-/* (3) Canvas initialisation */
-var _CAN = DOM.canvas;
- _CAN.width = _CAN.height = 1000;
-var _CON = _CAN.getContext('2d');
+ /* (2) dat.GUI initialization */
+ var Controller = new dat.GUI();
-/* (4) Image Loader + Définitions */
-var iL;
+ /* (3) Canvas initialisation */
+ var _CAN = DOM.canvas;
+ _CAN.width = _CAN.height = 1000;
+ var _CON = _CAN.getContext('2d');
-var process;
-var exec = false;
-var last;
+ /* (4) Image Loader + Définitions */
+ var iL;
+
+ var filterManager;
+ var process;
+ var exec = false;
+ var last;
+
+}
-
-/* [1] Initialisation
-=========================================================*/
-var init = function(){
- /* (1) Image par défaut */
- this.src = 'front:male:1.jpg';
-
- /* (2) Attachement de dat.GUI */
- Controller.addFolder('image source');
- Controller.add(this, 'src', this._images).listen();
-
- last = this.src;
-};
+{ /* [1] Initialisation du process
+ =========================================================*/
+ var init = function(){
+ /* (1) Image par défaut */
+ this.src = 'front:male:1.jpg';
-/* (x) Variables globales
----------------------------------------------------------*/
-/* (1) Gestion du ration de l'image */
-var pixelRatio = {
+ /* (2) Attachement de dat.GUI */
+ Controller.addFolder('image source');
+ Controller.add(this, 'src', this._images).listen();
- initialized: false,
+ last = this.src;
+ };
- init: function(){
- if( this.initialized )
- return;
+ /* (2) Gestion de tracking.js */
+ var zones;
- this.initialized = true;
+ /* (3) Gestion du track de l'image */
+ var track = {update: true};
+ var tracker = new tracking.ObjectTracker(['face', 'eye', 'mouth']);
+ tracker.setStepSize(1.5);
- this._w = this._h = 0.9;
- this.width = this.height = null;
+ Controller.addFolder('Tracking.js');
+ Controller.add(track, 'update');
- this.__defineGetter__('width', function(){ return this._w; });
- this.__defineGetter__('height', function(){ return this._h; });
+}
- this.__defineSetter__('width', function(v){ this._w = v; process.bind(iL._wrapper)(); });
- this.__defineSetter__('height', function(v){ this._h = v; process.bind(iL._wrapper)(); });
-
-
- Controller.addFolder('Image Ratio');
- Controller.add(this, 'width', 0, 2).listen();
- Controller.add(this, 'height', 0, 2).listen();
- }
-
-};
-
-/* (2) Gestion de tracking.js */
-var zones;
-
-/* (3) Gestion du track de l'image */
-var track = {update: true};
-var tracker = new tracking.ObjectTracker(['face', 'eye', 'mouth']);
-
-tracker.setStepSize(1.5);
-
-Controller.addFolder('Tracking.js');
-Controller.add(track, 'update');
/* [2] Routine principale
=========================================================*/
@@ -110,8 +85,7 @@ process = function(){
this.defaultHeight = this.height;
log('Image copied', '[Canvas]');
-
- /* (2) Si `track.update` est TRUE, on lance `Tracking.js`
+ /* (3) Si `track.update` est TRUE, on lance `Tracking.js`
---------------------------------------------------------*/
if( track.update ){
@@ -147,19 +121,20 @@ process = function(){
{ /* [2] Copie sur le `