none
Compile time error in NuiApi.h RRS feed

  • Question

  • My library and include paths are set and "windows.h" is included before NuiApi.h, still I am experiencing the following errors: 

    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46): error C2146: syntax error : missing ';' before identifier 'INuiAudioBeam'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46): error C2146: syntax error : missing ';' before identifier 'INuiAudioBeam'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46): error C2086: 'int INuiAudioBeam' : redefinition
    1>          C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(46) : see declaration of 'INuiAudioBeam'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(52): error C2146: syntax error : missing ';' before identifier 'INuiFrameTexture'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(52): warning C4091: '' : ignored on left of 'interface' when no variable is declared
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(58): error C2146: syntax error : missing ';' before identifier 'INuiSensor'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(58): warning C4091: '' : ignored on left of 'interface' when no variable is declared
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(385): error C2371: 'INuiFrameTexture' : redefinition; different basic types
    1>          C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(52) : see declaration of 'INuiFrameTexture'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(508): error C2371: 'INuiSensor' : redefinition; different basic types
    1>          C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(58) : see declaration of 'INuiSensor'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(596): error C2061: syntax error : identifier 'INuiAudioBeam'
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(870): error C2065: 'ppDmo' : undeclared identifier
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(870): warning C4229: anachronism used : modifiers on data are ignored
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(870): error C2491: 'NuiGetAudioSource' : definition of dllimport data not allowed
    1>C:\Program Files\Microsoft SDKs\Kinect\v1.0\inc\NuiSensor.h(870): fatal error C1903: unable to recover from previous error(s); stopping compilation
    1>
    1>Build FAILED.

    What am i doing wrong? Any help will be appreciated.

    Monday, March 5, 2012 12:57 PM

Answers

  • It's possible that ObjBase.h (which is normally pulled in by Windows.h) is not being included.

    Do you have WIN32_LEAN_AND_MEAN defined? If so, you should also define INC_OLE2.

    John
    K4W Dev

    Tuesday, March 6, 2012 10:45 PM