Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(572)

Unified Diff: chrome/test/data/third_party/kraken/tests/kraken-1.1/imaging-desaturate.js

Issue 11348021: Automate Kraken benchmark with Chrome Remote Control. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/third_party/kraken/tests/kraken-1.1/imaging-desaturate.js
diff --git a/chrome/test/data/third_party/kraken/tests/kraken-1.1/imaging-desaturate.js b/chrome/test/data/third_party/kraken/tests/kraken-1.1/imaging-desaturate.js
deleted file mode 100644
index 503f9cf2b95af87680ff9a59fbba0e307f14e01b..0000000000000000000000000000000000000000
--- a/chrome/test/data/third_party/kraken/tests/kraken-1.1/imaging-desaturate.js
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Pixastic Lib - Desaturation filter - v0.1.1
- * Copyright (c) 2008 Jacob Seidelin, jseidelin@nihilogic.dk, http://blog.nihilogic.dk/
- * License: [http://www.pixastic.com/lib/license.txt] (MPL 1.1)
- */
-
-var Pixastic = {};
-Pixastic.Actions = {};
-Pixastic.Actions.desaturate = {
- process : function(params) {
- var useAverage = !!(params.options.average && params.options.average != "false");
- var data = params.data;
- var rect = params.options.rect;
- var w = rect.width;
- var h = rect.height;
-
- var p = w*h;
- var pix = p*4, pix1, pix2;
-
- if (useAverage) {
- while (p--)
- data[pix-=4] = data[pix1=pix+1] = data[pix2=pix+2] = (data[pix]+data[pix1]+data[pix2])/3
- } else {
- while (p--)
- data[pix-=4] = data[pix1=pix+1] = data[pix2=pix+2] = (data[pix]*0.3 + data[pix1]*0.59 + data[pix2]*0.11);
- }
- return true;
- }
-}
-
-var params = {
- options: {
- rect: { width: width, height: height},
- },
- data: squidImageData
-}
-
-//XXX improve dataset rather than loop
-for (var pixcounter = 0; pixcounter < 200; pixcounter++)
- Pixastic.Actions.desaturate.process(params);

Powered by Google App Engine
This is Rietveld 408576698