Inherits from SPPoolObject : NSObject
Conforms to NSCopying
Declared in SPColorMatrix.h

Tasks

Initialization

Methods

  • – invert

    Inverts the colors.

  • – adjustSaturation:

    Changes the saturation. Typical values are in the range [-1, 1]. Values above zero will raise, values below zero will reduce the saturation. ‘-1’ will produce a grayscale image.

  • – adjustContrast:

    Changes the contrast. Typical values are in the range [-1, 1]. Values above zero will raise, values below zero will reduce the contrast.

  • – adjustBrightness:

    Changes the brightness. Typical values are in the range [-1, 1]. Values above zero will make the image brighter, values below zero will make it darker.

  • – adjustHue:

    Changes the hue. Typical values are in the range [-1, 1].

  • – identity

    Changes the color matrix into an identity matrix.

  • – concatColorMatrix:

    Concatenates the receiving color matrix with another one.

Properties

  •   values

    Returns a point to the internal color matrix array.

    property
  •   numValues

    Returns the count of values (always 20).

    property

Properties

numValues

Returns the count of values (always 20).

@property (nonatomic, readonly) int numValues

Discussion

Returns the count of values (always 20).

Declared In

SPColorMatrix.h

values

Returns a point to the internal color matrix array.

@property (nonatomic, readonly) float *values

Discussion

Returns a point to the internal color matrix array.

Declared In

SPColorMatrix.h

Class Methods

colorMatrixWithIdentity

Factory method.

+ (instancetype)colorMatrixWithIdentity

Discussion

Factory method.

Declared In

SPColorMatrix.h

colorMatrixWithValues:

Factory method.

+ (instancetype)colorMatrixWithValues:(const float [ 20 ])values

Discussion

Factory method.

Declared In

SPColorMatrix.h

Instance Methods

adjustBrightness:

Changes the brightness. Typical values are in the range [-1, 1]. Values above zero will make the image brighter, values below zero will make it darker.

- (void)adjustBrightness:(float)brightness

Discussion

Changes the brightness. Typical values are in the range [-1, 1]. Values above zero will make the image brighter, values below zero will make it darker.

Declared In

SPColorMatrix.h

adjustContrast:

Changes the contrast. Typical values are in the range [-1, 1]. Values above zero will raise, values below zero will reduce the contrast.

- (void)adjustContrast:(float)contrast

Discussion

Changes the contrast. Typical values are in the range [-1, 1]. Values above zero will raise, values below zero will reduce the contrast.

Declared In

SPColorMatrix.h

adjustHue:

Changes the hue. Typical values are in the range [-1, 1].

- (void)adjustHue:(float)hue

Discussion

Changes the hue. Typical values are in the range [-1, 1].

Declared In

SPColorMatrix.h

adjustSaturation:

Changes the saturation. Typical values are in the range [-1, 1]. Values above zero will raise, values below zero will reduce the saturation. ‘-1’ will produce a grayscale image.

- (void)adjustSaturation:(float)saturation

Discussion

Changes the saturation. Typical values are in the range [-1, 1]. Values above zero will raise, values below zero will reduce the saturation. ‘-1’ will produce a grayscale image.

Declared In

SPColorMatrix.h

concatColorMatrix:

Concatenates the receiving color matrix with another one.

- (void)concatColorMatrix:(SPColorMatrix *)colorMatrix

Discussion

Concatenates the receiving color matrix with another one.

Declared In

SPColorMatrix.h

identity

Changes the color matrix into an identity matrix.

- (void)identity

Discussion

Changes the color matrix into an identity matrix.

Declared In

SPColorMatrix.h

init

Initializes an identity matrix.

- (instancetype)init

Discussion

Initializes an identity matrix.

Declared In

SPColorMatrix.h

initWithValues:

Initializes a color matrix with an array of 20 floats. Designated Initializer.

- (instancetype)initWithValues:(const float [ 20 ])values

Discussion

Initializes a color matrix with an array of 20 floats. Designated Initializer.

Declared In

SPColorMatrix.h

invert

Inverts the colors.

- (void)invert

Discussion

Inverts the colors.

Declared In

SPColorMatrix.h