|
Re: Labview Camera lag -- modify dashboard
The dashboard in '10 had two issues that contributed to increased CPU usage. Removing either would reduce the CPU required to draw the video.
The reason is somewhat complicated, but the chart to the right of the screen was configured so that the scale overlapped the plot area. This resulted in the chart invalidating its screen area on updates rather than drawing only new info. The image display also invalidated the image info area. Since these two controls were on opposite sides of the screen, everything that intersects the bounding box of those two invalidated areas would redraw. This approximately doubled the CPU needed to draw the video.
This year's dashboard doesn't have that chart, and will not cause this issue.
At least for LabVIEW, the lag in the vision was often caused by the size of the buffer being returned from the camera. This was due to resizing of buffers and artifacts of the VxWorks memory manager.
If you really want to have lag-free video to the dashboard, I'd recommend hooking a dedicated camera to the switch on the robot, and modifying the dashboard to directly request and decode the MJPG stream. I expect a tutorial or example to be released shortly showing the details.
Greg McKaskle
|