Package icyllis.arc3d.core.effects

# Class ColorMatrixColorFilter

java.lang.Object
icyllis.arc3d.core.effects.ColorMatrixColorFilter

All Implemented Interfaces:
  `ColorFilter`, `RefCounted`

public final class ColorMatrixColorFilter extends Object implements ColorFilter

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ColorMatrixColorFilter(float[] matrix)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `filterColor4f(float[] col, float[] out, ColorSpace dstCS)`
  Applies this color filter with RGBA colors.
  `float[]`
  `getMatrix()`
  `boolean`
  `isAlphaUnchanged()`
  Returns the flags for this filter.
  `static ColorFilter`
  `make(float[] matrix)`
  `void`
  `ref()`
  Increases the reference count by 1.
  `void`
  `unref()`
  Decreases the reference count by 1.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface icyllis.arc3d.core.effects.ColorFilter

  `andThen, compose, filterColor`

- ## Constructor Details

  - ### ColorMatrixColorFilter

    public ColorMatrixColorFilter(@Size(20L) float[] matrix)

- ## Method Details

  - ### make

    @Nullable public static ColorFilter make(@Size(20L) float[] matrix)

  - ### getMatrix

    public float[] getMatrix()

  - ### isAlphaUnchanged

    public boolean isAlphaUnchanged()
    Description copied from interface: `ColorFilter`
    Returns the flags for this filter. Override in subclasses to return custom flags.
    Specified by:
      `isAlphaUnchanged` in interface `ColorFilter`

  - ### filterColor4f

    public void filterColor4f(float[] col, float[] out, ColorSpace dstCS)
    Description copied from interface: `ColorFilter`
    Applies this color filter with RGBA colors. col and out store premultiplied R,G,B,A components from index 0 to 3. col and out can be the same pointer. col is read-only, out may be written multiple times.
    Specified by:
      `filterColor4f` in interface `ColorFilter`
    Parameters:
      `col` - base color
      `out` - resulting color
      `dstCS` - destination color space

  - ### ref

    public void ref()
    Description copied from interface: `RefCounted`
    Increases the reference count by 1.
    Specified by:
      `ref` in interface `RefCounted`

  - ### unref

    public void unref()
    Description copied from interface: `RefCounted`
    Decreases the reference count by 1.
    Specified by:
      `unref` in interface `RefCounted`