ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Proper source of xncore for compiling svn opencv with openni support?

asked 2011-06-01 10:52:36 -0600

lucasw gravatar image

updated 2020-11-21 11:25:43 -0600

I've just upgraded my opencv svn to 2.2.9 and am building it with OpenNI support on a Ubuntu 10.10 64-bit system, already having installed the apt-get available openni-dev (either because I have ros installed or it's part of ubuntu repositories now).

I used -D WITH_OPENNI=ON and -D OPENNI_INCLUDE_DIR=/usr/include/openni/ with cmake, and this generated this error:

"WARNING, PrimeSensor Module binaries directory (set by OPENNI_PRIME_SENSOR_MODULE_BIN_DIR variable) is not found or does not have 
PrimeSensor Module binaries."

In the OpenCVFindOpenNI.cmake I found this was due to XnCore not being found- this happened to be on my system in a ros installed directory /.../ros/ni/ni/ps_engine/lib/, but where should I get it from if I don't want to install ros if I'm to install opencv on another system?

The above compiles opencv fine, but kinect_maps fails

Kinect opening ...
Can not open a capture object.

Which might be the source of a separate question, unless I shouldn't be using the openni-dev package at all and it's causing that problem also.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted

answered 2011-07-15 09:40:46 -0600

You need to install OpenNI and PrimeSense sensor module from source. That's what I did.

  1. Get the source codes

    $ git clone

    $ git clone

  2. Compile them in order (follow their README instructions of each package to satisfy requirements/dependencies)

  3. Re-build (Cmake) your openCV.
edit flag offensive delete link more

Question Tools


Asked: 2011-06-01 10:52:36 -0600

Seen: 1,450 times

Last updated: Jul 15 '11