Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1054,6 +1054,19 @@ Enumeration Properties
- ``OfxImageEffectRenderFullySafe``
- **Doc**: For detailed doc, see :c:macro:`kOfxImageEffectPluginRenderThreadSafety`.

.. _prop_OfxImageEffectPropBehaviourWhenUnlicensed:

**OfxImageEffectPropBehaviourWhenUnlicensed**
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

- **C #define**: :c:macro:`kOfxImageEffectPropBehaviourWhenUnlicensed`
- **Type**: enum
- **Dimension**: 1
- **Valid Values**:
- ``OfxUnlicensedContinue``
- ``OfxUnlicensedFail``
- **Doc**: For detailed doc, see :c:macro:`kOfxImageEffectPropBehaviourWhenUnlicensed`.

.. _prop_OfxImageEffectPropCPURenderSupported:

**OfxImageEffectPropCPURenderSupported**
Expand Down
28 changes: 20 additions & 8 deletions Documentation/sources/Reference/ofxPropertySetsGenerated.rst
Original file line number Diff line number Diff line change
Expand Up @@ -818,6 +818,10 @@ For each action, the required input properties (passed from host to plugin) and

**Input Arguments**

- :ref:`OfxPropName <prop_OfxPropName>` - Type: string, Dimension: 1 (:c:macro:`kOfxPropName`)

- :ref:`OfxPropTime <prop_OfxPropTime>` - Type: double, Dimension: 1 (:c:macro:`kOfxPropTime`)

- :ref:`OfxParamPropCustomValue <prop_OfxParamPropCustomValue>` - Type: string, Dimension: 2 (:c:macro:`kOfxParamPropCustomValue`)

- :ref:`OfxParamPropInterpolationTime <prop_OfxParamPropInterpolationTime>` - Type: double, Dimension: 2 (:c:macro:`kOfxParamPropInterpolationTime`)
Expand Down Expand Up @@ -981,12 +985,12 @@ For each action, the required input properties (passed from host to plugin) and

- :ref:`OfxImageEffectPropOpenGLTextureTarget <prop_OfxImageEffectPropOpenGLTextureTarget>` - Type: int, Dimension: 1 (:c:macro:`kOfxImageEffectPropOpenGLTextureTarget`)

- :ref:`OfxImageEffectPropInteractiveRenderStatus <prop_OfxImageEffectPropInteractiveRenderStatus>` - Type: bool, Dimension: 1 (:c:macro:`kOfxImageEffectPropInteractiveRenderStatus`)

- :ref:`OfxImageEffectPropNoSpatialAwareness <prop_OfxImageEffectPropNoSpatialAwareness>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropNoSpatialAwareness`)

- :ref:`OfxImageEffectPropThumbnailRender <prop_OfxImageEffectPropThumbnailRender>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropThumbnailRender`)

- :ref:`OfxImageEffectPropBehaviourWhenUnlicensed <prop_OfxImageEffectPropBehaviourWhenUnlicensed>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropBehaviourWhenUnlicensed`)

.. _action_OfxImageEffectActionDescribeInContext:

**OfxImageEffectActionDescribeInContext**
Expand Down Expand Up @@ -1045,8 +1049,6 @@ For each action, the required input properties (passed from host to plugin) and

- :ref:`OfxImageEffectPropOpenGLTextureTarget <prop_OfxImageEffectPropOpenGLTextureTarget>` - Type: int, Dimension: 1 (:c:macro:`kOfxImageEffectPropOpenGLTextureTarget`)

- :ref:`OfxImageEffectPropInteractiveRenderStatus <prop_OfxImageEffectPropInteractiveRenderStatus>` - Type: bool, Dimension: 1 (:c:macro:`kOfxImageEffectPropInteractiveRenderStatus`)

.. _action_OfxImageEffectActionGetClipPreferences:

**OfxImageEffectActionGetClipPreferences**
Expand Down Expand Up @@ -1075,10 +1077,6 @@ For each action, the required input properties (passed from host to plugin) and

- :ref:`OfxImageEffectPropThumbnailRender <prop_OfxImageEffectPropThumbnailRender>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropThumbnailRender`)

**Output Arguments**

- :ref:`OfxImageEffectPropFrameRange <prop_OfxImageEffectPropFrameRange>` - Type: double, Dimension: 2 (doc: :c:macro:`kOfxImageEffectPropFrameRange`)

.. _action_OfxImageEffectActionGetOutputColourspace:

**OfxImageEffectActionGetOutputColourspace**
Expand Down Expand Up @@ -1150,6 +1148,12 @@ For each action, the required input properties (passed from host to plugin) and

- :ref:`OfxImageEffectPropThumbnailRender <prop_OfxImageEffectPropThumbnailRender>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropThumbnailRender`)

**Output Arguments**

- :ref:`OfxPropName <prop_OfxPropName>` - Type: string, Dimension: 1 (doc: :c:macro:`kOfxPropName`)

- :ref:`OfxPropTime <prop_OfxPropTime>` - Type: double, Dimension: 1 (doc: :c:macro:`kOfxPropTime`)

.. _action_OfxImageEffectActionRender:

**OfxImageEffectActionRender**
Expand All @@ -1159,6 +1163,12 @@ For each action, the required input properties (passed from host to plugin) and

- :ref:`OfxPropTime <prop_OfxPropTime>` - Type: double, Dimension: 1 (:c:macro:`kOfxPropTime`)

- :ref:`OfxImageEffectPropFieldToRender <prop_OfxImageEffectPropFieldToRender>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropFieldToRender`)

- :ref:`OfxImageEffectPropRenderWindow <prop_OfxImageEffectPropRenderWindow>` - Type: int, Dimension: 4 (:c:macro:`kOfxImageEffectPropRenderWindow`)

- :ref:`OfxImageEffectPropRenderScale <prop_OfxImageEffectPropRenderScale>` - Type: double, Dimension: 2 (:c:macro:`kOfxImageEffectPropRenderScale`)

- :ref:`OfxImageEffectPropSequentialRenderStatus <prop_OfxImageEffectPropSequentialRenderStatus>` - Type: bool, Dimension: 1 (:c:macro:`kOfxImageEffectPropSequentialRenderStatus`)

- :ref:`OfxImageEffectPropInteractiveRenderStatus <prop_OfxImageEffectPropInteractiveRenderStatus>` - Type: bool, Dimension: 1 (:c:macro:`kOfxImageEffectPropInteractiveRenderStatus`)
Expand Down Expand Up @@ -1199,6 +1209,8 @@ For each action, the required input properties (passed from host to plugin) and

- :ref:`OfxImageEffectPropThumbnailRender <prop_OfxImageEffectPropThumbnailRender>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropThumbnailRender`)

- :ref:`OfxImageEffectPropBehaviourWhenUnlicensed <prop_OfxImageEffectPropBehaviourWhenUnlicensed>` - Type: enum, Dimension: 1 (:c:macro:`kOfxImageEffectPropBehaviourWhenUnlicensed`)

.. _action_OfxInteractActionDraw:

**OfxInteractActionDraw**
Expand Down
2 changes: 1 addition & 1 deletion include/ofxCore.h
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ These are the actions passed to a plug-in's 'main' function
inArgs:
- OfxPropChangeReason
- OfxImageEffectPropThumbnailRender
outArgs: []
outArgs:
*/
#define kOfxActionBeginInstanceChanged "OfxActionBeginInstanceChanged"

Expand Down
22 changes: 15 additions & 7 deletions include/ofxImageEffect.h
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ These are the list of actions passed to an image effect plugin's main function.
- OfxPropTime
- OfxImageEffectPropThumbnailRender
outArgs:
- OfxImageEffectPropFrameRange
# - OfxImageEffectPropFrameRange_ # with clip name

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the same way as for OfxImageEffectClipPropRoI_ in kOfxImageEffectActionGetRegionsOfInterest:
https://github.com/umajho/openfx/blob/e82be712c7f7bed3ba3581b42902647ce1c6fe90/include/ofxImageEffect.h#L204

*/
#define kOfxImageEffectActionGetFramesNeeded "OfxImageEffectActionGetFramesNeeded"

Expand Down Expand Up @@ -442,6 +442,8 @@ These are the list of actions passed to an image effect plugin's main function.
- OfxImageEffectPropRenderScale
- OfxImageEffectPropThumbnailRender
outArgs:
- OfxPropName
- OfxPropTime
*/
#define kOfxImageEffectActionIsIdentity "OfxImageEffectActionIsIdentity"

Expand Down Expand Up @@ -490,6 +492,9 @@ These are the list of actions passed to an image effect plugin's main function.
@actiondef
inArgs:
- OfxPropTime
- OfxImageEffectPropFieldToRender
- OfxImageEffectPropRenderWindow
- OfxImageEffectPropRenderScale
- OfxImageEffectPropSequentialRenderStatus
- OfxImageEffectPropInteractiveRenderStatus
- OfxImageEffectPropRenderQualityDraft
Expand All @@ -510,6 +515,7 @@ These are the list of actions passed to an image effect plugin's main function.
- OfxImageEffectPropOpenGLTextureTarget
- OfxImageEffectPropNoSpatialAwareness
- OfxImageEffectPropThumbnailRender
- OfxImageEffectPropBehaviourWhenUnlicensed
outArgs:
*/
#define kOfxImageEffectActionRender "OfxImageEffectActionRender"
Expand Down Expand Up @@ -576,9 +582,9 @@ These are the list of actions passed to an image effect plugin's main function.
- OfxImageEffectPropOpenGLEnabled
- OfxImageEffectPropOpenGLTextureIndex
- OfxImageEffectPropOpenGLTextureTarget
- OfxImageEffectPropInteractiveRenderStatus
- OfxImageEffectPropNoSpatialAwareness
- OfxImageEffectPropThumbnailRender
- OfxImageEffectPropBehaviourWhenUnlicensed
outArgs:
*/
#define kOfxImageEffectActionBeginSequenceRender "OfxImageEffectActionBeginSequenceRender"
Expand Down Expand Up @@ -642,7 +648,6 @@ These are the list of actions passed to an image effect plugin's main function.
- OfxImageEffectPropOpenGLEnabled
- OfxImageEffectPropOpenGLTextureIndex
- OfxImageEffectPropOpenGLTextureTarget
- OfxImageEffectPropInteractiveRenderStatus
outArgs:
*/
#define kOfxImageEffectActionEndSequenceRender "OfxImageEffectActionEndSequenceRender"
Expand Down Expand Up @@ -1703,10 +1708,6 @@ This will be in \ref PixelCoordinates

/** @brief The host's behaviour when the plug-in is unlicensed
- Type - string X 1
- Property Set - inArgs property set of the \ref kOfxImageEffectActionBeginSequenceRender
and \ref kOfxImageEffectActionRender actions
If the plug-in determines that it is unlicensed during a \ref
kOfxImageEffectActionBeginSequenceRender or \ref kOfxImageEffectActionRender
action, it should check this property.
Expand All @@ -1730,6 +1731,13 @@ If \ref kOfxImageEffectPropBehaviourWhenUnlicensed is set to
- plug-in should return \ref kOfxStatUnlicensed and may do this
without any rendering, because it knows the host will fail the
render.
@propdef
type: enum
dimension: 1
values:
- OfxUnlicensedContinue
- OfxUnlicensedFail
*/
#define kOfxImageEffectPropBehaviourWhenUnlicensed "OfxImageEffectPropBehaviourWhenUnlicensed"

Expand Down
2 changes: 2 additions & 0 deletions include/ofxParam.h
Original file line number Diff line number Diff line change
Expand Up @@ -924,6 +924,8 @@ The interp value is a linear interpolation amount, however his may be derived fr

@actiondef
inArgs:
- OfxPropName
- OfxPropTime
- OfxParamPropCustomValue
- OfxParamPropInterpolationTime
- OfxParamPropInterpolationAmount
Expand Down
63 changes: 45 additions & 18 deletions openfx-cpp/include/openfx/ofxPropSetAccessors.h
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,14 @@ class CustomParamInterpFunc_InArgs : public PropertySetAccessor {
public:
using PropertySetAccessor::PropertySetAccessor;

const char* name(bool error_if_missing = true) const {
return props_.get<PropId::OfxPropName>(0, error_if_missing);
}

double time(bool error_if_missing = true) const {
return props_.get<PropId::OfxPropTime>(0, error_if_missing);
}

std::array<const char*, 2> customValue() const {
return props_.getAll<PropId::OfxParamPropCustomValue>();
}
Expand Down Expand Up @@ -822,6 +830,10 @@ class ImageEffectActionBeginSequenceRender_InArgs : public PropertySetAccessor {
return props_.get<PropId::OfxImageEffectPropThumbnailRender>(0, error_if_missing);
}

const char* behaviourWhenUnlicensed(bool error_if_missing = true) const {
return props_.get<PropId::OfxImageEffectPropBehaviourWhenUnlicensed>(0, error_if_missing);
}

};

// Property set accessor for: ImageEffectActionDescribeInContext_InArgs
Expand Down Expand Up @@ -973,24 +985,6 @@ class ImageEffectActionGetFramesNeeded_InArgs : public PropertySetAccessor {

};

// Property set accessor for: ImageEffectActionGetFramesNeeded_OutArgs
class ImageEffectActionGetFramesNeeded_OutArgs : public PropertySetAccessor {
public:
using PropertySetAccessor::PropertySetAccessor;

ImageEffectActionGetFramesNeeded_OutArgs& setFrameRange(const std::array<double, 2>& values, bool error_if_missing = true) {
props_.setAll<PropId::OfxImageEffectPropFrameRange>(values, error_if_missing);
return *this;
}

// Set all values from an initializer list (e.g., {1, 2})
ImageEffectActionGetFramesNeeded_OutArgs& setFrameRange(std::initializer_list<double> values, bool error_if_missing = true) {
props_.setAll<PropId::OfxImageEffectPropFrameRange>(values, error_if_missing);
return *this;
}

};

// Property set accessor for: ImageEffectActionGetOutputColourspace_InArgs
class ImageEffectActionGetOutputColourspace_InArgs : public PropertySetAccessor {
public:
Expand Down Expand Up @@ -1119,6 +1113,23 @@ class ImageEffectActionIsIdentity_InArgs : public PropertySetAccessor {

};

// Property set accessor for: ImageEffectActionIsIdentity_OutArgs
class ImageEffectActionIsIdentity_OutArgs : public PropertySetAccessor {
public:
using PropertySetAccessor::PropertySetAccessor;

ImageEffectActionIsIdentity_OutArgs& setName(const char* value, bool error_if_missing = true) {
props_.set<PropId::OfxPropName>(value, 0, error_if_missing);
return *this;
}

ImageEffectActionIsIdentity_OutArgs& setTime(double value, bool error_if_missing = true) {
props_.set<PropId::OfxPropTime>(value, 0, error_if_missing);
return *this;
}

};

// Property set accessor for: ImageEffectActionRender_InArgs
class ImageEffectActionRender_InArgs : public PropertySetAccessor {
public:
Expand All @@ -1128,6 +1139,18 @@ class ImageEffectActionRender_InArgs : public PropertySetAccessor {
return props_.get<PropId::OfxPropTime>(0, error_if_missing);
}

const char* fieldToRender(bool error_if_missing = true) const {
return props_.get<PropId::OfxImageEffectPropFieldToRender>(0, error_if_missing);
}

std::array<int, 4> renderWindow() const {
return props_.getAll<PropId::OfxImageEffectPropRenderWindow>();
}

std::array<double, 2> renderScale() const {
return props_.getAll<PropId::OfxImageEffectPropRenderScale>();
}

bool sequentialRenderStatus(bool error_if_missing = true) const {
return props_.get<PropId::OfxImageEffectPropSequentialRenderStatus>(0, error_if_missing);
}
Expand Down Expand Up @@ -1208,6 +1231,10 @@ class ImageEffectActionRender_InArgs : public PropertySetAccessor {
return props_.get<PropId::OfxImageEffectPropThumbnailRender>(0, error_if_missing);
}

const char* behaviourWhenUnlicensed(bool error_if_missing = true) const {
return props_.get<PropId::OfxImageEffectPropBehaviourWhenUnlicensed>(0, error_if_missing);
}

};

// Property set accessor for: ImageEffectHost
Expand Down
Loading