Function

CGColorSpaceCreatePattern

Creates a pattern color space.

Declaration

CGColorSpaceRef CGColorSpaceCreatePattern(CGColorSpaceRef baseSpace);

Parameters

baseSpace

For masking patterns, the underlying color space that specifies the colors to be painted through the mask. For colored patterns, you should pass NULL.

Return Value

A new pattern color space. You are responsible for releasing this object by calling CGColorSpaceRelease. If unsuccessful, returns NULL.

Discussion

For information on creating and using patterns, see Quartz 2D Programming Guide and CGPattern. Quartz retains the color space you pass in. Upon return, you may safely release it by calling CGColorSpaceRelease.

See Also

Creating Special Color Spaces

CGColorSpaceCreateIndexed

Creates an indexed color space, consisting of colors specified by a color lookup table.

CGColorSpaceCreateWithName

Creates a specified type of Quartz color space.