Merge branch 'master' of https://source.jalview.org/git/jalviewjs.git
[jalviewjs.git] / site / j2s / java / awt / image / ByteLookupTable.js
index df2e444..948e9a0 100644 (file)
@@ -1,69 +1,69 @@
-Clazz.declarePackage ("java.awt.image");\r
-Clazz.load (["java.awt.image.LookupTable"], "java.awt.image.ByteLookupTable", ["java.lang.ArrayIndexOutOfBoundsException"], function () {\r
-c$ = Clazz.decorateAsClass (function () {\r
-this.data = null;\r
-Clazz.instantialize (this, arguments);\r
-}, java.awt.image, "ByteLookupTable", java.awt.image.LookupTable);\r
-Clazz.makeConstructor (c$, \r
-function (offset, data) {\r
-Clazz.superConstructor (this, java.awt.image.ByteLookupTable, [offset, data.length]);\r
-this.numComponents = data.length;\r
-this.numEntries = data[0].length;\r
-this.data =  Clazz.newByteArray (this.numComponents, 0);\r
-for (var i = 0; i < this.numComponents; i++) {\r
-this.data[i] = data[i];\r
-}\r
-}, "~N,~A");\r
-Clazz.makeConstructor (c$, \r
-function (offset, data) {\r
-Clazz.superConstructor (this, java.awt.image.ByteLookupTable, [offset, data.length]);\r
-this.numComponents = 1;\r
-this.numEntries = data.length;\r
-this.data =  Clazz.newByteArray (1, 0);\r
-this.data[0] = data;\r
-}, "~N,~A");\r
-Clazz.defineMethod (c$, "getTable", \r
-function () {\r
-return this.data;\r
-});\r
-Clazz.defineMethod (c$, "lookupPixel", \r
-function (src, dst) {\r
-if (dst == null) {\r
-dst =  Clazz.newIntArray (src.length, 0);\r
-}if (this.numComponents == 1) {\r
-for (var i = 0; i < src.length; i++) {\r
-var s = src[i] - this.offset;\r
-if (s < 0) {\r
-throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");\r
-}dst[i] = this.data[0][s];\r
-}\r
-} else {\r
-for (var i = 0; i < src.length; i++) {\r
-var s = src[i] - this.offset;\r
-if (s < 0) {\r
-throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");\r
-}dst[i] = this.data[i][s];\r
-}\r
-}return dst;\r
-}, "~A,~A");\r
-Clazz.defineMethod (c$, "lookupPixel", \r
-function (src, dst) {\r
-if (dst == null) {\r
-dst =  Clazz.newByteArray (src.length, 0);\r
-}if (this.numComponents == 1) {\r
-for (var i = 0; i < src.length; i++) {\r
-var s = (src[i] & 0xff) - this.offset;\r
-if (s < 0) {\r
-throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");\r
-}dst[i] = this.data[0][s];\r
-}\r
-} else {\r
-for (var i = 0; i < src.length; i++) {\r
-var s = (src[i] & 0xff) - this.offset;\r
-if (s < 0) {\r
-throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");\r
-}dst[i] = this.data[i][s];\r
-}\r
-}return dst;\r
-}, "~A,~A");\r
-});\r
+Clazz.declarePackage ("java.awt.image");
+Clazz.load (["java.awt.image.LookupTable"], "java.awt.image.ByteLookupTable", ["java.lang.ArrayIndexOutOfBoundsException"], function () {
+c$ = Clazz.decorateAsClass (function () {
+this.data = null;
+Clazz.instantialize (this, arguments);
+}, java.awt.image, "ByteLookupTable", java.awt.image.LookupTable);
+Clazz.makeConstructor (c$, 
+function (offset, data) {
+Clazz.superConstructor (this, java.awt.image.ByteLookupTable, [offset, data.length]);
+this.numComponents = data.length;
+this.numEntries = data[0].length;
+this.data =  Clazz.newByteArray (this.numComponents, 0);
+for (var i = 0; i < this.numComponents; i++) {
+this.data[i] = data[i];
+}
+}, "~N,~A");
+Clazz.makeConstructor (c$, 
+function (offset, data) {
+Clazz.superConstructor (this, java.awt.image.ByteLookupTable, [offset, data.length]);
+this.numComponents = 1;
+this.numEntries = data.length;
+this.data =  Clazz.newByteArray (1, 0);
+this.data[0] = data;
+}, "~N,~A");
+Clazz.defineMethod (c$, "getTable", 
+function () {
+return this.data;
+});
+Clazz.defineMethod (c$, "lookupPixel", 
+function (src, dst) {
+if (dst == null) {
+dst =  Clazz.newIntArray (src.length, 0);
+}if (this.numComponents == 1) {
+for (var i = 0; i < src.length; i++) {
+var s = src[i] - this.offset;
+if (s < 0) {
+throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");
+}dst[i] = this.data[0][s];
+}
+} else {
+for (var i = 0; i < src.length; i++) {
+var s = src[i] - this.offset;
+if (s < 0) {
+throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");
+}dst[i] = this.data[i][s];
+}
+}return dst;
+}, "~A,~A");
+Clazz.defineMethod (c$, "lookupPixel", 
+function (src, dst) {
+if (dst == null) {
+dst =  Clazz.newByteArray (src.length, 0);
+}if (this.numComponents == 1) {
+for (var i = 0; i < src.length; i++) {
+var s = (src[i] & 0xff) - this.offset;
+if (s < 0) {
+throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");
+}dst[i] = this.data[0][s];
+}
+} else {
+for (var i = 0; i < src.length; i++) {
+var s = (src[i] & 0xff) - this.offset;
+if (s < 0) {
+throw  new ArrayIndexOutOfBoundsException ("src[" + i + "]-offset is " + "less than zero");
+}dst[i] = this.data[i][s];
+}
+}return dst;
+}, "~A,~A");
+});