|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Re: Camera in Grayscale
I'm not an expert, but how would this decrease bandwidth usage? You're still sending the same information, except this time instead of a pixel being red it's just black.
If you're worried about bandwidth, I would look into capping the frames per second the camera transmits or the resolution. I know the Axis cameras had a configuration utility page that allowed this sort of customization. |
|
#2
|
||||
|
||||
|
Re: Camera in Grayscale
Quote:
|
|
#3
|
|||
|
|||
|
Re: Camera in Grayscale
Quote:
There are a number of ways to convert from rgb to grayscale, what language/computer vision library are you using? |
|
#4
|
|||
|
|||
|
Re: Camera in Grayscale
The LabVIEW WPILib has a function to set the Color Enable Property. True means color is enabled. False means the camera is grayscale. But the property is only supported for Axis cameras. JPEGs have a special encoding for grayscale images, and they are indeed smaller than color, but it isn't as simple as a threeX ratio.
As mentioned by others, there are other effective ways to reduce bandwidth. Image resolution reduces by X squared. Framerate by X. Greg McKaskle |
|
#5
|
||||
|
||||
|
Re: Camera in Grayscale
But you're not sending raw data, you're sending an MJPG. Its lossy compression, and the difference between color and grayscale will be negligible compared to bumping up the compression a bit
|
|
#6
|
||||
|
||||
|
Re: Camera in Grayscale
Exactly.
|
|
#7
|
|||
|
|||
|
Re: Camera in Grayscale
I don't have time to do the side-by-side compare, but if you use an IP camera such as Axis and flip between color enable of true and false, you will see the difference. JPEG has a special definition for encoding Y only images and it is another way to reduce size. You are deciding whether you lose color and retain detail or lose color and detail by lowering compression. The other lever you can pull is the resolution or size of the image. The final lever is the framerate.
Experiment and make sure the drivers understand how to pull the levers for themselves. The default dashboard gives an LED indicator showing how their usage compares to the field limits. Also, I personally don't have much experience with the new radio and bandwidth limiting, but I expect that the radio will cause the equivalent of framerate limiting if you don't pull the levers to get your usage under the limit. I don't expect the cameras to hog bandwidth the way they were able to in past years. Greg McKaskle |
|
#8
|
||||
|
||||
|
Re: Camera in Grayscale
Quote:
|
|
#9
|
|||
|
|||
|
Re: Camera in Grayscale
It's compressing to JPG before transmission across the network. That said, this will still reduce bandwidth requirement (although how much would require testing).
Before going this route, I'd recommend looking at reducing the resoultion & framerate if possible. I'm curious as to what is currently being used and what is required. |
|
#10
|
|||
|
|||
|
Re: Camera in Grayscale
Another option would be to convert to HSV and then select which channel you want to process. That way you are still retaining information from RGB at 1/3 the data.
|
|
#11
|
|||
|
|||
|
Re: Camera in Grayscale
I'd still be leery about that. The HD3000 can output images in JPG directly and use internal hardware compression. Any sort of post processing on the roboRIO would require compressing the image on the roboRIO and this will use up significant processor resources.
|
|
#12
|
|||
|
|||
|
Re: Camera in Grayscale
To echo adciv. Potential options are great. But test them, as the real world isn't obliged to work the way you expected.
Greg McKaskle |
|
#13
|
||||
|
||||
|
Re: Camera in Grayscale
If you are trying to use a camera for vision tracking I don't know that this will be able to still vision track across a gray scale as it may confuse similar objects for the reflected light. If this is for a drive camera for driver vision going around obstacles, I would highly recommend keeping the camera in color so that you know what exactly you are looking at. the best option to reduce bandwidth would be dropping the frames to about 15 FPS and lowering the resolution to about half of the area the camera will take up on your screen. this way you are still able to visually use and see with the camera as well as being able to tell whether that is a blue or red robot charging at you and whether or not they will stop. If it still becomes a bandwidth issue you can always reduce the FPS or resolution further to make the FTA's and Others happy.
Feel free to try grayscale though if you can figure it out, but I don't think it will be as effective as reducing frames and resolution. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|