ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

lower resolution of images with image_transport

asked 2017-11-02 13:42:21 -0500

waspinator gravatar image

I'd like to publish/subscribe to streams with different resolutions from a camera node. How would I change the resolution using image_transport? Or is there a better place for creating additional streams?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2017-11-02 14:05:15 -0500

lucasw gravatar image

image_proc resize is relatively new http://wiki.ros.org/image_proc (the inner page link isn't working) doesn't have a lot of detail but the source cfg file shows all the parameters:

https://github.com/ros-perception/ima...

You need to run a nodelet for it for every destination resolution you want, the nodelet doesn't have to subscribe or publish to other nodelets but there is a performance enhancement if you go to that extra effort.

It looks like it can do either scale factor (e.g. 0.5 for half as big, 5.0 for five times as large) or a destination resolution in pixels.

(TODO I have some aspect ratio preserving code in my own version that inserts black vertical or horizontal letterbox bars that I ought to merge in).

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2017-11-02 13:42:21 -0500

Seen: 1,796 times

Last updated: Nov 02 '17