Ask Your Question
2

How to use multiple depth sensors with OpenNI/OpenCV ?

asked 2013-02-20 09:17:50 -0600

George Profenza gravatar image

I'm using OpenCV 2.4.4 built from source with OpenNI support and I'd like to use two Asus sensors at the same time. Is that possible with OpenCV ? If so how ?

If I initialize a sensor like so:

VideoCapture sensor1;sensor1.open(CV_CAP_OPENNI_ASUS);

How can I init the second ?

edit retag flag offensive close merge delete

Comments

did you try : VideoCapture sensor2;sensor2.open(CV_CAP_OPENNI_ASUS+1); ?

berak gravatar imageberak ( 2013-02-20 12:02:12 -0600 )edit

@berak Just did and it works ! If you want to add that as an answer I'd be more than happy to accept. Thanks!

George Profenza gravatar imageGeorge Profenza ( 2013-02-21 04:54:06 -0600 )edit

ah, cool ;)

berak gravatar imageberak ( 2013-02-21 04:56:06 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2013-02-21 04:58:03 -0600

berak gravatar image

this will work:

VideoCapture sensor1;
sensor1.open( CV_CAP_OPENNI_ASUS );

VideoCapture sensor2;
sensor2.open( CV_CAP_OPENNI_ASUS + 1 );
edit flag offensive delete link more

Question Tools

Stats

Asked: 2013-02-20 09:17:50 -0600

Seen: 972 times

Last updated: Feb 21 '13