Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement new snap-label-to-grid ODE Action - dsl_ode_action_label_snap_to_grid_new #1191

Closed
rjhowell44 opened this issue Apr 24, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@rjhowell44
Copy link
Collaborator

rjhowell44 commented Apr 24, 2024

Objects labels are anchored to the Object's bbox which can fluctuate greatly from frame to frame. This make reading the object label difficult as it jumps around in view with the upper left corner of the bbox.

New ODE Action to snap the Object label to the closest point on a defined 2D grid. This has the effect stabilizing the box and only moving it as the object moves through the frame.

/**
 * @brief Creates a uniquely named "Snap Object Label to Grid " ODE Action that moves 
 * the object label to the closes location on a 2D grid measured over the frame. 
 * @param[in] name unique name for the "Snap Object Label to Grid ODE Action. 
 * @param[in] module_width width of each module (square) in the grid in pixels.
 * @param[in] module_height height of each module (square) in the grid in pixels. 
 * @return DSL_RESULT_SUCCESS on success, one of DSL_RESULT_ODE_ACTION_RESULT otherwise.
 */
DslReturnType dsl_ode_action_label_snap_to_grid_new(const wchar_t* name,  
    uint module_width, uint module_height);
@rjhowell44 rjhowell44 self-assigned this Apr 24, 2024
@rjhowell44 rjhowell44 added the enhancement New feature or request label Apr 24, 2024
@rjhowell44 rjhowell44 added this to the v0.30.alpha milestone Apr 24, 2024
@rjhowell44 rjhowell44 changed the title Implement new Implement new snap-label-to-grid ODE Action - dsl_ode_action_label_snap_to_grid_new Apr 25, 2024
@rjhowell44
Copy link
Collaborator Author

Merged into the v0.30.alpha dev branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant