compiling error

Discussion in 'Mac Programming' started by wfs123, May 10, 2011.

  1. macrumors newbie

    Joined:
    Mar 28, 2011
    #1
    im working on compiling a kinect hack. i ran make in a folder, it started to make it then i got an error... here is the results


    HackBook:AS3OpenNI Developer$ make
    g++ -c -arch i386 -arch x86_64 -O3 -fno-tree-pre -fno-strict-aliasing -DNDEBUG -msse3 -mssse3 -I../AS3OpenNI -I/usr/include/nite -I/usr/include/ni -I/usr/local/include -DXN_SSE -o Release/main.o main.cpp
    main.cpp: In function ‘int main(int, char**)’:
    main.cpp:783: error: invalid conversion from ‘void (*)(XnFloat, void*)’ to ‘void (*)(XnUInt32, XnFloat, void*)’
    main.cpp:783: error: initializing argument 2 of ‘void* XnVSteadyDetector::RegisterSteady(void*, void (*)(XnUInt32, XnFloat, void*))’
    main.cpp: In function ‘int main(int, char**)’:
    main.cpp:783: error: invalid conversion from ‘void (*)(XnFloat, void*)’ to ‘void (*)(XnUInt32, XnFloat, void*)’
    main.cpp:783: error: initializing argument 2 of ‘void* XnVSteadyDetector::RegisterSteady(void*, void (*)(XnUInt32, XnFloat, void*))’
    lipo: can't figure out the architecture type of: /var/folders/Uq/Uqg-h-sKEzKf9PCDQjQOXE+++TY/-Tmp-//cceCeWQB.out
    make: *** [Release/main.o] Error 1
    HackBook:AS3OpenNI Developer$

    please help me!
    what am i missing, or doing wrong?
    thanks
     
  2. macrumors 6502

    Joined:
    Apr 29, 2010
    #2
    Should a variable name be between the "int" and the comma? I've never seen a prototype for the main() function.
     
  3. macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #3
    What's on line 783 of main.cpp? The function given as the 2nd argument to the call to RegisterSteady on the that line has a type mismatch. The function is declared with arguments (XnFloat, void*) but it needs to be (XnUInt32, XnFloat, void*).
     
  4. thread starter macrumors newbie

    Joined:
    Mar 28, 2011
    #4
    never mind... i was in the wrong folder.... thanks for all the help though

    will
     

Share This Page