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

Clearer Display of OpenCV window in image_tools/showimage ROS2 node #668

Draft
wants to merge 1 commit into
base: rolling
Choose a base branch
from

Conversation

cardboardcode
Copy link
Contributor

@cardboardcode cardboardcode commented Mar 7, 2024

What Is This For?

The purpose of this pull request is to introduce a small but helpful change to the showimage ROS 2 node under the image_tools package.

This change includes a few new lines under the file image_tools/src/showimage.cpp that defines the starting position for an OpenCV window display at x=0, y=0 desktop pixel position; the top-left corner of a user's desktop.

Why?

I have been using image_tools for a quite a while now. Here are the following reasons why I believe this small change could help improve the user experience for any developers who used the ROS 2 node in their own project:

  1. When displaying camera images, the image would be cut-off when it is too big to fit within desktop boundaries (Eg. 4K web cam images). Displaying on the upper-left corner helps reduce that inconvenience.
  2. This standardizes the position of the OpenCV window and account for more deterministic behaviour during testing.

Other Remarks

In order to better fit the OpenCV window into a user's desktop automatically, I am considering implementing a resize feature within showimage of image_tools ROS 2 package (which should not take long actually).

However, I fear it may introduce additional dependencies which may complicate testing down the line. To the maintainers, do let me know your thoughts on this. In the meantime, will do my own testing offline and update if it is just a false fear.

Welcoming any constructive feedbacks on this matter and what I can do to contribute to this amazing community. To the maintainers, thank you for the work you have done so far in this repository and will continue to support in whatever way I can, given personal bandwidth. ☺️

@cardboardcode
Copy link
Contributor Author

cardboardcode commented Mar 7, 2024

Encountering the following build error during CI:

12:52:26 rosdep2.lookup.ResolutionError: No definition of [ros_workspace] for OS version [jammy]
12:52:26 rosdep key : ros_workspace
12:52:26 OS name : ubuntu
12:52:26 OS version : jammy

Don't think it is an issue with the new lines of code. Seems like an issue on the backend.

Is there anything I can do to rectify this from my side?

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

Successfully merging this pull request may close these issues.

1 participant