I have a little problem with the C++ plugins examples that use the support library.
When the plugin describes itself to the host, it uses :
desc.addSupportedContext(eContextFilter);
This function declares the property kOfxImageEffectPropSupportedContexts with kOfxImageEffectContextFilter.
But in the action createInstance, the plugin requires the property kOfxImageEffectPropContext which is not defined.
The action kOfxActionCreateInstance in the C++ support library is :
else if(action == kOfxActionCreateInstance) {
checkMainHandles(actionRaw, handleRaw, inArgsRaw, outArgsRaw, false, true, true);
stage 1 - kOfxActionDescribe
In this call the plugin states which contexts it can work in...
eg: plugin says it can be a filter, a generator and a general plugin
stage 2 - kOfxImageEffectActionDescribeInContext
This is called once for each of the contexts set in stage 1 that the host supports.
eg: our host only support generator and filter contexts, so describe in context is called once for each of these and not for the general plugin
stage 3 - kOfxActionCreateInstance
At some point a user selects our plugin to be used, and it needs to be made in a single context. The plugin is told what context to make the instance for.
eg: the user of our applications selects an image and say to apply the plug-in as a filter to it, so create instance will be called. The instance handle will already have a set of properties on it, one of these is the context that the plug-in was created for.
b
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
I have a little problem with the C++ plugins examples that use the support library.
When the plugin describes itself to the host, it uses :
desc.addSupportedContext(eContextFilter);
This function declares the property kOfxImageEffectPropSupportedContexts with kOfxImageEffectContextFilter.
But in the action createInstance, the plugin requires the property kOfxImageEffectPropContext which is not defined.
The action kOfxActionCreateInstance in the C++ support library is :
else if(action == kOfxActionCreateInstance) {
checkMainHandles(actionRaw, handleRaw, inArgsRaw, outArgsRaw, false, true, true);
}
Does the host add this property in the OfxImageEffect ? This property is already set in inArgs.
Best regards
Hi Fab,
stage 1 - kOfxActionDescribe
In this call the plugin states which contexts it can work in...
eg: plugin says it can be a filter, a generator and a general plugin
stage 2 - kOfxImageEffectActionDescribeInContext
This is called once for each of the contexts set in stage 1 that the host supports.
eg: our host only support generator and filter contexts, so describe in context is called once for each of these and not for the general plugin
stage 3 - kOfxActionCreateInstance
At some point a user selects our plugin to be used, and it needs to be made in a single context. The plugin is told what context to make the instance for.
eg: the user of our applications selects an image and say to apply the plug-in as a filter to it, so create instance will be called. The instance handle will already have a set of properties on it, one of these is the context that the plug-in was created for.
b