prominenceai/deepstream-services-library

Extend Pipelines/Branches to be able to link components by both position and by add-order.

rjhowell44 opened this issue · 2 comments

Currently, DSL Pipelines and Branches link components by position. This allows Pipelines to be defined in steps, and over time. However, this requires the Pipeline to be aware of all component types and how they should be linked. This is not the case for custom components which DSL is now to support. See #1174.

Pipelines and Branches need to be able to link all components by add-order. New constants and services defined as follows. The method is propagated down through all Tees and Branches at the point the Pipeline is played.

New symbolic constants used to specify the order to link the Pipeline components

/**
 * @brief Methods of linking Pipeline components
 */
#define DSL_PIPELINE_LINK_METHOD_BY_POSITION                        0
#define DSL_PIPELINE_LINK_METHOD_BY_ADD_ORDER                       1
#define DSL_PIPELINE_LINK_METHOD_DEFAULT                            DSL_PIPELINE_LINK_METHOD_BY_POSITION

New Pipeline services to get/set the Pipeline's link method.

/**
 * @brief Gets the current link method in use by the named Pipeline.
 * @param[in] name unique name of the Pipeline to query.
 * @param[out] link_method DSL_PIPELINE_LINK_METHOD_BY_POSITION or
 * DSL_PIPELINE_LINK_METHOD_BY_ORDER (defaul tis BY_POSITION)
 * @return DSL_RESULT_SUCCESS on success, DSL_RESULT_PIPELINE_RESULT on failure.
 */
DslReturnType dsl_pipeline_link_method_get(const wchar_t* name, uint* link_method);

/**
 * @brief Sets the link method for the named Pipeline to use.
 * @param[in] name unique name of the Pipeline to update.
 * @param[in] link_method DSL_PIPELINE_LINK_METHOD_BY_POSITION or
 * DSL_PIPELINE_LINK_METHOD_BY_ORDER.
 * @return DSL_RESULT_SUCCESS on success, DSL_RESULT_PIPELINE_RESULT on failure.
 */
DslReturnType dsl_pipeline_link_method_set(const wchar_t* name, uint link_method);

Merged into the v0.30.alpha dev branch.

Merged into the v0.30.alpha dev branch