1 7 8 package java.awt.image; 9 10 11 29 public abstract class LookupTable extends Object { 30 31 34 35 int numComponents; 36 int offset; 37 int numEntries; 38 39 49 protected LookupTable(int offset, int numComponents) { 50 if (offset < 0) { 51 throw new 52 IllegalArgumentException ("Offset must be greater than 0"); 53 } 54 if (numComponents < 1) { 55 throw new IllegalArgumentException ("Number of components must "+ 56 " be at least 1"); 57 } 58 this.numComponents = numComponents; 59 this.offset = offset; 60 } 61 62 66 public int getNumComponents() { 67 return numComponents; 68 } 69 70 74 public int getOffset() { 75 return offset; 76 } 77 78 90 public abstract int[] lookupPixel(int[] src, int[] dest); 91 92 } 93 | Popular Tags |