... | ... | @@ -257,7 +257,7 @@ After this I took advantage of other features of Moving Images. I generated mult |
|
|
|
|
|
### Providing input images
|
|
|
|
|
|
An input image for a filter can come from either the output image of an earlier filter in the filter chain or from an image source from a base object. Both of these ways of supplying an input image to a filter has been demonstrated above.
|
|
|
An input image for a filter can come from either the output image of an earlier filter in the filter chain or from a base object. Both of these ways of supplying an input image to a filter has been demonstrated above.
|
|
|
|
|
|
If you source an input image from an output image of an earlier filter in the filter chain then you can do it in one of two ways:
|
|
|
|
... | ... | @@ -283,7 +283,25 @@ Method 2 using the filter index in the filter chain of an earlier filter, in thi |
|
|
|
|
|
If the input image for a filter is from a base object like a bitmap context or a image importer object then the "objectreference" key is required and it's value is a base object reference, or alternatively the two keys "objecttype" and "objectname" are required. The value for the "objecttype" key will be "bitmapcontext" or "imageimporter". The value for the "objectname" is the name of the base object given to it when it was created.
|
|
|
|
|
|
If the base object reference identifies a "imageimporter" object or if the "objecttype" is "imageimporter" then a "imageindex" should also be supplied which refers to the index of the image in the image file. If the "imageindex" key is not supplied then the image index value defaults to 0.
|
|
|
{
|
|
|
"cifilterkey": "inputImage",
|
|
|
"cifiltervalueclass": "CIImage",
|
|
|
"cifiltervalue": {
|
|
|
"objectreference": 4
|
|
|
}
|
|
|
}
|
|
|
|
|
|
If the base object reference identifies a "imageimporter" object or if the "objecttype" is "imageimporter" then a "imageindex" should also be supplied which refers to the index of the image in the image file. If the "imageindex" key is not supplied then the image index value defaults to 0. The image index in a image file starts at 0, so in the example below the image referred to is the second image in the image file.
|
|
|
|
|
|
{
|
|
|
"cifilterkey": "inputImage",
|
|
|
"cifiltervalueclass": "CIImage",
|
|
|
"cifiltervalue": {
|
|
|
"objecttype": "imageimporter",
|
|
|
"objectname": "yvs.com.documentation.renderingfilterchain.imageimporter",
|
|
|
"imageindex": 1
|
|
|
}
|
|
|
}
|
|
|
|
|
|
### Rendering an Image Filter Chain object
|
|
|
|
... | ... | |