AcademySoftwareFoundation / AcademySoftwareFoundation/openfx
OFX::Host::ImageEffect::Base::supportsTiles returns an incorrect value when kOfxImageEffectPropSupportsTiles is set on the plugin rather than the instance
- Dominant language
- C++
- Stars
- 570
- Forks
- 152
- Avg merge
- 5m
- Merged PRs (30d)
- 2
Description
### Problem
Plugins can declare support (or not) for tiles by setting `kOfxImageEffectPropSupportsTiles` on either the plugin descriptor or the plugin instance (per [the docs](https://openfx.readthedocs.io/en/main/Reference/ofxPropertiesReference.html)).
If a plugin explicitly sets the property to `false` on the plugin descriptor (in `kOfxActionDescribe `) but sets no value on the instance (in `kOfxImageEffectActionDescribeInContext`) then `supportsTiles` returns `true` even though the plugin has declared that it does not support tiling.
### Expected behaviour
If a plugin sets `kOfxImageEffectPropSupportsTiles` to `false` on the plugin descriptor, then `OFX::Host::ImageEffect::Base::supportsTiles` should return `false`.
### Actual behaviour
If a plugin sets `kOfxImageEffectPropSupportsTiles` to `false` on the plugin descriptor, then `OFX::Host::ImageEffect::Base::supportsTiles` returns `true`.
### Notes
I believe this is because a default is declared in the instance property set, and this default overrides the value that would otherwise be inherited from the plugin descriptor. I think it would be more correct for `kOfxImageEffectPropSupportsTiles` to be treated the same way as `kOfxImageEffectInstancePropSequentialRender`, and set the initial value to the one from the plugin descriptor.
Contributor guide
Research direction
Trace OFX::Host::ImageEffect::Base::supportsTiles and the plugin/instance property initialization described in the issue. Reproduce the case where the descriptor sets kOfxImageEffectPropSupportsTiles to false and the instance leaves it unset, then verify supportsTiles() returns false while instance values still behave correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- api
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100