pcl
pcl copied to clipboard
Exception throw [Enabling depth color synchronization failed] when Reading data from Kinect V1, PCL 1.12.0, OpenNi2
i have tried out tools Openni2_view.cpp https://github.com/PointCloudLibrary/pcl/blob/f8c0e1a04947ff8eedca48968aa380231c197e99/tools/openni2_viewer.cpp
Compile with no error, but an exception throw out when run this line https://github.com/PointCloudLibrary/pcl/blob/f8c0e1a04947ff8eedca48968aa380231c197e99/tools/openni2_viewer.cpp#L194
and it return an exception: "pcl::io::openni2::OpenNI2Device::setSynchronization @ C:\pcl-1.12.0\io\src\openni2\openni2_device.cpp @ 428 : Enabling depth color synchronization failed:"
and it cause error for the code below
My system:
- OS: Windows 10
- PCL ver 1.12.0, OpenNi2
- Camera: Kinect V1 (Kinect for Windows)
- i had install Kinect SDK V1.8 How can I fix that exception? or How can i streaming or get data (depth & picture) from Kinect V1 via PCL libraries.
(i have checked my camera with example in kinect sdk, and tool NIview and it OK)
I'm having the same issue. I can run pcl_openni2_viewer
and it works flawlessly. I'm using the correct point type as far as I know and it still appears to be a problem.
@mathemaphysics What are you trying to do and what is the problem? In the original issue, the exception was thrown when running the openni2_viewer. But you say that one works for you?
For the original issue, the problem seems to be this line: https://github.com/PointCloudLibrary/pcl/blob/daf5a3d9d865a2a08c0b467294e5c07006393174/io/include/pcl/io/openni2/openni2_device.h#L215 I don't know how to query that either, and I don't have a Kinect V1 to test. Maybe that device does not support it? Maybe a solution would be to not throw an exception here, just warn: https://github.com/PointCloudLibrary/pcl/blob/daf5a3d9d865a2a08c0b467294e5c07006393174/io/src/openni2/openni2_device.cpp#L424-L429
@mvieth I realized that the synchronization message isn't fatal, and I'm actually definitely getting color synchronization. The initial view in the basic OpenNI2Grabber
was just defaulting to a view pointing at (0, 0, 0), right on top of the origin, flooding the screen with red, green, and black boxes (the colors of the x, y, and z axes as displayed), making it appear that something was wrong.
False alarm. Sorry. I'm still curious about the message. Would damaged hardware result in the failed synchronization?