gz-rendering icon indicating copy to clipboard operation
gz-rendering copied to clipboard

Add functionality for drawing shapes on images

Open adlarkin opened this issue 4 years ago • 0 comments

Desired behavior

It would be nice to give users a way to draw shapes on images, if there's need/interest for it. I imagine that this would be useful for debugging applications, but perhaps there are also other use cases for this functionality.

Alternatives considered

OpenCV provides methods for doing things like drawing shapes on images. We could add OpenCV as a dependency and provide an API that wraps these OpenCV calls, but this seems like an overkill dependency for functionality that is probably targeted more towards debugging.

Implementation suggestion

Another option would be to create/implement some simple methods like DrawLine or DrawCircle that modify the image pixel data at user-defined locations to be a color specified by the user.

Additional context

Here's a tutorial from OpenCV that showcases some of the methods they have for drawing shapes on images: https://opencv-tutorial.readthedocs.io/en/latest/draw/draw.html

adlarkin avatar Jul 02 '21 03:07 adlarkin