1 /** 2 * 3 */ 4 package de.desy.acop.video.analysis; 5 6 /** 7 * </code>ColorDecoder</code> interface provides a means of transforming the 8 * </code>TYPE_INT_ARGB</code> integer color code into a meaningful double value. 9 * 10 * @author Tilen Kusterle, Cosylab 11 * 12 */ 13 public interface ColorDecoder { 14 15 /** 16 * Transforms the </code>TYPE_INT_ARGB</code> integer color code into a 17 * meaningful double value. 18 * @param code the </code>TYPE_INT_ARGB</code> integer color code 19 * @return a meaningful double value 20 * @deprecated use {@link #transform(int[])} to transform the whole array at once 21 */ 22 @Deprecated 23 public double transform(int code); 24 25 /** 26 * Transforms the complete array of </code>TYPE_INT_ARGB</code> integer 27 * colors codes into meaningful double value array. Use this method with large 28 * arrays in order to avoid calling {@link #transform(int)} many times, which 29 * might be costly. 30 * 31 * @param data the data to transform 32 * @return the transformed values 33 */ 34 public double[] transform(int[] data); 35 36 /* 37 * TODO: add method for min and max, so treshold can be defined in %. 38 */ 39 }