|
Switching between Multiple Cameras using Marker Module eJMO from United States [3 posts] |
11 year
|
There is a basic routine posted several years back on a way to switch between multiple cameras using Marker modules. The code is below.
Set camera_num = 2
if camera_num =1 then
Marker [Switch to camera 1]
end_if
if camera_num=2 then
Marker [Switch to camera 2]
end_if
I attempted to use this code and found Roborealm would not switch between cameras. I made sure that each of the Marker modules were linked to the proper camera. I tried cycling Run ON and OFF and I tried modifying the camera_num variable between 1 and 2. I tried rebooting the computer, and reloading the .robo file. I tried using two USB cameras, and I tried using an internal webcam and one USB camera. None of the combinations worked. The code doesn't do anything. Is there something else that has to be set to allow this code to work?
|
|
|
Steven Gentner from United States [1446 posts] |
11 year
|
e-JMO,
No, that seems about right. I've included what you have above and it appears to be working as would be expected. Ensuring that nothing in the pipeline is selected ensures that the entire pipeline is processed. If any module is selected the image only up to that module will be shown. The run button should be pressed too. Also, be sure to have the most recent version.
STeven. program.robo
|
|