ros-drivers / pointgrey_camera_driver

ROS driver for Pt. Grey cameras, based on the official FlyCapture2 SDK.
128 stars 180 forks source link

No control for Saturation, Sharpness and Hue #115

Closed ModiGit closed 7 years ago

ModiGit commented 7 years ago

Hello,

I am having issues with image quality using the ROS driver. When I take video outdoors the image is very dim. I used to work with PolySync before and never had this issue with the camera. After investigating, I found that with ROS, the camera is only adjusting the exposure and there is no control over saturation, sharpness and hue. While with polysync the camera is adjusting these parameters and the image quality is great. I added the sharpness controls to PointGrey.cfg file to add sharpness (and autosharpness) to rqt_reconfigure. I also added it to the source code as shown below, but it seems that flycapture is not responding to these parameters change even if I do it from rqt_reconfigure.

1- Changes to Pointgrey.cfg gen.add("auto_sharpness", bool_t, SensorLevels.RECONFIGURE_RUNNING, "Allow the camera to automatically change sharpness.", True)

gen.add("sharpness", double_t, SensorLevels.RECONFIGURE_RUNNING, "sharpness.", 1024.0, 0.0, 4095.0)

2- Changes to PointGreyCamera.cpp retVal &= PointGreyCamera::setProperty(SHARPNESS, config.auto_sharpness, config.sharpness);

Has anyone faced this issue,or am I missing something here,please advise. Thanks for your time....

polysync ros

The first image for polysync, the second one for ros. I know the version of flycapture is different in the two images, I tested with both versions. I upgraded the software hoping that the issue will be resolves but it did not fix it.

Camera model: Blackfly BFLY-PGE-20E4C OS:Ubuntu 14.04LTS Flycatpure version: 2.9.3.43

Here are some examples Polysync Images in snowstorm (no bright light) unspecified unspecified1 unspecified3

and these are examples from ros in cloudy weather (also no bright light) and in the same location: frame0000 frame0001 frame0002

ModiGit commented 7 years ago

I figured out what the problem was. Apparently the driver does not support RGB formatting and 24 bits encoding. I added this feature and it fixed my problem!!