deepstream-services-library icon indicating copy to clipboard operation
deepstream-services-library copied to clipboard

Implement new Style BBox Corners ODE Action

Open rjhowell44 opened this issue 1 year ago • 0 comments

Requested by a user... new ODE Action to stylize the corners of the bounding box as an alternative the standard box.

New data structure required to define a threshold value.... will be used to define a series (array) of line thickness values

/**
 * @struct _dsl_threshold_value
 * @brief defines an abstract class that contains two data points; a
 * minimum threshold and a value to use if the threshold is met.
 */
typedef struct _dsl_threshold_value
{
    /**
     * @brief the minimum threshold that defines when value is first valid.
     */
    uint threshold;

    /**
     * @brief the value to use if the minimum threshold is met.
     */
    uint value;
    
} dsl_threshold_value;
/**
 * @brief Creates a uniquely named "Style BBox Corners" ODE Action that styles
 * the Objects BBox corners with RGBA Mutli-Lines.
 * @param[in] name unique name for the "Scale Bounding Box" ODE Action. 
 * @param[in] color RGBA Color to use for the styled BBox corners. 
 * @param[in] length of each corner line defined as a percentage of the length of 
 * the longest side of the Object's BBox.
 * @param[in] max_length maximum length of each corner line defined as a percentage
 * of the shortest side of the Object's BBox.
 * @param[in] thickness_values an array of defined threshold values to use for each
 * lines thickness.
 * @param[in] num_values the number of values in the thickness_values array.
 * @return DSL_RESULT_SUCCESS on success, one of DSL_RESULT_ODE_ACTION_RESULT otherwise.
 */
DslReturnType dsl_ode_action_bbox_style_corners_new(const wchar_t* name, 
    const wchar_t* color, uint length, uint max_length,
    dsl_threshold_value* thickness_values, uint num_values);

rjhowell44 avatar Oct 08 '23 00:10 rjhowell44