.ONI file load using OpenNI2

asked 2016-09-11 14:08:14 -0500

I am programming in C++ and have been able to save a .oni depth file for testing purposes using OpenNI2.

I am now however unable to load this .ONI file back into a program to use. My code used is as follows:

Status rc_ = openni::STATUS_OK; Device

device_; rc_ = OpenNI::initialize();

char* fileaddress =

"C:\Users\James\DepthRecording1.oni";

rc_ = device_.open(fileaddress);

After the .open line has been executed, rc_ has the following status : STATUS_NO_DEVICE.

This is however the method of loading files as specified in the OpenNI2 documentation, and this code is proven to work if file address is switch for "openni::ANY_DEVICE", in which case it loads my 3D camera (Orbbec Astra). Does anyone know what needs to be changed/ added in order to be able to load the file?

edit retag flag offensive close merge delete

Comments

This forum addresses issues and questions related to Gazebo. You will have better luck with OpenNI questions on a different forum.

nkoenig gravatar imagenkoenig ( 2016-09-12 10:38:06 -0500 )edit