... | ... | @@ -10,25 +10,6 @@ To get a list of all the available CoreImage filters: |
|
|
|
|
|
smig getproperty -type imagefilterchain -property imagefilters
|
|
|
|
|
|
To get the list of filters that belong to particular category:
|
|
|
|
|
|
smig getproperty -type imagefilterchain -property imagefilters -filtercategory CICategoryDistortionEffect
|
|
|
|
|
|
All the filters belong to more than one category. The list of categories, [from Apple's documentation are](https://developer.apple.com/library/mac/documentation/GraphicsImaging/Conceptual/CoreImaging/ci_concepts/ci_concepts.html):
|
|
|
|
|
|
CICategoryBlur
|
|
|
CICategoryColorAdjustment
|
|
|
CICategoryCompositeOperation
|
|
|
CICategoryDistortionEffect
|
|
|
CICategoryGenerator
|
|
|
CICategoryGeometryAdjustment
|
|
|
CICategoryGradient
|
|
|
CICategoryHalftoneEffect
|
|
|
CICategorySharpen
|
|
|
CICategoryStylyize
|
|
|
CICategoryTileEffect
|
|
|
CICategoryTransition
|
|
|
|
|
|
### Getting the attributes of a CoreImage filter
|
|
|
|
|
|
To be able to create a property list dictionary or json object that you use to setup a core image filter in a filter chain, you need to know what the list of keys are for each filter are and for each key what the range of allowed values is that can be assigned to the filter. To get the filter description you can get the "imagefilterattribute" property from the "imagefilterchain" type. The information can be returned in one of 3 ways. Either as a json string (see the example below) or saved to a json or a plist file (-jsonfile, -plistfile). If saving to a file then after the (-jsonfile, -plistfile) option you need to provide a file path.
|
... | ... | @@ -237,7 +218,7 @@ The following json object is everything needed to define the filter chain manage |
|
|
|
|
|
The filter graph for the above filter chain looks like:
|
|
|
|
|
|
![Filter Graph](../raw/master/wiki-images/FilterGraph.jpg "The filter graph for the above json object filter chain representation.")
|
|
|
![Filter Graph](../raw/master/using-movingimages/wiki-images/FilterGraph.jpg "The filter graph for the above json object filter chain representation.")
|
|
|
|
|
|
I'm going to show what the output looks like at each of the stages of the above filter chain so you can see how the final result is built up from the intermediate steps. The radial gradient filter generates an image that has infinite extent. To produce a usable image it is followed by the crop filter. The result of the two filters is:
|
|
|
|
... | ... | |