![]() |
Camera using IterativeRobot class
Has anybody converted the 2010 Image Demo from the SimpleRobot class to the IterativeRobot class? How did you define the camera so it's not local to only the function it's defined in and therefore lost between iterations? The AxisCamera class seems to work differently from all the other WPILib classes.
|
Re: Camera using IterativeRobot class
I think I have an answer to my own question if anyone is interested. The line
AxisCamera &camera = AxisCamera::getInstance can be put into a function and called repeatedly. The first time it's called it creates a pointer to the camera object and starts the camera app. After that it just returns the same pointer. Seems to works okay. |
Re: Camera using IterativeRobot class
Quote:
Code:
AxisCamera * camera;Code:
camera = &(AxisCamera::GetInstance());Code above is from memory, so it may not work if you cut/paste, but hopefully it will help! |
| All times are GMT -5. The time now is 12:13. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi