Ask Your Question
0

image colors change when starting application with launch file

asked 2011-06-09 02:14:02 -0500

Bram van de Klundert gravatar image

updated 2016-10-24 09:03:00 -0500

ngrennan gravatar image

hi everyone,

we are writing a user cockpit application which should serve as a way to control our robot, this cockpit shows 3 camera images, one from the kinect, 2 from two webcams.

when we start the cockpit application with a launch file on a machine connected to the robot, the cockpit shows all 3 of the images but the red and the blue channels of the images from the kinect are swapped.(everything that red shows up blue and the other way around). whenever we start the cockpit manually the same thing happens, except that both the webcams swap the blue and red channel, and the kinects colors are normal.

we have tried starting removing all other applications and parameters from the launch file, this gives the same result

the cockpit application is written in QT4.7.0 and both machines run diamondback on ubuntu 10.04.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
1

answered 2011-06-17 12:22:18 -0500

Vincent Rabaud gravatar image

If you are using OpenCV, the image format is BGR, not RGB. So if you are using OpenCV images and not converting them properly, that might be the answer.

edit flag offensive delete link more
1

answered 2011-06-09 05:16:02 -0500

dornhege gravatar image

There are (at least) two differences when running with roslaunch vs. rosrun/manually.

  • Extra parameters like __log are passed
  • You are in a different working directory

I would suggest finding out why the channels are swapped at all, as that seems to be some memory bug that is probably just triggered in another way.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-06-09 02:14:02 -0500

Seen: 260 times

Last updated: Jun 17 '11