Class Tuning


  • public final class Tuning
    extends java.lang.Object
    The Tuning class contains tuning hints that help the image processing system decide between multiple algorithms when performing certain operations. A default tuning profile is built in, but more accurate tuning values can be determined for a particular platform by calling update(int, boolean). This should only be done when no image processing is currently taking place. Tuning profiles can be read to and from a file to avoid having to call update for each application run.
    Since:
    3.0
    Author:
    Chris Jennings
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void main​(java.lang.String[] args)  
      static void read​(java.util.Properties p)
      Sets the tuning parameters using previously written properties.
      static void update​(int accuracy, boolean printResults)
      Updates the tuning parameters with platform-specific data by running a sequence of test operations.
      static void write​(java.util.Properties p)
      Copies the tuning parameter values into a set of Properties.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • SET_INT_ARGB

        public static float SET_INT_ARGB
      • SET_INT_RGB

        public static float SET_INT_RGB
      • SET_INT_OTHER

        public static float SET_INT_OTHER
      • GET_INT_ARGB

        public static float GET_INT_ARGB
      • GET_INT_RGB

        public static float GET_INT_RGB
      • GET_INT_OTHER

        public static float GET_INT_OTHER
      • PER_ROW

        public static float PER_ROW
      • PER_IMAGE

        public static float PER_IMAGE
      • GROW_ROWS

        public static float GROW_ROWS
      • PREMUL

        public static float PREMUL
      • FLIP

        public static float FLIP
    • Method Detail

      • write

        public static void write​(java.util.Properties p)
        Copies the tuning parameter values into a set of Properties. Tuning parameters will be added using a key consisting of "IMGOP_ACCEL_" followed by the tuning parameter name. This can be used to save the tuning parameters instead of running update
        Parameters:
        p - the properties instance to add the tuning parameters to
      • read

        public static void read​(java.util.Properties p)
        Sets the tuning parameters using previously written properties.
        Parameters:
        p - the properties instance to read the turning parameters from
      • update

        public static void update​(int accuracy,
                                  boolean printResults)
        Updates the tuning parameters with platform-specific data by running a sequence of test operations. The accuracy parameter allows you to trade speed for accuracy. Lower values will allow the tests to complete more quickly and use fewer resources. Higher values will obtain more accurate results.
        Parameters:
        accuracy - a value from 1-9, with higher values requested progressively more accurate results
        printResults - if true the results will be printed to System.err as they are generated.
      • main

        public static void main​(java.lang.String[] args)