I try to use ofxOpenNi under linux (codeblocks) I’ve copied everythindg in the src directory got every search paths right but when I try to compile I get this error message on the file XnStatus.h (even when I point to the one installed on my system…) :
error : two or more data types in declaration of ‘parameter’
what I don’t get is that the app osceleton from sensebloom compiles just fine.
Could someone point me in the right direction please.
no one ?
I’m really stuck here , I don’t need full source code just a hint on how to compile an OF app wich would include OpenNI on Linux without those errors from xnstatus.h.
/**
* Gets the name of a Xiron Status as a string.
*
* @param Status [in] The input Xiron Status.
*
* @return A string representation of the Xiron status name.
*/
XN_C_API const XnChar* xnGetStatusName(const XnStatus Status);
/**
* Prints a user message with a description of the error.
*
* @param Status [in] The input Xiron Status.
* @param csUserMessage [in] A user message.
*
*/
XN_C_API void xnPrintError(const XnStatus Status, const XnChar* csUserMessage);
see the attach file for a screengrab hope that can be useful to someone.
hehe plusplusweb, we were struggling with the same thing at the same time.
I ended up renaming Status to something like __Status in the same place in the code as you did. It seems there is another Status already declared which is causing this problem.
I am not quite where you are yet, but getting there.
i’m using only makefile, with no codeblocks
config.make seems to be broken in my of version, so i had to add USER_CFLAG directly in makefile for including of/addons/ofxOpenNI/include/openni
but now i have really a lot of undefined reference problem. in opencv, openni, poco, ofOpenALSoundPlayer, ofxUserGenerator
the last one for example is:
…/…/…/addons/ofxOpenCv/libs/opencv/lib/linux/libopencv_objdetect.a(haar.o): In function cvHaarDetectObjects': haar.cpp:(.text.cvHaarDetectObjects+0x1bf2): undefined reference tocvCanny’
if i don’t use USER_CFLAG the compiler can’t find the files .h that ofxOpenNI need (openni, nite, libusb).
if i add the path in USER_CFLAG the compiler get a lot of undefined reference in mostly every libs of openframeworks (poco, sound, ofImage, opencv, and also openni and libusb)
what could it be?
i’m getting mad with this compilation error!
EDIT:
i’ve found (here: http://www.patriciogonzalezvivo.com/blog/?p=213 ) a real awesome example. it uses openNi and has a good file structure and a good makefile with good USER_CFLAGS, USER_LDFLAGS and USER_LIBS.