Instance Method


Produces a CIImage object by applying a kernel function.


- (CIImage *)apply:(CIKernel *)k, ...;



A CIKernel object that contains a kernel function.


A list of arguments to supply to the kernel function. The supplied arguments must be type-compatible with the function signature of the kernel function. The list of arguments must be terminated by the nil object.


If you are implementing a custom filter, this method needs to be called from within the outputImage method in order to apply your kernel function to the CIImage object. For example, if the kernel function has this signature:

kernel vec4 brightenEffect (sampler src, float k)

You would supply two arguments after the k argument to the apply:k, .. method. In this case, the first argument must be a sampler and the second a floating-point value. For more information on kernels, see Core Image Kernel Language Reference.

See Also

Applying a Filter

- apply:arguments:options:

Produces a CIImage object by applying arguments to a kernel function and using options to control how the kernel function is evaluated.