From dfda7e31d19ed93e99b8fa618e9eb06cf5e1d2b1 Mon Sep 17 00:00:00 2001
From: Bilasco Ioan Marius <marius.bilasco@univ-lille1.fr>
Date: Mon, 5 Feb 2018 04:49:23 +0100
Subject: [PATCH] ajout gitignore

---
 .gitignore         |  3 ++-
 features/pixels.js | 19 +++++++++++++++++++
 2 files changed, 21 insertions(+), 1 deletion(-)
 create mode 100644 features/pixels.js

diff --git a/.gitignore b/.gitignore
index 78b753f..1f5c3d2 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
-**/sol**
+**/sol**.js
+**/sol**.html
diff --git a/features/pixels.js b/features/pixels.js
new file mode 100644
index 0000000..755c8f1
--- /dev/null
+++ b/features/pixels.js
@@ -0,0 +1,19 @@
+GetPixelRGBATask=function(opt_options) {
+  this.x=opt_options.x;
+  this.y=opt_options.y;
+  this.output=opt_options.output;
+}
+
+GetPixelRGBATask.prototype.process=function(imageData) {
+  var pos=(this.y*imageData.width+this.x)<<2;
+  var r=imageData.data[pos];
+  var g=imageData.data[pos+1];
+  var b=imageData.data[pos+2];
+  var a=imageData.data[pos+3];
+
+  this.output.innerHTML=this.x+"x"+this.y+" : ";
+  this.output.innerHTML+="<font color='red'>"+r+"</font> | ";
+  this.output.innerHTML+="<font color='green'>"+g+"</font> | ";
+  this.output.innerHTML+="<font color='blue'>"+b+"</font> | ";
+  this.output.innerHTML+="<font color='gray'>"+a+"</font>";
+}
-- 
GitLab