bantherewind / cinder-mskinect Goto Github PK
View Code? Open in Web Editor NEWCinder wrapper for the official Kinect SDK
Home Page: http://www.bantherewind.com/kinectsdk-for-cinder
Cinder wrapper for the official Kinect SDK
Home Page: http://www.bantherewind.com/kinectsdk-for-cinder
https://github.com/BanTheRewind/Cinder-KinectSdk/blob/master/src/Kinect.cpp#L998
That line ensures that the device id is always ""
. Is this intentional? Seems to have made it into the code in commit 70b3c10.
I'm using the newest build that was posted yesterday (March 7th, 2012).
Cinder is version 0.83 - newest from GitHub as of today and boost is version 1.48.0
Looking forward to using the library!
PreBuildEvent:
1> C:\Program Files\Microsoft SDKs\Kinect\v1.0\Assemblies\Microsoft.Kinect.dll
1> 1 File(s) copied
1>ClCompile:
1> KinectApp.cpp
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(79): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(80): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(133): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(134): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(79): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(80): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(133): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\src\kinect.h(134): warning C4482: nonstandard extension used: enum '_NUI_IMAGE_RESOLUTION' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(224): warning C4482: nonstandard extension used: enum '_NUI_SKELETON_POSITION_INDEX' used in qualified name
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::complex<_Other> std::operator +(const _Ty &,const std::complex<_Other> &)' : could not deduce template argument for 'const std::complex<_Other> &' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xcomplex(26) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::complex<_Other> std::operator +(const std::complex<_Other> &,const _Ty &)' : could not deduce template argument for 'const std::complex<_Other> &' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xcomplex(17) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::complex<_Other> std::operator +(const std::complex<_Other> &,const std::complex<_Other> &)' : could not deduce template argument for 'const std::complex<_Other> &' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xcomplex(9) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Deque_iterator<_Ty,_Alloc> std::operator +(_Deque_iterator<_Ty,_Alloc>::difference_type,std::_Deque_iterator<_Ty,_Alloc>)' : could not deduce template argument for 'std::_Deque_iterator<_Ty,_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\deque(707) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Deque_const_iterator<_Ty,_Alloc> std::operator +(_Deque_const_iterator<_Ty,_Alloc>::difference_type,std::_Deque_const_iterator<_Ty,_Alloc>)' : could not deduce template argument for 'std::_Deque_const_iterator<_Ty,_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\deque(570) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Deque_unchecked_iterator<_Ty,_Alloc> std::operator +(_Deque_unchecked_iterator<_Ty,_Alloc>::difference_type,std::_Deque_unchecked_iterator<_Ty,_Alloc>)' : could not deduce template argument for 'std::_Deque_unchecked_iterator<_Ty,_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\deque(279) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Deque_unchecked_const_iterator<_Ty,_Alloc> std::operator +(_Deque_unchecked_const_iterator<_Ty,_Alloc>::difference_type,std::_Deque_unchecked_const_iterator<_Ty,_Alloc>)' : could not deduce template argument for 'std::_Deque_unchecked_const_iterator<_Ty,_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\deque(172) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Vb_iterator<_Alloc> std::operator +(_Alloc::difference_type,std::_Vb_iterator<_Alloc>)' : could not deduce template argument for 'std::_Vb_iterator<_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\vector(1985) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Vb_const_iterator<_Alloc> std::operator +(_Alloc::difference_type,std::_Vb_const_iterator<_Alloc>)' : could not deduce template argument for 'std::_Vb_const_iterator<_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\vector(1878) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Vector_iterator<_Myvec> std::operator +(_Vector_iterator<_Myvec>::difference_type,std::_Vector_iterator<_Myvec>)' : could not deduce template argument for 'std::_Vector_iterator<_Myvec>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\vector(407) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Vector_const_iterator<_Myvec> std::operator +(_Vector_const_iterator<_Myvec>::difference_type,std::_Vector_const_iterator<_Myvec>)' : could not deduce template argument for 'std::_Vector_const_iterator<_Myvec>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\vector(276) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::move_iterator<_RanIt> std::operator +(_Diff,const std::move_iterator<_RanIt> &)' : could not deduce template argument for 'const std::move_iterator<_RanIt> &' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\iterator(336) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(std::basic_string<_Elem,_Traits,_Alloc> &&,const _Elem)' : could not deduce template argument for 'std::basic_string<_Elem,_Traits,_Alloc> &&' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(153) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(std::basic_string<_Elem,_Traits,_Alloc> &&,const _Elem *)' : could not deduce template argument for 'std::basic_string<_Elem,_Traits,_Alloc> &&' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(143) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const _Elem,std::basic_string<_Elem,_Traits,_Alloc> &&)' : could not deduce template argument for 'std::basic_string<_Elem,_Traits,_Alloc> &&' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(133) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const _Elem *,std::basic_string<_Elem,_Traits,_Alloc> &&)' : could not deduce template argument for 'const _Elem *' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(123) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(std::basic_string<_Elem,_Traits,_Alloc> &&,std::basic_string<_Elem,_Traits,_Alloc> &&)' : could not deduce template argument for 'std::basic_string<_Elem,_Traits,_Alloc> &&' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(109) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(std::basic_string<_Elem,_Traits,_Alloc> &&,const std::basic_string<_Elem,_Traits,_Alloc> &)' : could not deduce template argument for 'std::basic_string<_Elem,_Traits,_Alloc> &&' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(99) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const std::basic_string<_Elem,_Traits,_Alloc> &,std::basic_string<_Elem,_Traits,_Alloc> &&)' : could not deduce template argument for 'const std::basic_string<_Elem,_Traits,_Alloc> &' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(89) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const std::basic_string<_Elem,_Traits,_Alloc> &,const _Elem)' : could not deduce template argument for 'const std::basic_string<_Elem,_Traits,_Alloc> &' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(75) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const std::basic_string<_Elem,_Traits,_Alloc> &,const _Elem *)' : could not deduce template argument for 'const std::basic_string<_Elem,_Traits,_Alloc> &' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(61) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const _Elem,const std::basic_string<_Elem,_Traits,_Alloc> &)' : could not deduce template argument for 'const std::basic_string<_Elem,_Traits,_Alloc> &' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(47) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const _Elem *,const std::basic_string<_Elem,_Traits,_Alloc> &)' : could not deduce template argument for 'const _Elem *' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(33) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::basic_string<_Elem,_Traits,_Alloc> std::operator +(const std::basic_string<_Elem,_Traits,_Alloc> &,const std::basic_string<_Elem,_Traits,_Alloc> &)' : could not deduce template argument for 'const std::basic_string<_Elem,_Traits,_Alloc> &' from 'boost::filesystem3::path'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\string(19) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_String_iterator<_Elem,_Traits,_Alloc> std::operator +(_String_iterator<_Elem,_Traits,_Alloc>::difference_type,std::_String_iterator<_Elem,_Traits,_Alloc>)' : could not deduce template argument for 'std::_String_iterator<_Elem,_Traits,_Alloc>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xstring(434) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_String_const_iterator<_Elem,_Traits,_Alloc> std::operator +(_String_const_iterator<_Elem,_Traits,_Alloc>::difference_type,std::_String_const_iterator<_Elem,_Traits,_Alloc>)' : could not deduce template argument for 'std::_String_const_iterator<_Elem,_Traits,_Alloc>' from 'const char[6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xstring(293) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Array_iterator<_Ty,_Size> std::operator +(_Array_iterator<_Ty,_Size>::difference_type,std::_Array_iterator<_Ty,_Size>)' : could not deduce template argument for 'std::_Array_iterator<_Ty,_Size>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xutility(2068) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Array_const_iterator<_Ty,_Size> std::operator +(_Array_const_iterator<_Ty,_Size>::difference_type,std::_Array_const_iterator<_Ty,_Size>)' : could not deduce template argument for 'std::_Array_const_iterator<_Ty,_Size>' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xutility(1929) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::reverse_iterator<_RanIt> std::operator +(_Diff,const std::reverse_iterator<_RanIt> &)' : could not deduce template argument for 'const std::reverse_iterator<_RanIt> &' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xutility(1323) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2784: 'std::_Revranit<_RanIt,_Base> std::operator +(_Diff,const std::_Revranit<_RanIt,_Base> &)' : could not deduce template argument for 'const std::_Revranit<_RanIt,_Base> &' from 'const char [6]'
1> c:\program files (x86)\microsoft visual studio 10.0\vc\include\xutility(1136) : see declaration of 'std::operator +'
1>c:\development\cinder\cinder\blocks\cinder-kinectsdk\samples\kinectapp\src\kinectapp.cpp(341): error C2676: binary '+' : 'boost::filesystem3::path' does not define this operator or a conversion to a type acceptable to the predefined operator
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:09.54
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
The Cinder-KinectSdk dev branch works well under the new Visual Studio 2012 (v110_xp compiler) and the new Cinder appRewrite. But when switching from the "Debug" build to "Release", the program compiles fine but throws an exception when running:
Unhandled exception at at 0x7674C41F in KinectProject.exe: Microsoft C++ exception: std::length_error at memory location 0x0018FCEC.
Call stack:
KernelBase.dll!_RaiseException@16�() Unknown
KinectProject.exe!00480adf() Unknown
[Frames below may be incorrect and/or missing, no symbols loaded for KinectProject.exe]
KinectProject.exe!004616ee() Unknown
KinectProject.exe!004240ee() Unknown
KinectProject.exe!00423e15() Unknown
KinectProject.exe!00424651() Unknown
KinectProject.exe!004815d4() Unknown
KinectProject.exe!004815d4() Unknown
KinectProject.exe!004b2f3b() Unknown
KinectProject.exe!004193ea() Unknown
KinectProject.exe!00415a23() Unknown
KinectProject.exe!004021a6() Unknown
KinectProject.exe!00480a0e() Unknown
kernel32.dll!@BaseThreadInitThunk@12�() Unknown
ntdll.dll!___RtlUserThreadStart@8�() Unknown
ntdll.dll!__RtlUserThreadStart@8�() Unknown
Hi,
I'm trying to pull in depth data at 640x480, and am getting a blank gl::Texture. With the same code, if I replace NUI_IMAGE_RESOLUTION_640x480
with NUI_IMAGE_RESOLUTION_320x240
, everything works as expected. Here's my setup code:
DeviceOptions opts;
opts.enableSkeletonTracking( false );
opts.enableColor( false );
opts.enableUserTracking( false );
opts.enableNearMode( false );
opts.enableDepth( true );
opts.setDepthResolution( NUI_IMAGE_RESOLUTION_320x240 );
int32_t numKinects = Kinect::getDeviceCount();
for ( int32_t i = 0; i < numKinects; ++i ) {
opts.setDeviceIndex( i );
Device device;
device.kinectRef = Kinect::create();
device.kinectRef->start( opts );
device.callbackId = device.kinectRef->addDepthCallback( &MyApp::onDepthData, this );
device.tex = gl::Texture( opts.getDepthSize().x, opts.getDepthSize().y );
devices.push_back( device );
}
I'm currently testing with only one Kinect attached. I debugged the Surface data in onDepthData
and there's nothing obviously out of place. The surface is the correct size, has a valid data pointer, and mRowBytes looks right. I've attached a screenshot of debugging the blank surface with 640x480 resolution.
I couldn't find any examples of actually using the depth stream at 640x480.
Any ideas of where I could look?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.