mirror of
https://github.com/opencv/opencv.git
synced 2024-11-28 21:20:18 +08:00
Merge pull request #6537 from Slonegg:opeeni2_multiple_devices
This commit is contained in:
commit
7f9319924b
@ -231,6 +231,14 @@ CvCapture_OpenNI2::CvCapture_OpenNI2( int index )
|
||||
return;
|
||||
}
|
||||
|
||||
// find appropriate device URI
|
||||
openni::Array<openni::DeviceInfo> ldevs;
|
||||
if (index > 0)
|
||||
{
|
||||
openni::OpenNI::enumerateDevices(&ldevs);
|
||||
deviceURI = ldevs[index].getUri();
|
||||
}
|
||||
|
||||
status = device.open(deviceURI);
|
||||
if( status != openni::STATUS_OK )
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user