Skip to content

Most visited

Recently visited

navigation
Added in API level 1

ColorMatrixColorFilter

public class ColorMatrixColorFilter
extends ColorFilter

java.lang.Object
   ↳ android.graphics.ColorFilter
     ↳ android.graphics.ColorMatrixColorFilter


A color filter that transforms colors through a 4x5 color matrix. This filter can be used to change the saturation of pixels, convert from YUV to RGB, etc.

See also:

Summary

Public constructors

ColorMatrixColorFilter(ColorMatrix matrix)

Create a color filter that transforms colors through a 4x5 color matrix.

ColorMatrixColorFilter(float[] array)

Create a color filter that transforms colors through a 4x5 color matrix.

Inherited methods

From class android.graphics.ColorFilter
From class java.lang.Object

Public constructors

ColorMatrixColorFilter

Added in API level 1
ColorMatrixColorFilter (ColorMatrix matrix)

Create a color filter that transforms colors through a 4x5 color matrix.

Parameters
matrix ColorMatrix: 4x5 matrix used to transform colors. It is copied into the filter, so changes made to the matrix after the filter is constructed will not be reflected in the filter.

ColorMatrixColorFilter

Added in API level 1
ColorMatrixColorFilter (float[] array)

Create a color filter that transforms colors through a 4x5 color matrix.

Parameters
array float: Array of floats used to transform colors, treated as a 4x5 matrix. The first 20 entries of the array are copied into the filter. See ColorMatrix.
This site uses cookies to store your preferences for site-specific language and display options.

Hooray!

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.