Package toxi.color

Class ToneMap

java.lang.Object
toxi.color.ToneMap

public class ToneMap extends Object
  • Field Details

  • Constructor Details

  • Method Details

    • getARGBToneFor

      public final int getARGBToneFor(float t)
    • getToneFor

      public final ReadonlyTColor getToneFor(float t)
    • getToneMappedArray

      public int[] getToneMappedArray(float[] src, int[] pixels)
      Applies the tonemap to all elements in the given source array of single precision values and places the resulting ARGB color in the corresponding index of the target pixel buffer. If the target buffer is null, a new one will be created automatically.
      Parameters:
      src - source array of values to be tone mapped
      pixels - target pixel buffer
      Returns:
      pixel array
    • getToneMappedArray

      public int[] getToneMappedArray(float[] src, int[] pixels, int offset)
    • getToneMappedArray

      public int[] getToneMappedArray(int[] src, int[] pixels)
      Applies the tonemap to all elements in the given source array of integers and places the resulting ARGB color in the corresponding index of the target pixel buffer. If the target buffer is null, a new one will be created automatically.
      Parameters:
      src - source array of values to be tone mapped
      pixels - target pixel buffer
      Returns:
      pixel array
    • getToneMappedArray

      public int[] getToneMappedArray(int[] src, int[] pixels, int offset)
    • setMapFunction

      public void setMapFunction(InterpolateStrategy func)
      Sets the interpolation function for the underlying ScaleMap instance of this ToneMap.
      Parameters:
      func -
      See Also: