Showing preview only (541K chars total). Download the full file or copy to clipboard to get everything.
Repository: ofTheo/ofxKinect
Branch: master
Commit: ebb9075bcb5a
Files: 71
Total size: 515.5 KB
Directory structure:
gitextract_ut9eoanc/
├── .gitignore
├── LICENSE.txt
├── README.md
├── addon_config.mk
├── kinectExample/
│ ├── addons.make
│ └── src/
│ ├── main.cpp
│ ├── testApp.cpp
│ └── testApp.h
├── libs/
│ ├── libfreenect/
│ │ ├── APACHE20
│ │ ├── CONTRIB
│ │ ├── GPL2
│ │ ├── include/
│ │ │ ├── libfreenect-registration.h
│ │ │ └── libfreenect.h
│ │ ├── platform/
│ │ │ ├── linux/
│ │ │ │ └── udev/
│ │ │ │ ├── 51-kinect.rules
│ │ │ │ └── README
│ │ │ └── windows/
│ │ │ ├── README.TXT
│ │ │ ├── inf/
│ │ │ │ ├── xbox nui audio/
│ │ │ │ │ ├── Xbox_NUI_Audio.cat
│ │ │ │ │ ├── Xbox_NUI_Audio.inf
│ │ │ │ │ ├── amd64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── ia64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── libusb-win32-bin-README.txt
│ │ │ │ │ ├── license/
│ │ │ │ │ │ └── libusb-win32/
│ │ │ │ │ │ └── installer_license.txt
│ │ │ │ │ └── x86/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ ├── xbox nui camera/
│ │ │ │ │ ├── Xbox_NUI_Camera.cat
│ │ │ │ │ ├── Xbox_NUI_Camera.inf
│ │ │ │ │ ├── amd64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── ia64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── libusb-win32-bin-README.txt
│ │ │ │ │ ├── license/
│ │ │ │ │ │ └── libusb-win32/
│ │ │ │ │ │ └── installer_license.txt
│ │ │ │ │ └── x86/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ └── xbox nui motor/
│ │ │ │ ├── Xbox_NUI_Motor.cat
│ │ │ │ ├── Xbox_NUI_Motor.inf
│ │ │ │ ├── amd64/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ ├── ia64/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ ├── libusb-win32-bin-README.txt
│ │ │ │ ├── license/
│ │ │ │ │ └── libusb-win32/
│ │ │ │ │ └── installer_license.txt
│ │ │ │ └── x86/
│ │ │ │ └── libusb0.sys
│ │ │ ├── libusb10emu/
│ │ │ │ └── libusb-1.0/
│ │ │ │ ├── failguard.cpp
│ │ │ │ ├── failguard.h
│ │ │ │ ├── libusb.h
│ │ │ │ ├── libusbemu.cpp
│ │ │ │ ├── libusbemu_internal.h
│ │ │ │ ├── libusbemu_threads.h
│ │ │ │ └── libusbemu_threads_win32.h
│ │ │ ├── stdbool.h
│ │ │ └── unistd.h
│ │ └── src/
│ │ ├── cameras.c
│ │ ├── cameras.h
│ │ ├── core.c
│ │ ├── freenect_internal.h
│ │ ├── loader.h
│ │ ├── registration.c
│ │ ├── registration.h
│ │ ├── tilt.c
│ │ ├── usb_libusb10.c
│ │ └── usb_libusb10.h
│ ├── libusb-1.0/
│ │ ├── include/
│ │ │ └── libusb-1.0/
│ │ │ └── libusb.h
│ │ └── lib/
│ │ └── osx/
│ │ └── usb-1.0.a
│ └── libusb-win32/
│ ├── AUTHORS.txt
│ ├── COPYING_LGPL.txt
│ ├── README.txt
│ ├── include/
│ │ └── lusb0_usb.h
│ └── lib/
│ ├── vs/
│ │ ├── libusb.lib
│ │ └── libusbd.lib
│ └── win_cb/
│ ├── libusb.lib
│ └── libusbd.lib
├── scripts/
│ ├── update_freenect.sh
│ └── update_libusb-win32.sh
└── src/
├── ofxBase3DVideo.h
├── ofxKinect.cpp
└── ofxKinect.h
================================================
FILE CONTENTS
================================================
================================================
FILE: .gitignore
================================================
.svn/
obj/
bin/
build/
!data/
ipch/
# mac Finder index files
.DS_*
# mac apps
*.app*
# xcode user project files
*.pbxuser
*.perspectivev3
xcuserdata
*.mode1*v3
# codeblocks project files
*.depend
*.layout
*.cbTemp
# visual studio project files
*.vcxproj.user
*.suo
*.sdf
*.opensdf
================================================
FILE: LICENSE.txt
================================================
Copyright (c) 2010, 2011 ofxKinect Team
The MIT License <http://www.opensource.org/licenses/mit-license.php>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
================================================
FILE: README.md
================================================
ofxKinect
=========
**Note: As of OpenFrameworks 0.8.0, ofxKinect has been integrated into the OF core. All future development of this addon will take place in the [main OF Github repo](https://github.com/openframeworks/openFrameworks) so please log issues there.**
**This repo will be left for anyone supporting old (pre-0.8.0+) OF projects and will not be updated. The final master branch is compatible with OF 0.8.0.**
Copyright (c) 2010-2013 ofxKinect Team
MIT License.
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "LICENSE.txt," in this distribution.
See https://github.com/ofTheo/ofxKinect for documentation as well as the [OF forums](http://forum.openframeworks.cc/index.php).
This project uses [libfreenect](https://github.com/OpenKinect/libfreenect), copyrighted by the Open Kinect Project using the Apache License v2. See the file "APACHE20" in libs/libfreenect.
Description
-----------
ofxKinect is an Open Frameworks addon for the Xbox Kinect that runs on Mac OSX, Linux, and Windows.
OpenFrameworks is a cross platform open source toolkit for creative coding in C++.
[http://www.openframeworks.cc/](http://www.openframeworks.cc/)
#### NOTE: Xbox Kinect models > 1414 (1473, etc) or Kinect4Windows devices that have been plugged into an XBox will not work with ofxKinect on Mac OSX
If you have an Xbox Kinect model 1473+ or Kinect4Windows device and want to use it with ofxKinect on OSX, DO NOT plug it into an XBox! If you do, it will receive a firmware update which will cause it to freeze after about 20 secs with libfreenect/ofxKinect on OSX. Linux and Windows are fine. The [fix is in the works](https://github.com/OpenKinect/libfreenect/pull/325).
In the meantime, we suggest you get the *original* Xbox Kinect model 1414 and keep those new toys away from an XBox ...
Installation
------------
To use ofxKinect, first you need to download and install [Open Frameworks](https://github.com/openframeworks/openFrameworks).
To get a copy of the repository you can download the source from [http://github.com/ofTheo/ofxKinect](http://github.com/ofTheo/ofxKinect/) or, alternatively, you can use git clone:
<pre>
git clone git://github.com/ofTheo/ofxKinect.git
</pre>
The addon should sit in `openFrameworks/addons/ofxKinect/`.
#### Which version to use?
If you are using a stable version (0062, 007, ...) of OpenFrameworks then you want to use a git tag of ofxKinect for that version. You can select the tag in the Github menu or clone and check it out using git.
For example, the following commands will clone ofxKinect and switch to the OF 0062 tagged version:
<pre>
git clone git://github.com/ofTheo/ofxKinect.git
cd ofxKinect
git checkout 0062
</pre>
#### Using the latest ofxKinect
The master branch of ofxKinect will work with the current master of OpenFrameworks and can be considered unstable. The develop branch is used for testing new features and bugfixes before they are applied to master.
If you want to work with the latest unstable (still in development) ofxKinect, download the source from the develop branch [https://github.com/ofTheo/ofxKinect/tree/develop](https://github.com/ofTheo/ofxKinect/tree/develop) or via git clone:
<pre>
git clone git://github.com/ofTheo/ofxKinect.git -b develop
</pre>
Warning: The develop branch will be in flux, so don't be surprised if things do not always work as expected!
#### Bug: ofxKinect 0.7.4 + Windows CodeBlocks 12.11 missing pthread
If you're using Windows CodeBlocks 12.11 and OF/ofxKinect 0.7.4, you may see an issue where ofxKinect projects cannot compile/link due to missing the "pthread" library. This is due to CodeBlocks removing some built in libraries between versions 10.5 & 12.11.
The fix is to manually add the pthread-win32 library which provides "pthread".
First, make sure you've followed to "Add files to MinGW guide" in the [CodeBlocks 12.11 setup for OF guide](http://www.openframeworks.cc/setup/codeblocks/). Then, manually add pthreads-win32:
1. download the compiled version: http://www.sourceware.org/pthreads-win32/index.html
2. rename the lib file `Pre-built.2\lib\x86\libpthreadGC2.a` to `libpthread` and copy it into the MinGW folder for your CodeBlocks installation:
`C:\Program Files (x86)\CodeBlocks\MinGW\lib`
3. if they do not exist, copy the header (.h) files in `Pre-build.2\include` into your CodeBlocks installation: `C:\Program Files (x86)\CodeBlocks\MinGW\include`
Running the Example Project
---------------------------
An example project is provided in the `kinectExample` folder. As of OF 0.8.0, ofxKinect no longer ships with the platform project files. Simply use the OpenFrameworks ProjectGenerator in `apps/projectGenerator` to generate the Xcode, VS2012, CodeBlocks projects and/or Makefiles by pointing it to the `kinectExample` folder and making sure to include the following addons:
* ofxKinect (duh)
* ofxOpenCv (for blob tracking in the example, not required by ofxKinect itself.)
### OSX
Xcode4: Open the Xcode project, select the "kinectExample Debug" scheme, and hit "Run".
### Linux
Install the libusb-1.0 library. On Ubuntu, you can do this with:
<pre>
sudo apt-get install libusb-1.0-0-dev
</pre>
Open the Code::Blocks .cbp and hit F9 to build. Optionally, you can build the example with the Makefile.
To run it, use the terminal:
<pre>
make
cd bin
./example_debug
</pre>
Also, you can add a set of udev rules which allow you to run a kinect app without root privileges:
sudo libs\libfreenect\platform\linux\udev\51-kinect.rules /etc/udev/rules.d
### Windows
Precompiled libfreenect drivers and libusb-win32 libs are included for Windows.
Make sure to install or update the libfreenect Kinect camera, motor, and audio drivers through Windows Device Manager by pointing it to the driver folder:
<pre>
ofxKinect/libs/libfreenect/platform/windows/inf
</pre>
You may need to manually update each driver individually if you've plugged it in before. ofxKinect will not work if the drivers are not installed.
**NOTE**: You cannot use the OpenNI drivers and the libfreenect drivers included with ofxKinect at the same time. You must manually uninstall one and reinstall the other in the Device Manager. Sorry, that's just how it is. :P
How to Create a New ofxKinect Project
-------------------------------------
To develop your own project based on ofxKinect, simply copy the example project and rename it. You probably want to put it in your apps folder, for example, after copying:
`openFrameworks/addons/ofxKinect/kinectExample/ => openFrameworks/apps/myApps/kinectExample/`
Then after renaming:
`openFrameworks/apps/myApps/myKinectProject/`
### Mac (Xcode):
Rename the project in Xcode (do not rename the .xcodeproj file in Finder!): Slow double click the project name and rename (Xcode4)
### Codeblocks (Win & Linux):
Close Codeblocks and rename the *.cbp and *.workspace files to the same name as the project folder. Open the workspace and readd the renamed project file.
### Windows (Visual Studio):
Close Visual Studio and rename the *.sln file. Open the solution, right click on the project in the project browser and select "Rename ...".
Adding ofxKinect to an Existing Project
---------------------------------------
If you want to add ofxKinect to another project, you need to make sure you include the src folder and the :
<pre>
openFrameworks/addons/ofxKinect/src
</pre>
as well as search paths for the addons (ofxOpenCv) and libs (freenect, libusb) required by ofxKinect.
Don't forget to include the ofxOpenCv addon sources and opencv libraries.
### Mac (Xcode):
In the Xcode project browser:
* add the ofxKinect sources to the project:
* create a new group "ofxKinect"
* drag these directories from ofxKinect into this new group: ofxKinect/src & ofxKinect/libs
* add a search path to the libusb headers: `../../../addons/ofxKinect/libs/libusb/include/libusb-1.0` to your project Target build settings
* Xcode4: add the lib path to your Project.xconfig, see the example
* add the path to the libusb precompiled library: `../../../addons/ofxKinect/libs/libusb-1.0/lib/osx/usb-1.0.a`
* Xcode4: add the lib path to your Project.xconfig, see the example
### Linux (Makefiles & Codeblocks):
Edit the Makefile config files:
* edit addons.make in your project folder and add the following line to the end of the file:
<pre>ofxKinect</pre>
* edit config.make in your project folder and change the lines for USER_LIBS to:
<pre>
USER_LIBS = -lusb-1.0
</pre>
#### Windows (Visual Studio):
* add the ofxPd sources to the project:
* right click on the addons folder in your project tree and create a new filter named "ofxKinect"
* drag the src directory from the ofxKinect addon folder in Explorer into the ofxKinect folder in your project tree
* add header and library search paths:
* right lick on your project and select "Properties"
* choose "Debug" from the "Configurations" drop down box
* under C/C++->General, add the following to the "Additional Include Directories":
<pre>
..\\..\\..\addons\ofxKinect\src
..\\..\\..\addons\ofxKinect\libs\libfreenect\src
..\\..\\..\addons\ofxKinect\libs\libfreenect\include
..\\..\\..\addons\ofxKinect\libs\libfreenect\platform\windows
..\\..\\..\addons\ofxKinect\libs\libfreenect\platform\windows\libusb10emu\libusb-1.0
..\\..\\..\addons\ofxKinect\libs\libusb-win32\include
</pre>
* under Linker->General, add the following to the "Additional Library Directories":
<pre>
..\..\..\addons\ofxKinect\libs\libusb-win32\lib\vs
</pre>
* repeat for the "Release" configuration
#### Windows (Codeblocks):
* add the ofxPd sources to the project:
* right-click on your project in the project tree
* select "Add Files Recursively ..."
* navigate and choose the ofxKinect/src folder
* add search paths and libraries to link:
* right-click on your project in the project tree
* select "Build options..."
* make sure the project name is selected in the tree (not release or debug)
* select the "Search directories" tab, click add the search paths:
<pre>
..\\..\\..\addons\ofxKinect\src
..\\..\\..\addons\ofxKinect\libs\libfreenect\src
..\\..\\..\addons\ofxKinect\libs\libfreenect\include
..\\..\\..\addons\ofxKinect\libs\libfreenect\platform\windows
..\\..\\..\addons\ofxKinect\libs\libfreenect\platform\windows\libusb10emu\libusb-1.0
..\\..\\..\addons\ofxKinect\libs\libusb-win32\include
</pre>
* select the "Linker settings" tab, add the following to Link libraries:
<pre>
m
pthread
</pre>
* select the "Linker settings" tab, add the following to Other liker options:
<pre>
..\..\..\addons\ofxKinect\libs\libusb-win32\lib\win_cb\libusb.lib
</pre>
Notes
-----
### Using multiple kinects
ofxKinect supports multiple kinects, however stability is based on the bandwidth of your usb hardware. If you only require the depth image, it is recommended to disable the video grabbing of the rgb/ir images from your devices:
<pre>
kinect.init(false, false); // disable video image (faster fps)
</pre>
For Kinect4Windows, Microsoft states that only 2 Kinects can be supported on the same USB bus. In practice on OSX, this proves to be the case as, even with the RGB images disabled, there are transfer errors using ofxKinect and 3 Kinects simultaneously. If you need to support many Kinects, you will probably need to add extra USB controllers to your machine …
Developing ofxKinect
--------------------
Feel free to log bug reports and issues to the ofxKinect Github page: https://github.com/ofTheo/ofxKinect/issues
If you wish to help in ofxKinect development, please refer to the wiki: https://github.com/ofTheo/ofxKinect/wiki/Developing-ofxKinect
================================================
FILE: addon_config.mk
================================================
# All variables and this file are optional, if they are not present the PG and the
# makefiles will try to parse the correct values from the file system.
#
# Variables that specify exclusions can use % as a wildcard to specify that anything in
# that position will match. A partial path can also be specified to, for example, exclude
# a whole folder from the parsed paths from the file system
#
# Variables can be specified using = or +=
# = will clear the contents of that variable both specified from the file or the ones parsed
# from the file system
# += will add the values to the previous ones in the file or the ones parsed from the file
# system
#
# The PG can be used to detect errors in this file, just create a new project with this addon
# and the PG will write to the console the kind of error and in which line it is
meta:
ADDON_NAME = ofxKinect
ADDON_DESCRIPTION = Addon for interfacing with microsoft kinect cameras
ADDON_AUTHOR = Dan Wilcox, Theo Watson, Kyle McDonald, Arturo Castro
ADDON_TAGS = "computer vision" "3D sensing" "kinect"
ADDON_URL = http://github.com/ofTheo/ofxKinect
common:
# dependencies with other addons, a list of them separated by spaces
# or use += in several lines
# ADDON_DEPENDENCIES =
# include search paths, this will be usually parsed from the file system
# but if the addon or addon libraries need special search paths they can be
# specified here separated by spaces or one per line using +=
# ADDON_INCLUDES =
# any special flag that should be passed to the compiler when using this
# addon
# ADDON_CFLAGS =
# any special flag that should be passed to the linker when using this
# addon, also used for system libraries with -lname
# ADDON_LDFLAGS =
# linux only, any library that should be included in the project using
# pkg-config
# ADDON_PKG_CONFIG_LIBRARIES =
# osx/iOS only, any framework that should be included in the project
# ADDON_FRAMEWORKS =
# source files, these will be usually parsed from the file system looking
# in the src folders in libs and the root of the addon. if your addon needs
# to include files in different places or a different set of files per platform
# they can be specified here
# ADDON_SOURCES =
# some addons need resources to be copied to the bin/data folder of the project
# specify here any files that need to be copied, you can use wildcards like * and ?
# ADDON_DATA =
# when parsing the file system looking for libraries exclude this for all or
# a specific platform
# ADDON_LIBS_EXCLUDE =
# when parsing the file system looking for sources exclude this for all or
# a specific platform
# ADDON_SOURCES_EXCLUDE =
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
# ADDON_INCLUDES_EXCLUDE =
linux64:
# linux only, any library that should be included in the project using
# pkg-config
ADDON_PKG_CONFIG_LIBRARIES = libusb-1.0
# when parsing the file system looking for sources exclude this for all or
# a specific platform
ADDON_SOURCES_EXCLUDE = libs/libfreenect/platform/%
ADDON_SOURCES_EXCLUDE += libs/libusb-win32/%
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE = libs/libfreenect/platform/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-win32/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-1.0/%
linux:
# linux only, any library that should be included in the project using
# pkg-config
ADDON_PKG_CONFIG_LIBRARIES = libusb-1.0
# when parsing the file system looking for sources exclude this for all or
# a specific platform
ADDON_SOURCES_EXCLUDE = libs/libfreenect/platform/%
ADDON_SOURCES_EXCLUDE += libs/libusb-win32/%
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE = libs/libfreenect/platform/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-win32/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-1.0/%
win_cb:
# source files, these will be usually parsed from the file system looking
# in the src folders in libs and the root of the addon. if your addon needs
# to include files in different places or a different set of files per platform
# they can be specified here
ADDON_SOURCES += libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/failguard.cpp
ADDON_SOURCES += libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu.cpp
# include search paths, this will be usually parsed from the file system
# but if the addon or addon libraries need special search paths they can be
# specified here separated by spaces or one per line using +=
ADDON_INCLUDES += libs/libfreenect/platform/windows
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE += libs/libusb-1.0/%
vs:
# source files, these will be usually parsed from the file system looking
# in the src folders in libs and the root of the addon. if your addon needs
# to include files in different places or a different set of files per platform
# they can be specified here
ADDON_SOURCES += libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/failguard.cpp
ADDON_SOURCES += libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu.cpp
# include search paths, this will be usually parsed from the file system
# but if the addon or addon libraries need special search paths they can be
# specified here separated by spaces or one per line using +=
ADDON_INCLUDES += libs/libfreenect/platform/windows
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE += libs/libusb-1.0/%
linuxarmv6l:
# linux only, any library that should be included in the project using
# pkg-config
ADDON_PKG_CONFIG_LIBRARIES = libusb-1.0
# when parsing the file system looking for sources exclude this for all or
# a specific platform
ADDON_SOURCES_EXCLUDE = libs/libfreenect/platform/%
ADDON_SOURCES_EXCLUDE += libs/libusb-win32/%
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE = libs/libfreenect/platform/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-win32/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-1.0/%
linuxarmv7l:
# linux only, any library that should be included in the project using
# pkg-config
ADDON_PKG_CONFIG_LIBRARIES = libusb-1.0
# when parsing the file system looking for sources exclude this for all or
# a specific platform
ADDON_SOURCES_EXCLUDE = libs/libfreenect/platform/%
ADDON_SOURCES_EXCLUDE += libs/libusb-win32/%
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE = libs/libfreenect/platform/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-win32/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-1.0/%
android/armeabi:
android/armeabi-v7a:
osx:
# when parsing the file system looking for sources exclude this for all or
# a specific platform
ADDON_SOURCES_EXCLUDE = libs/libfreenect/platform/%
ADDON_SOURCES_EXCLUDE += libs/libusb-win32/%
# when parsing the file system looking for include paths exclude this for all or
# a specific platform
ADDON_INCLUDES_EXCLUDE = libs/libfreenect/platform/%
ADDON_INCLUDES_EXCLUDE += libs/libusb-win32/%
ios:
================================================
FILE: kinectExample/addons.make
================================================
ofxKinect
ofxOpenCv
================================================
FILE: kinectExample/src/main.cpp
================================================
#include "testApp.h"
#include "ofAppGlutWindow.h"
int main() {
ofAppGlutWindow window;
ofSetupOpenGL(&window, 1024, 768, OF_WINDOW);
ofRunApp(new testApp());
}
================================================
FILE: kinectExample/src/testApp.cpp
================================================
#include "testApp.h"
//--------------------------------------------------------------
void testApp::setup() {
ofSetLogLevel(OF_LOG_VERBOSE);
// enable depth->video image calibration
kinect.setRegistration(true);
kinect.init();
//kinect.init(true); // shows infrared instead of RGB video image
//kinect.init(false, false); // disable video image (faster fps)
kinect.open(); // opens first available kinect
//kinect.open(1); // open a kinect by id, starting with 0 (sorted by serial # lexicographically))
//kinect.open("A00362A08602047A"); // open a kinect using it's unique serial #
// print the intrinsic IR sensor values
if(kinect.isConnected()) {
ofLogNotice() << "sensor-emitter dist: " << kinect.getSensorEmitterDistance() << "cm";
ofLogNotice() << "sensor-camera dist: " << kinect.getSensorCameraDistance() << "cm";
ofLogNotice() << "zero plane pixel size: " << kinect.getZeroPlanePixelSize() << "mm";
ofLogNotice() << "zero plane dist: " << kinect.getZeroPlaneDistance() << "mm";
}
#ifdef USE_TWO_KINECTS
kinect2.init();
kinect2.open();
#endif
colorImg.allocate(kinect.width, kinect.height);
grayImage.allocate(kinect.width, kinect.height);
grayThreshNear.allocate(kinect.width, kinect.height);
grayThreshFar.allocate(kinect.width, kinect.height);
nearThreshold = 230;
farThreshold = 70;
bThreshWithOpenCV = true;
ofSetFrameRate(60);
// zero the tilt on startup
angle = 0;
kinect.setCameraTiltAngle(angle);
// start from the front
bDrawPointCloud = false;
}
//--------------------------------------------------------------
void testApp::update() {
ofBackground(100, 100, 100);
kinect.update();
// there is a new frame and we are connected
if(kinect.isFrameNew()) {
// load grayscale depth image from the kinect source
grayImage.setFromPixels(kinect.getDepthPixels(), kinect.width, kinect.height);
// we do two thresholds - one for the far plane and one for the near plane
// we then do a cvAnd to get the pixels which are a union of the two thresholds
if(bThreshWithOpenCV) {
grayThreshNear = grayImage;
grayThreshFar = grayImage;
grayThreshNear.threshold(nearThreshold, true);
grayThreshFar.threshold(farThreshold);
cvAnd(grayThreshNear.getCvImage(), grayThreshFar.getCvImage(), grayImage.getCvImage(), NULL);
} else {
// or we do it ourselves - show people how they can work with the pixels
unsigned char * pix = grayImage.getPixels();
int numPixels = grayImage.getWidth() * grayImage.getHeight();
for(int i = 0; i < numPixels; i++) {
if(pix[i] < nearThreshold && pix[i] > farThreshold) {
pix[i] = 255;
} else {
pix[i] = 0;
}
}
}
// update the cv images
grayImage.flagImageChanged();
// find contours which are between the size of 20 pixels and 1/3 the w*h pixels.
// also, find holes is set to true so we will get interior contours as well....
contourFinder.findContours(grayImage, 10, (kinect.width*kinect.height)/2, 20, false);
}
#ifdef USE_TWO_KINECTS
kinect2.update();
#endif
}
//--------------------------------------------------------------
void testApp::draw() {
ofSetColor(255, 255, 255);
if(bDrawPointCloud) {
easyCam.begin();
drawPointCloud();
easyCam.end();
} else {
// draw from the live kinect
kinect.drawDepth(10, 10, 400, 300);
kinect.draw(420, 10, 400, 300);
grayImage.draw(10, 320, 400, 300);
contourFinder.draw(10, 320, 400, 300);
#ifdef USE_TWO_KINECTS
kinect2.draw(420, 320, 400, 300);
#endif
}
// draw instructions
ofSetColor(255, 255, 255);
stringstream reportStream;
if(kinect.hasAccelControl()) {
reportStream << "accel is: " << ofToString(kinect.getMksAccel().x, 2) << " / "
<< ofToString(kinect.getMksAccel().y, 2) << " / "
<< ofToString(kinect.getMksAccel().z, 2) << endl;
} else {
reportStream << "Note: this is a newer Xbox Kinect or Kinect For Windows device," << endl
<< "motor / led / accel controls are not currently supported" << endl << endl;
}
reportStream << "press p to switch between images and point cloud, rotate the point cloud with the mouse" << endl
<< "using opencv threshold = " << bThreshWithOpenCV <<" (press spacebar)" << endl
<< "set near threshold " << nearThreshold << " (press: + -)" << endl
<< "set far threshold " << farThreshold << " (press: < >) num blobs found " << contourFinder.nBlobs
<< ", fps: " << ofGetFrameRate() << endl
<< "press c to close the connection and o to open it again, connection is: " << kinect.isConnected() << endl;
if(kinect.hasCamTiltControl()) {
reportStream << "press UP and DOWN to change the tilt angle: " << angle << " degrees" << endl
<< "press 1-5 & 0 to change the led mode" << endl;
}
ofDrawBitmapString(reportStream.str(), 20, 652);
}
void testApp::drawPointCloud() {
int w = 640;
int h = 480;
ofMesh mesh;
mesh.setMode(OF_PRIMITIVE_POINTS);
int step = 2;
for(int y = 0; y < h; y += step) {
for(int x = 0; x < w; x += step) {
if(kinect.getDistanceAt(x, y) > 0) {
mesh.addColor(kinect.getColorAt(x,y));
mesh.addVertex(kinect.getWorldCoordinateAt(x, y));
}
}
}
glPointSize(3);
ofPushMatrix();
// the projected points are 'upside down' and 'backwards'
ofScale(1, -1, -1);
ofTranslate(0, 0, -1000); // center the points a bit
glEnable(GL_DEPTH_TEST);
mesh.drawVertices();
glDisable(GL_DEPTH_TEST);
ofPopMatrix();
}
//--------------------------------------------------------------
void testApp::exit() {
kinect.setCameraTiltAngle(0); // zero the tilt on exit
kinect.close();
#ifdef USE_TWO_KINECTS
kinect2.close();
#endif
}
//--------------------------------------------------------------
void testApp::keyPressed (int key) {
switch (key) {
case ' ':
bThreshWithOpenCV = !bThreshWithOpenCV;
break;
case'p':
bDrawPointCloud = !bDrawPointCloud;
break;
case '>':
case '.':
farThreshold ++;
if (farThreshold > 255) farThreshold = 255;
break;
case '<':
case ',':
farThreshold --;
if (farThreshold < 0) farThreshold = 0;
break;
case '+':
case '=':
nearThreshold ++;
if (nearThreshold > 255) nearThreshold = 255;
break;
case '-':
nearThreshold --;
if (nearThreshold < 0) nearThreshold = 0;
break;
case 'w':
kinect.enableDepthNearValueWhite(!kinect.isDepthNearValueWhite());
break;
case 'o':
kinect.setCameraTiltAngle(angle); // go back to prev tilt
kinect.open();
break;
case 'c':
kinect.setCameraTiltAngle(0); // zero the tilt
kinect.close();
break;
case '1':
kinect.setLed(ofxKinect::LED_GREEN);
break;
case '2':
kinect.setLed(ofxKinect::LED_YELLOW);
break;
case '3':
kinect.setLed(ofxKinect::LED_RED);
break;
case '4':
kinect.setLed(ofxKinect::LED_BLINK_GREEN);
break;
case '5':
kinect.setLed(ofxKinect::LED_BLINK_YELLOW_RED);
break;
case '0':
kinect.setLed(ofxKinect::LED_OFF);
break;
case OF_KEY_UP:
angle++;
if(angle>30) angle=30;
kinect.setCameraTiltAngle(angle);
break;
case OF_KEY_DOWN:
angle--;
if(angle<-30) angle=-30;
kinect.setCameraTiltAngle(angle);
break;
}
}
//--------------------------------------------------------------
void testApp::mouseDragged(int x, int y, int button)
{}
//--------------------------------------------------------------
void testApp::mousePressed(int x, int y, int button)
{}
//--------------------------------------------------------------
void testApp::mouseReleased(int x, int y, int button)
{}
//--------------------------------------------------------------
void testApp::windowResized(int w, int h)
{}
================================================
FILE: kinectExample/src/testApp.h
================================================
#pragma once
#include "ofMain.h"
#include "ofxOpenCv.h"
#include "ofxKinect.h"
// Windows users:
// You MUST install the libfreenect kinect drivers in order to be able to use
// ofxKinect. Plug in the kinect and point your Windows Device Manager to the
// driver folder in:
//
// ofxKinect/libs/libfreenect/platform/windows/inf
//
// This should install the Kinect camera, motor, & audio drivers.
//
// You CANNOT use this driver and the OpenNI driver with the same device. You
// will have to manually update the kinect device to use the libfreenect drivers
// and/or uninstall/reinstall it in Device Manager.
//
// No way around the Windows driver dance, sorry.
// uncomment this to read from two kinects simultaneously
//#define USE_TWO_KINECTS
class testApp : public ofBaseApp {
public:
void setup();
void update();
void draw();
void exit();
void drawPointCloud();
void keyPressed(int key);
void mouseDragged(int x, int y, int button);
void mousePressed(int x, int y, int button);
void mouseReleased(int x, int y, int button);
void windowResized(int w, int h);
ofxKinect kinect;
#ifdef USE_TWO_KINECTS
ofxKinect kinect2;
#endif
ofxCvColorImage colorImg;
ofxCvGrayscaleImage grayImage; // grayscale depth image
ofxCvGrayscaleImage grayThreshNear; // the near thresholded image
ofxCvGrayscaleImage grayThreshFar; // the far thresholded image
ofxCvContourFinder contourFinder;
bool bThreshWithOpenCV;
bool bDrawPointCloud;
int nearThreshold;
int farThreshold;
int angle;
// used for viewing the point cloud
ofEasyCam easyCam;
};
================================================
FILE: libs/libfreenect/APACHE20
================================================
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
================================================
FILE: libs/libfreenect/CONTRIB
================================================
For a list of libfreenect authors, please see the Git history of the project,
such as with 'git log'. This file will contain a list of authors on release
snapshots of libfreenect.
THIS FILE IS NOT VALID FOR NON-GIT DISTRIBUTIONS. If you wish to redistribute
libfreenect source code outside of the Git infrastructure, you MUST either use
a release version or generate a complete CONTRIB file valid for the source Git
revision tree that you use for your distribution. Redistributions of libfreenect
source code without a valid CONTRIB file and without Git metadata are not
compliant with the license.
================================================
FILE: libs/libfreenect/GPL2
================================================
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Library General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.
================================================
FILE: libs/libfreenect/include/libfreenect-registration.h
================================================
/*
* This file is part of the OpenKinect Project. http://www.openkinect.org
*
* Copyright (c) 2011 individual OpenKinect contributors. See the CONTRIB file
* for details.
*
* This code is licensed to you under the terms of the Apache License, version
* 2.0, or, at your option, the terms of the GNU General Public License,
* version 2.0. See the APACHE20 and GPL2 files for the text of the licenses,
* or the following URLs:
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.gnu.org/licenses/gpl-2.0.txt
*
* If you redistribute this file in source form, modified or unmodified, you
* may:
* 1) Leave this header intact and distribute it under the same terms,
* accompanying it with the APACHE20 and GPL20 files, or
* 2) Delete the Apache 2.0 clause and accompany it with the GPL2 file, or
* 3) Delete the GPL v2 clause and accompany it with the APACHE20 file
* In all cases you must keep the copyright notice intact and include a copy
* of the CONTRIB file.
*
* Binary distributions must follow the binary distribution requirements of
* either License.
*/
#ifndef LIBFREENECT_REGISTRATION_H
#define LIBFREENECT_REGISTRATION_H
#include <libfreenect.h>
#include <stdint.h>
#ifdef __cplusplus
extern "C" {
#endif
/// Internal Kinect registration parameters.
/// Structure matches that of the line protocol
/// of the Kinect.
typedef struct {
int32_t dx_center; // not used by mapping algorithm
int32_t ax;
int32_t bx;
int32_t cx;
int32_t dx;
int32_t dx_start;
int32_t ay;
int32_t by;
int32_t cy;
int32_t dy;
int32_t dy_start;
int32_t dx_beta_start;
int32_t dy_beta_start;
int32_t rollout_blank; // not used by mapping algorithm
int32_t rollout_size; // not used by mapping algorithm
int32_t dx_beta_inc;
int32_t dy_beta_inc;
int32_t dxdx_start;
int32_t dxdy_start;
int32_t dydx_start;
int32_t dydy_start;
int32_t dxdxdx_start;
int32_t dydxdx_start;
int32_t dxdxdy_start;
int32_t dydxdy_start;
int32_t back_comp1; // not used by mapping algorithm
int32_t dydydx_start;
int32_t back_comp2; // not used by mapping algorithm
int32_t dydydy_start;
} freenect_reg_info;
/// registration padding info (?)
typedef struct {
uint16_t start_lines;
uint16_t end_lines;
uint16_t cropping_lines;
} freenect_reg_pad_info;
/// internal Kinect zero plane data
typedef struct {
float dcmos_emitter_dist; // Distance between IR camera and IR emitter, in cm.
float dcmos_rcmos_dist; // Distance between IR camera and RGB camera, in cm.
float reference_distance; // The focal length of the IR camera, in mm.
float reference_pixel_size; // The size of a single pixel on the zero plane, in mm.
} freenect_zero_plane_info;
/// all data needed for depth->RGB mapping
typedef struct {
freenect_reg_info reg_info;
freenect_reg_pad_info reg_pad_info;
freenect_zero_plane_info zero_plane_info;
double const_shift;
uint16_t* raw_to_mm_shift;
int32_t* depth_to_rgb_shift;
int32_t (*registration_table)[2]; // A table of 640*480 pairs of x,y values.
// Index first by pixel, then x:0 and y:1.
} freenect_registration;
// These allow clients to export registration parameters; proper docs will
// come later
FREENECTAPI freenect_registration freenect_copy_registration(freenect_device* dev);
FREENECTAPI int freenect_destroy_registration(freenect_registration* reg);
// convenience function to convert a single x-y coordinate pair from camera
// to world coordinates
FREENECTAPI void freenect_camera_to_world(freenect_device* dev,
int cx, int cy, int wz, double* wx, double* wy);
#ifdef __cplusplus
}
#endif
#endif // LIBFREENECT_REGISTRATION_H
================================================
FILE: libs/libfreenect/include/libfreenect.h
================================================
/*
* This file is part of the OpenKinect Project. http://www.openkinect.org
*
* Copyright (c) 2010 individual OpenKinect contributors. See the CONTRIB file
* for details.
*
* This code is licensed to you under the terms of the Apache License, version
* 2.0, or, at your option, the terms of the GNU General Public License,
* version 2.0. See the APACHE20 and GPL2 files for the text of the licenses,
* or the following URLs:
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.gnu.org/licenses/gpl-2.0.txt
*
* If you redistribute this file in source form, modified or unmodified, you
* may:
* 1) Leave this header intact and distribute it under the same terms,
* accompanying it with the APACHE20 and GPL20 files, or
* 2) Delete the Apache 2.0 clause and accompany it with the GPL2 file, or
* 3) Delete the GPL v2 clause and accompany it with the APACHE20 file
* In all cases you must keep the copyright notice intact and include a copy
* of the CONTRIB file.
*
* Binary distributions must follow the binary distribution requirements of
* either License.
*/
#ifndef LIBFREENECT_H
#define LIBFREENECT_H
#include <stdint.h>
/* We need struct timeval */
#ifdef _WIN32
#include <winsock.h>
#else
#include <sys/time.h>
#endif
#ifdef __cplusplus
extern "C" {
#endif
#define FREENECT_COUNTS_PER_G 819 /**< Ticks per G for accelerometer as set per http://www.kionix.com/Product%20Sheets/KXSD9%20Product%20Brief.pdf */
/// Maximum value that a uint16_t pixel will take on in the buffer of any of the FREENECT_DEPTH_MM or FREENECT_DEPTH_REGISTERED frame callbacks
#define FREENECT_DEPTH_MM_MAX_VALUE 10000
/// Value indicating that this pixel has no data, when using FREENECT_DEPTH_MM or FREENECT_DEPTH_REGISTERED depth modes
#define FREENECT_DEPTH_MM_NO_VALUE 0
/// Maximum value that a uint16_t pixel will take on in the buffer of any of the FREENECT_DEPTH_11BIT, FREENECT_DEPTH_10BIT, FREENECT_DEPTH_11BIT_PACKED, or FREENECT_DEPTH_10BIT_PACKED frame callbacks
#define FREENECT_DEPTH_RAW_MAX_VALUE 2048
/// Value indicating that this pixel has no data, when using FREENECT_DEPTH_11BIT, FREENECT_DEPTH_10BIT, FREENECT_DEPTH_11BIT_PACKED, or FREENECT_DEPTH_10BIT_PACKED
#define FREENECT_DEPTH_RAW_NO_VALUE 2047
/// Flags representing devices to open when freenect_open_device() is called.
/// In particular, this allows libfreenect to grab only a subset of the devices
/// in the Kinect, so you could (for instance) use libfreenect to handle audio
/// and motor support while letting OpenNI have access to the cameras.
/// If a device is not supported on a particular platform, its flag will be ignored.
typedef enum {
FREENECT_DEVICE_MOTOR = 0x01,
FREENECT_DEVICE_CAMERA = 0x02,
FREENECT_DEVICE_AUDIO = 0x04,
} freenect_device_flags;
/// A struct used in enumeration to give access to serial numbers, so you can
/// open a particular device by serial rather than depending on index. This
/// is most useful if you have more than one Kinect.
struct freenect_device_attributes;
struct freenect_device_attributes {
struct freenect_device_attributes *next; /**< Next device in the linked list */
const char* camera_serial; /**< Serial number of this device's camera subdevice */
};
/// Enumeration of available resolutions.
/// Not all available resolutions are actually supported for all video formats.
/// Frame modes may not perfectly match resolutions. For instance,
/// FREENECT_RESOLUTION_MEDIUM is 640x488 for the IR camera.
typedef enum {
FREENECT_RESOLUTION_LOW = 0, /**< QVGA - 320x240 */
FREENECT_RESOLUTION_MEDIUM = 1, /**< VGA - 640x480 */
FREENECT_RESOLUTION_HIGH = 2, /**< SXGA - 1280x1024 */
FREENECT_RESOLUTION_DUMMY = 2147483647, /**< Dummy value to force enum to be 32 bits wide */
} freenect_resolution;
/// Enumeration of video frame information states.
/// See http://openkinect.org/wiki/Protocol_Documentation#RGB_Camera for more information.
typedef enum {
FREENECT_VIDEO_RGB = 0, /**< Decompressed RGB mode (demosaicing done by libfreenect) */
FREENECT_VIDEO_BAYER = 1, /**< Bayer compressed mode (raw information from camera) */
FREENECT_VIDEO_IR_8BIT = 2, /**< 8-bit IR mode */
FREENECT_VIDEO_IR_10BIT = 3, /**< 10-bit IR mode */
FREENECT_VIDEO_IR_10BIT_PACKED = 4, /**< 10-bit packed IR mode */
FREENECT_VIDEO_YUV_RGB = 5, /**< YUV RGB mode */
FREENECT_VIDEO_YUV_RAW = 6, /**< YUV Raw mode */
FREENECT_VIDEO_DUMMY = 2147483647, /**< Dummy value to force enum to be 32 bits wide */
} freenect_video_format;
/// Enumeration of depth frame states
/// See http://openkinect.org/wiki/Protocol_Documentation#RGB_Camera for more information.
typedef enum {
FREENECT_DEPTH_11BIT = 0, /**< 11 bit depth information in one uint16_t/pixel */
FREENECT_DEPTH_10BIT = 1, /**< 10 bit depth information in one uint16_t/pixel */
FREENECT_DEPTH_11BIT_PACKED = 2, /**< 11 bit packed depth information */
FREENECT_DEPTH_10BIT_PACKED = 3, /**< 10 bit packed depth information */
FREENECT_DEPTH_REGISTERED = 4, /**< processed depth data in mm, aligned to 640x480 RGB */
FREENECT_DEPTH_MM = 5, /**< depth to each pixel in mm, but left unaligned to RGB image */
FREENECT_DEPTH_DUMMY = 2147483647, /**< Dummy value to force enum to be 32 bits wide */
} freenect_depth_format;
/// Structure to give information about the width, height, bitrate,
/// framerate, and buffer size of a frame in a particular mode, as
/// well as the total number of bytes needed to hold a single frame.
typedef struct {
uint32_t reserved; /**< unique ID used internally. The meaning of values may change without notice. Don't touch or depend on the contents of this field. We mean it. */
freenect_resolution resolution; /**< Resolution this freenect_frame_mode describes, should you want to find it again with freenect_find_*_frame_mode(). */
union {
int32_t dummy;
freenect_video_format video_format;
freenect_depth_format depth_format;
}; /**< The video or depth format that this freenect_frame_mode describes. The caller should know which of video_format or depth_format to use, since they called freenect_get_*_frame_mode() */
int32_t bytes; /**< Total buffer size in bytes to hold a single frame of data. Should be equivalent to width * height * (data_bits_per_pixel+padding_bits_per_pixel) / 8 */
int16_t width; /**< Width of the frame, in pixels */
int16_t height; /**< Height of the frame, in pixels */
int8_t data_bits_per_pixel; /**< Number of bits of information needed for each pixel */
int8_t padding_bits_per_pixel; /**< Number of bits of padding for alignment used for each pixel */
int8_t framerate; /**< Approximate expected frame rate, in Hz */
int8_t is_valid; /**< If 0, this freenect_frame_mode is invalid and does not describe a supported mode. Otherwise, the frame_mode is valid. */
} freenect_frame_mode;
/// Enumeration of LED states
/// See http://openkinect.org/wiki/Protocol_Documentation#Setting_LED for more information.
typedef enum {
LED_OFF = 0, /**< Turn LED off */
LED_GREEN = 1, /**< Turn LED to Green */
LED_RED = 2, /**< Turn LED to Red */
LED_YELLOW = 3, /**< Turn LED to Yellow */
LED_BLINK_GREEN = 4, /**< Make LED blink Green */
// 5 is same as 4, LED blink Green
LED_BLINK_RED_YELLOW = 6, /**< Make LED blink Red/Yellow */
} freenect_led_options;
/// Enumeration of tilt motor status
typedef enum {
TILT_STATUS_STOPPED = 0x00, /**< Tilt motor is stopped */
TILT_STATUS_LIMIT = 0x01, /**< Tilt motor has reached movement limit */
TILT_STATUS_MOVING = 0x04, /**< Tilt motor is currently moving to new position */
} freenect_tilt_status_code;
/// Data from the tilt motor and accelerometer
typedef struct {
int16_t accelerometer_x; /**< Raw accelerometer data for X-axis, see FREENECT_COUNTS_PER_G for conversion */
int16_t accelerometer_y; /**< Raw accelerometer data for Y-axis, see FREENECT_COUNTS_PER_G for conversion */
int16_t accelerometer_z; /**< Raw accelerometer data for Z-axis, see FREENECT_COUNTS_PER_G for conversion */
int8_t tilt_angle; /**< Raw tilt motor angle encoder information */
freenect_tilt_status_code tilt_status; /**< State of the tilt motor (stopped, moving, etc...) */
} freenect_raw_tilt_state;
struct _freenect_context;
typedef struct _freenect_context freenect_context; /**< Holds information about the usb context. */
struct _freenect_device;
typedef struct _freenect_device freenect_device; /**< Holds device information. */
// usb backend specific section
typedef void freenect_usb_context; /**< Holds libusb-1.0 context */
//
/// If Win32, export all functions for DLL usage
#ifndef _WIN32
#define FREENECTAPI /**< DLLExport information for windows, set to nothing on other platforms */
#else
/**< DLLExport information for windows, set to nothing on other platforms */
#ifdef __cplusplus
#define FREENECTAPI extern "C" __declspec(dllexport)
#else
// this is required when building from a Win32 port of gcc without being
// forced to compile all of the library files (.c) with g++...
#define FREENECTAPI __declspec(dllexport)
#endif
#endif
/// Enumeration of message logging levels
typedef enum {
FREENECT_LOG_FATAL = 0, /**< Log for crashing/non-recoverable errors */
FREENECT_LOG_ERROR, /**< Log for major errors */
FREENECT_LOG_WARNING, /**< Log for warning messages */
FREENECT_LOG_NOTICE, /**< Log for important messages */
FREENECT_LOG_INFO, /**< Log for normal messages */
FREENECT_LOG_DEBUG, /**< Log for useful development messages */
FREENECT_LOG_SPEW, /**< Log for slightly less useful messages */
FREENECT_LOG_FLOOD, /**< Log EVERYTHING. May slow performance. */
} freenect_loglevel;
/**
* Initialize a freenect context and do any setup required for
* platform specific USB libraries.
*
* @param ctx Address of pointer to freenect context struct to allocate and initialize
* @param usb_ctx USB context to initialize. Can be NULL if not using multiple contexts.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_init(freenect_context **ctx, freenect_usb_context *usb_ctx);
/**
* Closes the device if it is open, and frees the context
*
* @param ctx freenect context to close/free
*
* @return 0 on success
*/
FREENECTAPI int freenect_shutdown(freenect_context *ctx);
/// Typedef for logging callback functions
typedef void (*freenect_log_cb)(freenect_context *dev, freenect_loglevel level, const char *msg);
/**
* Set the log level for the specified freenect context
*
* @param ctx context to set log level for
* @param level log level to use (see freenect_loglevel enum)
*/
FREENECTAPI void freenect_set_log_level(freenect_context *ctx, freenect_loglevel level);
/**
* Callback for log messages (i.e. for rerouting to a file instead of
* stdout)
*
* @param ctx context to set log callback for
* @param cb callback function pointer
*/
FREENECTAPI void freenect_set_log_callback(freenect_context *ctx, freenect_log_cb cb);
/**
* Calls the platform specific usb event processor
*
* @param ctx context to process events for
*
* @return 0 on success, other values on error, platform/library dependant
*/
FREENECTAPI int freenect_process_events(freenect_context *ctx);
/**
* Calls the platform specific usb event processor until either an event occurs
* or the timeout parameter time has passed. If a zero timeval is passed, this
* function will handle any already-pending events, then return immediately.
*
* @param ctx Context to process events for
* @param timeout Pointer to a timeval containing the maximum amount of time to block waiting for events, or zero for nonblocking mode
*
* @return 0 on success, other values on error, platform/library dependant
*/
FREENECTAPI int freenect_process_events_timeout(freenect_context *ctx, struct timeval* timeout);
/**
* Return the number of kinect devices currently connected to the
* system
*
* @param ctx Context to access device count through
*
* @return Number of devices connected, < 0 on error
*/
FREENECTAPI int freenect_num_devices(freenect_context *ctx);
/**
* Scans for kinect devices and produces a linked list of their attributes
* (namely, serial numbers), returning the number of devices.
*
* @param ctx Context to scan for kinect devices with
* @param attribute_list Pointer to where this function will store the resultant linked list
*
* @return Number of devices connected, < 0 on error
*/
FREENECTAPI int freenect_list_device_attributes(freenect_context *ctx, struct freenect_device_attributes** attribute_list);
/**
* Free the linked list produced by freenect_list_device_attributes().
*
* @param attribute_list Linked list of attributes to free.
*/
FREENECTAPI void freenect_free_device_attributes(struct freenect_device_attributes* attribute_list);
/**
* Answer which subdevices this library supports. This is most useful for
* wrappers trying to determine whether the underlying library was built with
* audio support or not, so the wrapper can avoid calling functions that do not
* exist.
*
* @return Flags representing the subdevices that the library supports opening (see freenect_device_flags)
*/
FREENECTAPI int freenect_supported_subdevices(void);
/**
* Set which subdevices any subsequent calls to freenect_open_device()
* should open. This will not affect devices which have already been
* opened. The default behavior, should you choose not to call this
* function at all, is to open all supported subdevices - motor, cameras,
* and audio, if supported on the platform.
*
* @param ctx Context to set future subdevice selection for
* @param subdevs Flags representing the subdevices to select
*/
FREENECTAPI void freenect_select_subdevices(freenect_context *ctx, freenect_device_flags subdevs);
/**
* Returns the devices that are enabled after calls to freenect_open_device()
* On newer kinects the motor and audio are automatically disabled for now
*
* @param ctx Context to set future subdevice selection for
* @return Flags representing the subdevices that were actually opened (see freenect_device_flags)
*/
FREENECTAPI freenect_device_flags freenect_enabled_subdevices(freenect_context *ctx);
/**
* Opens a kinect device via a context. Index specifies the index of
* the device on the current state of the bus. Bus resets may cause
* indexes to shift.
*
* @param ctx Context to open device through
* @param dev Device structure to assign opened device to
* @param index Index of the device on the bus
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_open_device(freenect_context *ctx, freenect_device **dev, int index);
/**
* Opens a kinect device (via a context) associated with a particular camera
* subdevice serial number. This function will fail if no device with a
* matching serial number is found.
*
* @param ctx Context to open device through
* @param dev Device structure to assign opened device to
* @param camera_serial Null-terminated ASCII string containing the serial number of the camera subdevice in the device to open
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_open_device_by_camera_serial(freenect_context *ctx, freenect_device **dev, const char* camera_serial);
/**
* Closes a device that is currently open
*
* @param dev Device to close
*
* @return 0 on success
*/
FREENECTAPI int freenect_close_device(freenect_device *dev);
/**
* Set the device user data, for passing generic information into
* callbacks
*
* @param dev Device to attach user data to
* @param user User data to attach
*/
FREENECTAPI void freenect_set_user(freenect_device *dev, void *user);
/**
* Retrieve the pointer to user data from the device struct
*
* @param dev Device from which to get user data
*
* @return Pointer to user data
*/
FREENECTAPI void *freenect_get_user(freenect_device *dev);
/// Typedef for depth image received event callbacks
typedef void (*freenect_depth_cb)(freenect_device *dev, void *depth, uint32_t timestamp);
/// Typedef for video image received event callbacks
typedef void (*freenect_video_cb)(freenect_device *dev, void *video, uint32_t timestamp);
/**
* Set callback for depth information received event
*
* @param dev Device to set callback for
* @param cb Function pointer for processing depth information
*/
FREENECTAPI void freenect_set_depth_callback(freenect_device *dev, freenect_depth_cb cb);
/**
* Set callback for video information received event
*
* @param dev Device to set callback for
* @param cb Function pointer for processing video information
*/
FREENECTAPI void freenect_set_video_callback(freenect_device *dev, freenect_video_cb cb);
/**
* Set the buffer to store depth information to. Size of buffer is
* dependant on depth format. See FREENECT_DEPTH_*_SIZE defines for
* more information.
*
* @param dev Device to set depth buffer for.
* @param buf Buffer to store depth information to.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_set_depth_buffer(freenect_device *dev, void *buf);
/**
* Set the buffer to store depth information to. Size of buffer is
* dependant on video format. See FREENECT_VIDEO_*_SIZE defines for
* more information.
*
* @param dev Device to set video buffer for.
* @param buf Buffer to store video information to.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_set_video_buffer(freenect_device *dev, void *buf);
/**
* Start the depth information stream for a device.
*
* @param dev Device to start depth information stream for.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_start_depth(freenect_device *dev);
/**
* Start the video information stream for a device.
*
* @param dev Device to start video information stream for.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_start_video(freenect_device *dev);
/**
* Stop the depth information stream for a device
*
* @param dev Device to stop depth information stream on.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_stop_depth(freenect_device *dev);
/**
* Stop the video information stream for a device
*
* @param dev Device to stop video information stream on.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_stop_video(freenect_device *dev);
/**
* Updates the accelerometer state using a blocking control message
* call.
*
* @param dev Device to get accelerometer data from
*
* @return 0 on success, < 0 on error. Accelerometer data stored to
* device struct.
*/
FREENECTAPI int freenect_update_tilt_state(freenect_device *dev);
/**
* Retrieve the tilt state from a device
*
* @param dev Device to retrieve tilt state from
*
* @return The tilt state struct of the device
*/
FREENECTAPI freenect_raw_tilt_state* freenect_get_tilt_state(freenect_device *dev);
/**
* Return the tilt state, in degrees with respect to the horizon
*
* @param state The tilt state struct from a device
*
* @return Current degree of tilt of the device
*/
FREENECTAPI double freenect_get_tilt_degs(freenect_raw_tilt_state *state);
/**
* Set the tilt state of the device, in degrees with respect to the
* horizon. Uses blocking control message call to update
* device. Function return does not reflect state of device, device
* may still be moving to new position after the function returns. Use
* freenect_get_tilt_status() to find current movement state.
*
* @param dev Device to set tilt state
* @param angle Angle the device should tilt to
*
* @return 0 on success, < 0 on error.
*/
FREENECTAPI int freenect_set_tilt_degs(freenect_device *dev, double angle);
/**
* Return the movement state of the tilt motor (moving, stopped, etc...)
*
* @param state Raw state struct to get the tilt status code from
*
* @return Status code of the tilt device. See
* freenect_tilt_status_code enum for more info.
*/
FREENECTAPI freenect_tilt_status_code freenect_get_tilt_status(freenect_raw_tilt_state *state);
/**
* Set the state of the LED. Uses blocking control message call to
* update device.
*
* @param dev Device to set the LED state
* @param option LED state to set on device. See freenect_led_options enum.
*
* @return 0 on success, < 0 on error
*/
FREENECTAPI int freenect_set_led(freenect_device *dev, freenect_led_options option);
/**
* Get the axis-based gravity adjusted accelerometer state, as laid
* out via the accelerometer data sheet, which is available at
*
* http://www.kionix.com/Product%20Sheets/KXSD9%20Product%20Brief.pdf
*
* @param state State to extract accelerometer data from
* @param x Stores X-axis accelerometer state
* @param y Stores Y-axis accelerometer state
* @param z Stores Z-axis accelerometer state
*/
FREENECTAPI void freenect_get_mks_accel(freenect_raw_tilt_state *state, double* x, double* y, double* z);
/**
* Get the number of video camera modes supported by the driver. This includes both RGB and IR modes.
*
* @return Number of video modes supported by the driver
*/
FREENECTAPI int freenect_get_video_mode_count();
/**
* Get the frame descriptor of the nth supported video mode for the
* video camera.
*
* @param mode_num Which of the supported modes to return information about
*
* @return A freenect_frame_mode describing the nth video mode
*/
FREENECTAPI freenect_frame_mode freenect_get_video_mode(int mode_num);
/**
* Get the frame descriptor of the current video mode for the specified
* freenect device.
*
* @param dev Which device to return the currently-set video mode for
*
* @return A freenect_frame_mode describing the current video mode of the specified device
*/
FREENECTAPI freenect_frame_mode freenect_get_current_video_mode(freenect_device *dev);
/**
* Convenience function to return a mode descriptor matching the
* specified resolution and video camera pixel format, if one exists.
*
* @param res Resolution desired
* @param fmt Pixel format desired
*
* @return A freenect_frame_mode that matches the arguments specified, if such a valid mode exists; otherwise, an invalid freenect_frame_mode.
*/
FREENECTAPI freenect_frame_mode freenect_find_video_mode(freenect_resolution res, freenect_video_format fmt);
/**
* Sets the current video mode for the specified device. If the
* freenect_frame_mode specified is not one provided by the driver
* e.g. from freenect_get_video_mode() or freenect_find_video_mode()
* then behavior is undefined. The current video mode cannot be
* changed while streaming is active.
*
* @param dev Device for which to set the video mode
* @param mode Frame mode to set
*
* @return 0 on success, < 0 if error
*/
FREENECTAPI int freenect_set_video_mode(freenect_device* dev, freenect_frame_mode mode);
/**
* Get the number of depth camera modes supported by the driver. This includes both RGB and IR modes.
*
* @return Number of depth modes supported by the driver
*/
FREENECTAPI int freenect_get_depth_mode_count();
/**
* Get the frame descriptor of the nth supported depth mode for the
* depth camera.
*
* @param mode_num Which of the supported modes to return information about
*
* @return A freenect_frame_mode describing the nth depth mode
*/
FREENECTAPI freenect_frame_mode freenect_get_depth_mode(int mode_num);
/**
* Get the frame descriptor of the current depth mode for the specified
* freenect device.
*
* @param dev Which device to return the currently-set depth mode for
*
* @return A freenect_frame_mode describing the current depth mode of the specified device
*/
FREENECTAPI freenect_frame_mode freenect_get_current_depth_mode(freenect_device *dev);
/**
* Convenience function to return a mode descriptor matching the
* specified resolution and depth camera pixel format, if one exists.
*
* @param res Resolution desired
* @param fmt Pixel format desired
*
* @return A freenect_frame_mode that matches the arguments specified, if such a valid mode exists; otherwise, an invalid freenect_frame_mode.
*/
FREENECTAPI freenect_frame_mode freenect_find_depth_mode(freenect_resolution res, freenect_depth_format fmt);
/**
* Sets the current depth mode for the specified device. The mode
* cannot be changed while streaming is active.
*
* @param dev Device for which to set the depth mode
* @param mode Frame mode to set
*
* @return 0 on success, < 0 if error
*/
FREENECTAPI int freenect_set_depth_mode(freenect_device* dev, const freenect_frame_mode mode);
#ifdef __cplusplus
}
#endif
#endif //
================================================
FILE: libs/libfreenect/platform/linux/udev/51-kinect.rules
================================================
# ATTR{product}=="Xbox NUI Motor"
SUBSYSTEM=="usb", ATTR{idVendor}=="045e", ATTR{idProduct}=="02b0", MODE="0666"
# ATTR{product}=="Xbox NUI Audio"
SUBSYSTEM=="usb", ATTR{idVendor}=="045e", ATTR{idProduct}=="02ad", MODE="0666"
# ATTR{product}=="Xbox NUI Camera"
SUBSYSTEM=="usb", ATTR{idVendor}=="045e", ATTR{idProduct}=="02ae", MODE="0666"
================================================
FILE: libs/libfreenect/platform/linux/udev/README
================================================
Simply place this file in /etc/udev/rules.d and you'll no longer need
to run your apps as root.
================================================
FILE: libs/libfreenect/platform/windows/README.TXT
================================================
======================================================================================
SUMMARY
*******
1) libfreenect: incompatibilities with Visual C++
This section is here merely for historical reasons. All of the issues documented
here were already fixed in the libfreenect repository and CMake should be able to
produce a project that is ready to build libfreenect in Windows with Visual Studio.
Consider browsing this section if experiencing compilation issues under different
platforms, compilers and/or IDEs.
2) libusb-1.0 vs. libusbemu: Issues and Concept
The current port of libfreenect for Windows uses a libusb-1.0 emulation layer since
a proper port of libusb-1.0 for Windows is not yet available. Such emulation layer
allows Windows development to keep in sync with the official development branch of
libfreenect, without the need of dedicated drivers/implementations. This section
discusses why and how the current libfreenect Windows port moved in this direction.
3) libusbemu: Tips, Hints and Best Practices
The current status of libusbemu is quite reliable under normal usage circumstances,
but by no means stable: caution is advised. This section provides some guidelines
to avoid potential pitfalls and keep the application running safely under Windows.
They are simple and natural to follow, so they should not impose any special design
considerations for the application.
4) Overall performance of libfreenect in Windows
The current Windows port of libfreenect has some performance overhead over other
platforms and dedicated Win32 driver implementations due to the libusbemu module.
This section contains a benchmark scenario and a also a discussion on the results.
In short, the overhead is negligible and should not prevent anyone from using it.
======================================================================================
1) libfreenect source code: incompatibilities with Visual C++
**********************************************************
----------------------------------------------------------------------------------
Language issues: The Microsoft C compiler does not implement all the C99 standard.
----------------------------------------------------------------------------------
An attempt to compile the current libfreenect with Visual C++ will trigger a lot
of errors. A simple workaround is to tell Visual Studio to force compilation all the
".c" files within the project using the C++ compiler:
Project >> Properties >> C/C++ >> Advanced >> Compile As: Compile as C++ Code (/TP)
This will get rid of most errors, except those regarding implicit pointer casts.
Here are a few examples of such implicit pointer casts from within libfreenect:
tilt.c dev->raw_state.tilt_status = buf[9];
core.c *ctx = malloc(sizeof(freenect_context));
cameras.c strm->raw_buf = strm->proc_buf;
It seems that it is not possible to force Visual C++ to perform such implicit casts
(if anyone knows how, please share! :-)
Such implicit casts then have to be made explicit:
dev->raw_state.tilt_status = (freenect_tilt_status_code)buf[9];
*ctx = (freenect_context*)malloc(sizeof(freenect_context));
strm->raw_buf = (uint8_t*)strm->proc_buf;
Fortunately, they are not many, and it can be done in a couple of minutes.
This should impose a minimal burden to the Win32 repository maintainers.
NOTE: Sometimes, even when "Compile as C++ Code" is specified, the build will insist
on using the C-compiler to compile .c files (this happens with MSVC versions prior to
2010). To work around this, just set the "Compile As" to "Default", click "Apply" and
then set it back to "Compile as C++ Code (/TP)", click "Apply" and then "OK".
Another problem is that Visual C++ does not offer the <unistd.h> and <stdbool.h>
headers. However, they are pretty simple to be emulated; the <stdbool.h> will
actually be a dummy header because C++ already defines the "bool" type semantics,
while the <unistd.h> has to simply #include <stdint.h> and define the "ssize_t"
type. The implementation of these headers are located at:
"libfreenect\platform\windows"
NOTE: MSVC versions prior to 2010 do not provide the <stdint.h> header. An ISO C9x
compilant <stdint.h> header for such MSVC versions can be found at the wikipedia entry
of stdint.h (at the "External links" section of the page):
http://en.wikipedia.org/wiki/Stdint.h
or directly through this link:
http://msinttypes.googlecode.com/svn/trunk/stdint.h
A copy of such header will be also provided within libfreenect in the future.
The "freenect_internal.h" makes use of GCC's "__attribute__" keyword, and there is no
such a thing in Visual C++. Fortunately, this header is not exposed for the library
user and is just required during the library build. There are a few simple solutions
for this issue: a) remove this keyword or b) define a dummy macro for it.
Another issue is that since all .c files were forced to be compiled as C++ code,
the "libfreenect.h" header no longer requires the "#ifdef __cpluscplus extern C"
idiom. Commenting out this guard will do the trick, but better checking is possible.
-----------------------------------------------------------------------------------
Library issues: libfreenect uses libusb-1.0 which is not yet available for Windows.
-----------------------------------------------------------------------------------
The final issue is regarding the default USB back-end used by libfreenect, libusb-1.0,
which is not yet available for Windows. This restriction forces the Windows port of
libfreenect to implement its own back-end, which then splits the Windows port from the
main development branch of libfreenect as new device features are reverse-engineered
and added to the library. Fortunately, such restriction can be alleviated through the
libusb-1.0 API "emulator" and keep the Windows port in sync with the current status of
libfreenect. More on this subject in the following section.
======================================================================================
2) libusb-1.0 vs. libusbemu: Issues and Concept
********************************************
The libfreenect uses libusb-1.0 as its default USB back-end to communicate with Kinect
but libusb-1.0 is not yet available for Windows. The current libusb-1.0 implementation
for Windows is experimental and uses WinUSB as its USB back-end. Unfortunately, WinUSB
does not support isochronous transfers, rendering it useless for Kinect purposes.
However, all is not lost since the latest version of libusb-win32 has support for the
isochronous transfers imposed by Kinect. There are issues too: libusb-win32 is based
on the old libusb-0.1 API which is incompatible with the libusb-1.0 API. Some of the
initial efforts to port libfreenect to Windows were based on the libusb-win32, being
Zephod's Win32 Kinect driver prototype a well-known instance:
http://ajaxorg.posterous.com/kinect-driver-for-windows-prototype
The problem with a dedicated libusb-win32 driver implementation is that it has to be
maintained separately from the current libfreenect development. As new Kinect features
are reverse-engineered and implemented in the official libfreenect branch, the Windows
port requires additional maintenance to keep it in sync with the newest updates, even
when such updates don't involve USB communication at all.
One could argue that libfreenect should abandon the use of libusb-1.0 and just adopt
the old libusb-0.1 instead, since it is has support in a wider range of platforms...
This is out of question! First of all, libusb-0.1 still exists for legacy reasons, and
it is highly recommended to move to the new API if possible. Moreover, libusb-0.1 does
not have built-in support for asynchronous transfers, which would force libfreenect to
hold and manage threads internally, which would then lead to a whole set of new issues
that are prone to hurt performance, maintainability and portability.
Fortunately, libfreenect only requires a small portion of the libusb-1.0 API, and such
subset can be emulated, at some extent, through what is provided from libusb-win32. As
a result, the burden of maintaining dedicated development branches for a Windows port
is eliminated and the port can keep in synch with updates made in the libfreenect. One
may now ask: how can libusb-win32 be of any help if it is based on the libusb-0.1 API,
which has no support for asynchronous transfers? Well, that's because it happens that
libusb-win32 is more than just a Win32 build of libusb-0.1: it is a special branch of
the 0.1 API that extends it to allow asynchronous transfers.
The normal execution flow of libfreenect is something like this:
Application <-> libfreenect <-> libusb-1.0 <-> Kinect
In Windows, the flow is as follows:
Application <-> libfreenect <-> libusb-1.0-emu <-> libusb-win32 <-> Kinect
The source code of the emulation layer is available at:
libfreenect\platform\windows\libusb10emu\libusb-1.0
Keep in mind that libusb-win32 is still required, and can be downloaded from:
http://sourceforge.net/apps/trac/libusb-win32/wiki
The latest snapshots are recommended, obtained directly from this URL:
http://sourceforge.net/projects/libusb-win32/files/libusb-win32-snapshots
Emulation of libusb-1.0 on top of libusb-win32 is not trivial, in special because of
some Windows-specific issues. There will be performance overhead, but as discussed in
the "Overall Performance" section, this should not hurt the application performance at
significant levels. Moreover, although the libusbemu is currently quite reliable, it
is by no means stable and on par to the real libusb-1.0 semantics. Caution is advised,
so be sure to read the following section for some usage considerations.
The libusbemu sits completely hidden behind libfreenect: the application does not need
to worry or call any special functions. In fact the application is not even aware that
libusbemu exists.
======================================================================================
3) libusbemu: Tips, Hints and Best Practices
*****************************************
---------------------------------------------------------------
TIP: Trigger the Fail Guard if the system becomes unresponsive.
---------------------------------------------------------------
Since libusbemu is quite experimental, there is a fail guard within it. If for some
reason your system renders unresponsive, try focusing any window of the application
and hold [CTRL] + [ALT] for a while.
This will trigger a special synchronization event within the libusbemu which will
interrupt the execution of any internal thread of libusbemu and prompt a message box
to the user asking for action. You can either resume execution (if you unintentionally
pressed [CTRL] + [ALT] in the console window) or abort libusbemu. The fail guard will
never trigger if there is no incoming video or depth streams.
The Fail Guard is important since in such situations one would most likely be forced
to shutdown the computer (in a not so graceful way, by holding the power button!).
----------------------------------------
TIP: Only use a single freenect context.
----------------------------------------
Multiple freenect contexts should be no problem in the future. Having more than one
device attached to the same context should work fine, but no tests were made so far.
-----------------------------------------------------
TIP: Yield the rendering thread after each iteration.
-----------------------------------------------------
In case your application performs direct rendering (OpenGL, Direct3D), it is highly
recommended to yield the rendering thread after finishing rendering each frame. This
can alleviate a lot of CPU usage. The ideal place for this yield is right after the
swap-buffers call (SwapBuffers(), glutSwapBuffers(), Present(), etc). The best way to
yield is by calling Sleep(1). Note that Sleep(0) is also possible, but the former is
more "democratic".
Note that some graphics drivers or platforms may already yield after swap-buffers.
This seems to be the case with OpenGL NVIDIA drivers for Linux. In Windows, however,
the same driver (version) does not yield. Maybe in Linux the "yielder" is not the
driver itself, but the underlying implementation of glXSwapBuffers()... Anyway, when
in doubt, it will not hurt to explicitly yield again.
--------------------------------------------------------------------------------------
TIP: Perform stream operations only in the thread that calls freenect_process_events()
--------------------------------------------------------------------------------------
By stream operations I mean these:
freenect_start_video()
freenect_start_depth()
freenect_stop_video()
freenect_stop_depth()
This tip seems to hold for other platforms as well, and it is respected through all of
the official libfreenect examples and should be of no burden for the application. This
may be due to the underlying semantics of the real libusb-1.0. Unfortunately, although
libusb-1.0 has an excellent API documentation it lacks on a proper specification, thus
difficulting the task of checking if this is indeed a restriction.
In summary, a typical libfreenect application (check the official examples) will have
a dedicated thread that calls freenect_process_events(). This function is responsible
for querying and dispatching incoming streams (a.k.a. video and depth frames) from the
Kinect device to the application (behind the scenes is a call the libusb-1.0 function
libusb_handle_events()) and it is advised that any stream operation intended by the
application (like switching to some different video format) should happen within the
thread that calls the freenect_process_events(). The official libfreenect examples do
this, so be sure to check their source code if confused. It is also advised to have
only one thread calling freenect_handle_events().
Interestingly, some tests were made with both the libusb-1.0 and libusbemu and mixing
stream operations in different threads seem to work well. However, no guarantees are
given if executed in such a fashion. Again, libusb-1.0 has no specification document
and if such behavior is really to be expected is a hard task to determine.
======================================================================================
4) Overall performance of libfreenect in Windows
*********************************************
---------------------------------------------
THIS SECTION IS OUTDATED, GOTTA REDO IT SOON!
---------------------------------------------
Hardware:
* Notebook
* CPU: Intel Core2 Duo 32bit [T7250] @ 2.0GHz
* RAM: 4GB RAM
* GPU: GeForce 8600M GT 256MB VRAM
Task: display of simultaneous RGB (Bayer-to-RGB) and depth streams (16bit unpadded) on
the screen through OpenGL textures. Application source code is identical for all tests
(except for the Zephod's version that required some interface adaptation).
Results: performance measurements refer to the average frame time (one loop iteration).
Linux: Ubuntu Notebook 10.10 -- gcc 4.4.5
* Debug: 1.22ms | CPU @ 77% | video @ 30Hz | depth @ 30Hz
* Release: 1.15ms | CPU @ 72% | video @ 30Hz | depth @ 30Hz
Win32: Windows 7 Enterprise 32bit -- VC++ (Professional) 2010
1) libfreenect with libusbemu:
* Debug: 2.44ms | CPU @ 75% | video @ 30Hz | depth @ 30Hz
* Release: 1.93ms | CPU @ 63% | video @ 30Hz | depth @ 30Hz
2) Zephod's dedicated driver (V16):
* Debug: 2.87ms | CPU @ 82% | video @ 30Hz | depth @ 30Hz
* Release: 2.55ms | CPU @ 77% | video @ 30Hz | depth @ 30Hz
Remarks:
Debug builds account for the library itself being built in Debug mode (libfreenect or
Zaphod's driver, whichever applies). Release builds also imply that the program was
started without any debug information embedded.
In Windows, time was measured through the Win32 exclusive QueryPerformanceFrequency()
and QueryPerformanceCounter() routines. In Linux, the measurement was performed via
POSIX gettime() function.
A Win32 MinGW-based (gcc/g++ 4.5.0) build of libfreenect with libusbemu using POSIX
gettime() also yielded to nearly identical performance results than VC++ 2010 with
Performance Counters.
All of the Win32 performance results were also double-checked with Fraps.
In Windows, a single thread yield call was placed after rendering each screen frame
(as recommended in Item 3-3). In Linux, the graphics driver - possibly glXSwapBuffers
itself - seems to be already yielding the rendering thread, and forcing it in the code
did not incur into any extra impact on performance.
Discussion:
Even though there are no streaming frequency discrepancies between platforms, one may
infer, just from the frame times, that Windows clearly has an overhead disadvantage.
However, this does not hold true: there is still plenty of time for the application
logic to run.
For a steady 60FPS (~16.66ms per frame) real-time performance, a Release build using
libusbemu in Windows would still have about 14.70ms per frame available for the client
code, while in Linux the available time would be around 15.50ms, a 0.8ms overhead
between the platforms. Such a small difference should not impose any special design
considerations for the client code.
Furthermore, note that the CPU usage in Windows tend to be lower than in Linux. The
reason behind this difference is quite difficult to summarize here, but it is probably
related to the way Windows and Linux perform asynchronous I/O in USB-mapped files.
The interested reader is encouraged to refer to the following links:
> http://www.unwesen.de/articles/waitformultipleobjects_considered_expensive
> http://softwarecommunity.intel.com/articles/eng/2807.htm
> http://software.intel.com/en-us/blogs/2006/10/19/why-windows-threads-are-better-than-posix-threads/
The memory consumption overhead of libusbemu in Windows is negligible, and as far as
the VC++ memory leak detection goes, libusbemu has no memory leaks.
======================================================================================
================================================
FILE: libs/libfreenect/platform/windows/inf/xbox nui audio/libusb-win32-bin-README.txt
================================================
libusb-win32-bin v1.2.2.0 (10/02/2010) - [Package Information]
ALL ARCHITECTURES:
x86\libusb0_x86.dll: x86 32-bit library. Must be renamed to libusb0.dll
On 64 bit, Installs to Windows\syswow64\libusb0.dll.
On 32 bit, Installs to Windows\system32\libusb0.dll.
x86\inf-wizard.exe: inf-wizard application with embedded libusb-win32
v1.2.2.0 binaries.
X86 ONLY ARCHITECTURES:
x86\libusb0.sys: x86 32-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
AMD64-INTEL64 ONLY ARCHITECTURES:
amd64\libusb0.sys: x64 64-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
amd64\libusb0.dll: x64 64-bit library.
Installs to Windows\system32\libusb0.dll
IA64 ONLY ARCHITECTURES:
ia64\libusb0.sys: IA64 64-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
ia64\libusb0.dll: IA64 64-bit library.
Installs to Windows\system32\libusb0.dll
================================================
FILE: libs/libfreenect/platform/windows/inf/xbox nui audio/license/libusb-win32/installer_license.txt
================================================
Copyright (c) 2002-2004 Stephan Meyer, <ste_meyer@web.de>
Copyright (c) 2000-2004 Johannes Erdfelt, <johannes@erdfelt.com>
Copyright (c) 2000-2004 Thomas Sailer, <sailer@ife.ee.ethz.ch>
Copyright (c) 2010 Travis Robinson, <libusbdotnet@gmail.com>
This software is distributed under the following licenses:
Driver: GNU General Public License (GPL)
Library, Test Files, Installer: GNU Lesser General Public License (LGPL)
***********************************************************************
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
<program> Copyright (C) <year> <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
================================================
FILE: libs/libfreenect/platform/windows/inf/xbox nui camera/libusb-win32-bin-README.txt
================================================
libusb-win32-bin v1.2.2.0 (10/02/2010) - [Package Information]
ALL ARCHITECTURES:
x86\libusb0_x86.dll: x86 32-bit library. Must be renamed to libusb0.dll
On 64 bit, Installs to Windows\syswow64\libusb0.dll.
On 32 bit, Installs to Windows\system32\libusb0.dll.
x86\inf-wizard.exe: inf-wizard application with embedded libusb-win32
v1.2.2.0 binaries.
X86 ONLY ARCHITECTURES:
x86\libusb0.sys: x86 32-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
AMD64-INTEL64 ONLY ARCHITECTURES:
amd64\libusb0.sys: x64 64-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
amd64\libusb0.dll: x64 64-bit library.
Installs to Windows\system32\libusb0.dll
IA64 ONLY ARCHITECTURES:
ia64\libusb0.sys: IA64 64-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
ia64\libusb0.dll: IA64 64-bit library.
Installs to Windows\system32\libusb0.dll
================================================
FILE: libs/libfreenect/platform/windows/inf/xbox nui camera/license/libusb-win32/installer_license.txt
================================================
Copyright (c) 2002-2004 Stephan Meyer, <ste_meyer@web.de>
Copyright (c) 2000-2004 Johannes Erdfelt, <johannes@erdfelt.com>
Copyright (c) 2000-2004 Thomas Sailer, <sailer@ife.ee.ethz.ch>
Copyright (c) 2010 Travis Robinson, <libusbdotnet@gmail.com>
This software is distributed under the following licenses:
Driver: GNU General Public License (GPL)
Library, Test Files, Installer: GNU Lesser General Public License (LGPL)
***********************************************************************
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
<program> Copyright (C) <year> <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
================================================
FILE: libs/libfreenect/platform/windows/inf/xbox nui motor/libusb-win32-bin-README.txt
================================================
libusb-win32-bin v1.2.2.0 (10/02/2010) - [Package Information]
ALL ARCHITECTURES:
x86\libusb0_x86.dll: x86 32-bit library. Must be renamed to libusb0.dll
On 64 bit, Installs to Windows\syswow64\libusb0.dll.
On 32 bit, Installs to Windows\system32\libusb0.dll.
x86\inf-wizard.exe: inf-wizard application with embedded libusb-win32
v1.2.2.0 binaries.
X86 ONLY ARCHITECTURES:
x86\libusb0.sys: x86 32-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
AMD64-INTEL64 ONLY ARCHITECTURES:
amd64\libusb0.sys: x64 64-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
amd64\libusb0.dll: x64 64-bit library.
Installs to Windows\system32\libusb0.dll
IA64 ONLY ARCHITECTURES:
ia64\libusb0.sys: IA64 64-bit driver.
Installs to Windows\system32\drivers\libusb0.sys
ia64\libusb0.dll: IA64 64-bit library.
Installs to Windows\system32\libusb0.dll
================================================
FILE: libs/libfreenect/platform/windows/inf/xbox nui motor/license/libusb-win32/installer_license.txt
================================================
Copyright (c) 2002-2004 Stephan Meyer, <ste_meyer@web.de>
Copyright (c) 2000-2004 Johannes Erdfelt, <johannes@erdfelt.com>
Copyright (c) 2000-2004 Thomas Sailer, <sailer@ife.ee.ethz.ch>
Copyright (c) 2010 Travis Robinson, <libusbdotnet@gmail.com>
T
gitextract_ut9eoanc/
├── .gitignore
├── LICENSE.txt
├── README.md
├── addon_config.mk
├── kinectExample/
│ ├── addons.make
│ └── src/
│ ├── main.cpp
│ ├── testApp.cpp
│ └── testApp.h
├── libs/
│ ├── libfreenect/
│ │ ├── APACHE20
│ │ ├── CONTRIB
│ │ ├── GPL2
│ │ ├── include/
│ │ │ ├── libfreenect-registration.h
│ │ │ └── libfreenect.h
│ │ ├── platform/
│ │ │ ├── linux/
│ │ │ │ └── udev/
│ │ │ │ ├── 51-kinect.rules
│ │ │ │ └── README
│ │ │ └── windows/
│ │ │ ├── README.TXT
│ │ │ ├── inf/
│ │ │ │ ├── xbox nui audio/
│ │ │ │ │ ├── Xbox_NUI_Audio.cat
│ │ │ │ │ ├── Xbox_NUI_Audio.inf
│ │ │ │ │ ├── amd64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── ia64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── libusb-win32-bin-README.txt
│ │ │ │ │ ├── license/
│ │ │ │ │ │ └── libusb-win32/
│ │ │ │ │ │ └── installer_license.txt
│ │ │ │ │ └── x86/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ ├── xbox nui camera/
│ │ │ │ │ ├── Xbox_NUI_Camera.cat
│ │ │ │ │ ├── Xbox_NUI_Camera.inf
│ │ │ │ │ ├── amd64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── ia64/
│ │ │ │ │ │ └── libusb0.sys
│ │ │ │ │ ├── libusb-win32-bin-README.txt
│ │ │ │ │ ├── license/
│ │ │ │ │ │ └── libusb-win32/
│ │ │ │ │ │ └── installer_license.txt
│ │ │ │ │ └── x86/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ └── xbox nui motor/
│ │ │ │ ├── Xbox_NUI_Motor.cat
│ │ │ │ ├── Xbox_NUI_Motor.inf
│ │ │ │ ├── amd64/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ ├── ia64/
│ │ │ │ │ └── libusb0.sys
│ │ │ │ ├── libusb-win32-bin-README.txt
│ │ │ │ ├── license/
│ │ │ │ │ └── libusb-win32/
│ │ │ │ │ └── installer_license.txt
│ │ │ │ └── x86/
│ │ │ │ └── libusb0.sys
│ │ │ ├── libusb10emu/
│ │ │ │ └── libusb-1.0/
│ │ │ │ ├── failguard.cpp
│ │ │ │ ├── failguard.h
│ │ │ │ ├── libusb.h
│ │ │ │ ├── libusbemu.cpp
│ │ │ │ ├── libusbemu_internal.h
│ │ │ │ ├── libusbemu_threads.h
│ │ │ │ └── libusbemu_threads_win32.h
│ │ │ ├── stdbool.h
│ │ │ └── unistd.h
│ │ └── src/
│ │ ├── cameras.c
│ │ ├── cameras.h
│ │ ├── core.c
│ │ ├── freenect_internal.h
│ │ ├── loader.h
│ │ ├── registration.c
│ │ ├── registration.h
│ │ ├── tilt.c
│ │ ├── usb_libusb10.c
│ │ └── usb_libusb10.h
│ ├── libusb-1.0/
│ │ ├── include/
│ │ │ └── libusb-1.0/
│ │ │ └── libusb.h
│ │ └── lib/
│ │ └── osx/
│ │ └── usb-1.0.a
│ └── libusb-win32/
│ ├── AUTHORS.txt
│ ├── COPYING_LGPL.txt
│ ├── README.txt
│ ├── include/
│ │ └── lusb0_usb.h
│ └── lib/
│ ├── vs/
│ │ ├── libusb.lib
│ │ └── libusbd.lib
│ └── win_cb/
│ ├── libusb.lib
│ └── libusbd.lib
├── scripts/
│ ├── update_freenect.sh
│ └── update_libusb-win32.sh
└── src/
├── ofxBase3DVideo.h
├── ofxKinect.cpp
└── ofxKinect.h
SYMBOL INDEX (322 symbols across 24 files)
FILE: kinectExample/src/main.cpp
function main (line 4) | int main() {
FILE: kinectExample/src/testApp.h
function class (line 25) | class testApp : public ofBaseApp {
FILE: libs/libfreenect/include/libfreenect-registration.h
type freenect_reg_info (line 40) | typedef struct {
type freenect_reg_pad_info (line 86) | typedef struct {
type freenect_zero_plane_info (line 93) | typedef struct {
type freenect_registration (line 101) | typedef struct {
FILE: libs/libfreenect/include/libfreenect.h
type freenect_device_flags (line 59) | typedef enum {
type freenect_device_attributes (line 68) | struct freenect_device_attributes
type freenect_device_attributes (line 69) | struct freenect_device_attributes {
type freenect_resolution (line 78) | typedef enum {
type freenect_video_format (line 87) | typedef enum {
type freenect_depth_format (line 100) | typedef enum {
type freenect_frame_mode (line 113) | typedef struct {
type freenect_led_options (line 132) | typedef enum {
type freenect_tilt_status_code (line 144) | typedef enum {
type freenect_raw_tilt_state (line 151) | typedef struct {
type _freenect_context (line 159) | struct _freenect_context
type freenect_context (line 160) | typedef struct _freenect_context freenect_context;
type _freenect_device (line 162) | struct _freenect_device
type freenect_device (line 163) | typedef struct _freenect_device freenect_device;
type freenect_usb_context (line 166) | typedef void freenect_usb_context;
type freenect_loglevel (line 184) | typedef enum {
type timeval (line 254) | struct timeval
type freenect_device_attributes (line 275) | struct freenect_device_attributes
type freenect_device_attributes (line 282) | struct freenect_device_attributes
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/failguard.cpp
type libusbemu (line 6) | namespace libusbemu
type failguard (line 9) | namespace failguard
function Check (line 16) | const bool Check()
function WaitDecision (line 41) | void WaitDecision()
function Abort (line 46) | const bool Abort()
function ThreadFailGuardProc (line 57) | int ThreadFailGuardProc(void* params)
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/failguard.h
function namespace (line 4) | namespace libusbemu
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusb.h
type libusb_context_t (line 58) | struct libusb_context_t
type libusb_context (line 60) | typedef struct libusb_context_t libusb_context;
type libusb_device_t (line 65) | struct libusb_device_t
type libusb_device (line 66) | typedef struct libusb_device_t libusb_device;
type libusb_device_descriptor (line 70) | struct libusb_device_descriptor
type libusb_device_handle_t (line 72) | struct libusb_device_handle_t
type libusb_device_handle (line 73) | typedef struct libusb_device_handle_t libusb_device_handle;
type libusb_transfer (line 92) | struct libusb_transfer
type libusb_transfer (line 93) | struct libusb_transfer
type libusb_transfer (line 95) | struct libusb_transfer
type libusb_transfer (line 96) | struct libusb_transfer
type libusb_transfer (line 97) | struct libusb_transfer
type libusb_transfer (line 99) | struct libusb_transfer
type libusb_transfer (line 100) | struct libusb_transfer
type timeval (line 103) | struct timeval
type libusb_device_descriptor (line 109) | struct libusb_device_descriptor
type libusb_endpoint_direction (line 127) | enum libusb_endpoint_direction {
type libusb_transfer_status (line 132) | enum libusb_transfer_status
type libusb_transfer_type (line 143) | enum libusb_transfer_type
type libusb_transfer_flags (line 151) | enum libusb_transfer_flags {
type libusb_transfer (line 157) | struct libusb_transfer
type libusb_iso_packet_descriptor (line 174) | struct libusb_iso_packet_descriptor
type libusb_error (line 181) | enum libusb_error
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu.cpp
function libusb_init (line 88) | int libusb_init(libusb_context** context)
function libusb_exit (line 110) | void libusb_exit(libusb_context* ctx)
function libusb_set_debug (line 142) | void libusb_set_debug(libusb_context *ctx, int level)
function libusb_get_device_list (line 151) | ssize_t libusb_get_device_list(libusb_context* ctx, libusb_device*** list)
function libusb_free_device_list (line 190) | void libusb_free_device_list(libusb_device** list, int unref_devices)
function libusb_get_device_descriptor (line 206) | int libusb_get_device_descriptor(libusb_device* dev, struct libusb_devic...
function libusb_open (line 217) | int libusb_open(libusb_device* dev, libusb_device_handle** handle)
function libusb_close (line 249) | void libusb_close(libusb_device_handle* dev_handle)
function libusb_get_string_descriptor (line 267) | int libusb_get_string_descriptor(libusb_device_handle *dev_handle, uint8...
function libusb_get_string_descriptor_ascii (line 276) | int libusb_get_string_descriptor_ascii(libusb_device_handle *dev_handle,...
function libusb_set_configuration (line 286) | int libusb_set_configuration(libusb_device_handle *dev, int configuration)
function libusb_set_interface_alt_setting (line 305) | int libusb_set_interface_alt_setting(libusb_device_handle *dev, int inte...
function libusb_claim_interface (line 316) | int libusb_claim_interface(libusb_device_handle* dev, int interface_number)
function libusb_release_interface (line 347) | int libusb_release_interface(libusb_device_handle* dev, int interface_nu...
function libusb_device_handle (line 362) | libusb_device_handle *libusb_open_device_with_vid_pid(libusb_context *ct...
function libusb_control_transfer (line 394) | int libusb_control_transfer(libusb_device_handle* dev_handle, uint8_t bm...
function libusb_bulk_transfer (line 412) | int libusb_bulk_transfer(libusb_device_handle* dev_handle, uint8_t endpo...
type libusb_transfer (line 439) | struct libusb_transfer
function libusb_free_transfer (line 451) | void libusb_free_transfer(struct libusb_transfer* transfer)
function libusb_fill_iso_transfer (line 489) | void libusb_fill_iso_transfer(struct libusb_transfer* transfer, libusb_d...
function libusb_set_iso_packet_lengths (line 516) | void libusb_set_iso_packet_lengths(struct libusb_transfer* transfer, uns...
function libusb_submit_transfer (line 529) | int libusb_submit_transfer(struct libusb_transfer* transfer)
function libusb_cancel_transfer (line 578) | int libusb_cancel_transfer(struct libusb_transfer* transfer)
function libusbemu_handle_isochronous (line 599) | int libusbemu_handle_isochronous(libusb_context* ctx, const unsigned int...
function libusb_handle_events (line 622) | int libusb_handle_events(libusb_context* ctx)
function libusb_handle_events_timeout (line 638) | int libusb_handle_events_timeout(libusb_context* ctx, struct timeval* ti...
function libusbemu_deliver_transfer (line 661) | void libusbemu_deliver_transfer(transfer_wrapper* wrapper)
function ReapThreadProc (line 685) | int ReapThreadProc(void* params)
function ReapTransfer (line 810) | int ReapTransfer(transfer_wrapper* wrapper, unsigned int timeout, libusb...
function PreprocessTransferNaive (line 905) | void PreprocessTransferNaive(libusb_transfer* transfer, const int read)
function PreprocessTransferFreenect (line 925) | void PreprocessTransferFreenect(libusb_transfer* transfer, const int read)
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu_internal.h
function namespace (line 35) | namespace libusbemu {
type transfer_wrapper (line 240) | struct transfer_wrapper
type libusb_device_handle_t (line 249) | struct libusb_device_handle_t
type libusb_device_t (line 255) | struct libusb_device_t
type libusb_context_t (line 272) | struct libusb_context_t
function namespace (line 289) | namespace libusbemu {
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu_threads.h
function namespace (line 49) | namespace libusbemu
FILE: libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu_threads_win32.h
function namespace (line 35) | namespace libusbemu {
type QuickThread (line 77) | struct QuickThread
function DWORD (line 99) | static DWORD WINAPI Thunk(LPVOID lpParameter)
function QuickThread (line 155) | static inline QuickThread Myself()
function Join (line 160) | inline void Join()
function TryJoin (line 165) | inline bool TryJoin()
function LowerPriority (line 170) | inline bool LowerPriority()
function RaisePriority (line 175) | inline bool RaisePriority()
function Sleep (line 180) | static inline void Sleep(int milliseconds)
function Yield (line 194) | static inline void Yield()
function QuickMutex (line 208) | struct QuickMutex
function TryEnter (line 224) | inline const bool TryEnter()
function Enter (line 229) | inline void Enter()
function Leave (line 234) | inline void Leave()
type EventList (line 242) | struct EventList
function AttachEvent (line 251) | const bool AttachEvent(QuickEvent* poEvent)
function DetachEvent (line 260) | const bool DetachEvent(QuickEvent* poEvent)
function WaitAnyUntilTimeout (line 271) | int WaitAnyUntilTimeout(const unsigned int milliseconds)
function WaitAny (line 285) | int WaitAny()
function CheckAny (line 290) | int CheckAny()
function WaitAllUntilTimeout (line 295) | const bool WaitAllUntilTimeout(const unsigned int milliseconds)
function WaitAll (line 306) | const bool WaitAll()
function QuickEvent (line 311) | QuickEvent* operator [] (const unsigned int index)
FILE: libs/libfreenect/src/cameras.c
type pkt_hdr (line 75) | struct pkt_hdr {
function stream_process (line 86) | static int stream_process(freenect_context *ctx, packet_stream *strm, ui...
function stream_init (line 220) | static void stream_init(freenect_context *ctx, packet_stream *strm, int ...
function stream_freebufs (line 249) | static void stream_freebufs(freenect_context *ctx, packet_stream *strm)
function stream_setbuf (line 261) | static int stream_setbuf(freenect_context *ctx, packet_stream *strm, voi...
function convert_packed_to_16bit (line 293) | static inline void convert_packed_to_16bit(uint8_t *src, uint16_t *dest,...
function convert_packed_to_8bit (line 319) | static inline void convert_packed_to_8bit(uint8_t *src, uint8_t *dest, i...
function convert_packed11_to_16bit (line 334) | static void convert_packed11_to_16bit(uint8_t *raw, uint16_t *frame, int n)
function depth_process (line 366) | static void depth_process(freenect_device *dev, uint8_t *pkt, int len)
function convert_uyvy_to_rgb (line 409) | static void convert_uyvy_to_rgb(uint8_t *raw_buf, uint8_t *proc_buf, fre...
function convert_bayer_to_rgb (line 442) | static void convert_bayer_to_rgb(uint8_t *raw_buf, uint8_t *proc_buf, fr...
function video_process (line 606) | static void video_process(freenect_device *dev, uint8_t *pkt, int len)
type cam_hdr (line 653) | typedef struct {
function send_cmd (line 660) | static int send_cmd(freenect_device *dev, uint16_t cmd, void *cmdbuf, un...
function write_register (line 729) | static int write_register(freenect_device *dev, uint16_t reg, uint16_t d...
function read_register (line 750) | static uint16_t read_register(freenect_device *dev, uint16_t reg)
function freenect_fetch_reg_info (line 769) | static int freenect_fetch_reg_info(freenect_device *dev)
function freenect_fetch_reg_pad_info (line 847) | static int freenect_fetch_reg_pad_info(freenect_device *dev)
function freenect_fetch_reg_const_shift (line 874) | static int freenect_fetch_reg_const_shift(freenect_device *dev)
function freenect_fetch_zero_plane_info (line 899) | static int freenect_fetch_zero_plane_info(freenect_device *dev)
function freenect_start_depth (line 946) | int freenect_start_depth(freenect_device *dev)
function freenect_start_video (line 1006) | int freenect_start_video(freenect_device *dev)
function freenect_stop_depth (line 1153) | int freenect_stop_depth(freenect_device *dev)
function freenect_stop_video (line 1175) | int freenect_stop_video(freenect_device *dev)
function freenect_set_depth_callback (line 1196) | void freenect_set_depth_callback(freenect_device *dev, freenect_depth_cb...
function freenect_set_video_callback (line 1201) | void freenect_set_video_callback(freenect_device *dev, freenect_video_cb...
function freenect_get_video_mode_count (line 1206) | int freenect_get_video_mode_count()
function freenect_frame_mode (line 1211) | freenect_frame_mode freenect_get_video_mode(int mode_num)
function freenect_frame_mode (line 1220) | freenect_frame_mode freenect_get_current_video_mode(freenect_device *dev)
function freenect_frame_mode (line 1225) | freenect_frame_mode freenect_find_video_mode(freenect_resolution res, fr...
function freenect_set_video_mode (line 1238) | int freenect_set_video_mode(freenect_device* dev, const freenect_frame_m...
function freenect_get_depth_mode_count (line 1269) | int freenect_get_depth_mode_count()
function freenect_frame_mode (line 1274) | freenect_frame_mode freenect_get_depth_mode(int mode_num)
function freenect_frame_mode (line 1283) | freenect_frame_mode freenect_get_current_depth_mode(freenect_device *dev)
function freenect_frame_mode (line 1288) | freenect_frame_mode freenect_find_depth_mode(freenect_resolution res, fr...
function freenect_set_depth_mode (line 1301) | int freenect_set_depth_mode(freenect_device* dev, const freenect_frame_m...
function freenect_set_depth_buffer (line 1327) | int freenect_set_depth_buffer(freenect_device *dev, void *buf)
function freenect_set_video_buffer (line 1332) | int freenect_set_video_buffer(freenect_device *dev, void *buf)
function FN_INTERNAL (line 1337) | FN_INTERNAL int freenect_camera_init(freenect_device *dev)
function FN_INTERNAL (line 1361) | FN_INTERNAL int freenect_camera_teardown(freenect_device *dev)
FILE: libs/libfreenect/src/core.c
function FREENECTAPI (line 41) | FREENECTAPI int freenect_init(freenect_context **ctx, freenect_usb_conte...
function FREENECTAPI (line 65) | FREENECTAPI int freenect_shutdown(freenect_context *ctx)
function FREENECTAPI (line 77) | FREENECTAPI int freenect_process_events(freenect_context *ctx)
function FREENECTAPI (line 85) | FREENECTAPI int freenect_process_events_timeout(freenect_context *ctx, s...
function FREENECTAPI (line 109) | FREENECTAPI int freenect_num_devices(freenect_context *ctx)
function FREENECTAPI (line 114) | FREENECTAPI int freenect_list_device_attributes(freenect_context *ctx, s...
function FREENECTAPI (line 119) | FREENECTAPI void freenect_free_device_attributes(struct freenect_device_...
function FREENECTAPI (line 135) | FREENECTAPI int freenect_supported_subdevices(void) {
function FREENECTAPI (line 143) | FREENECTAPI void freenect_select_subdevices(freenect_context *ctx, freen...
function FREENECTAPI (line 151) | FREENECTAPI freenect_device_flags freenect_enabled_subdevices(freenect_c...
function FREENECTAPI (line 155) | FREENECTAPI int freenect_open_device(freenect_context *ctx, freenect_dev...
function FREENECTAPI (line 193) | FREENECTAPI int freenect_open_device_by_camera_serial(freenect_context *...
function FREENECTAPI (line 217) | FREENECTAPI int freenect_close_device(freenect_device *dev)
function FREENECTAPI (line 254) | FREENECTAPI void freenect_set_user(freenect_device *dev, void *user)
function FREENECTAPI (line 259) | FREENECTAPI void *freenect_get_user(freenect_device *dev)
function FREENECTAPI (line 264) | FREENECTAPI void freenect_set_log_level(freenect_context *ctx, freenect_...
function FREENECTAPI (line 269) | FREENECTAPI void freenect_set_log_callback(freenect_context *ctx, freene...
function FN_INTERNAL (line 274) | FN_INTERNAL void fn_log(freenect_context *ctx, freenect_loglevel level, ...
FILE: libs/libfreenect/src/freenect_internal.h
type _freenect_context (line 50) | struct _freenect_context {
function fn_le16 (line 89) | static inline uint16_t fn_le16(uint16_t d)
function fn_le32 (line 93) | static inline uint32_t fn_le32(uint32_t d)
function fn_le16s (line 97) | static inline int16_t fn_le16s(int16_t s)
function fn_le32s (line 108) | static inline int32_t fn_le32s(int32_t s)
type packet_stream (line 139) | typedef struct {
type audio_stream (line 163) | typedef struct {
type audio_in_block (line 186) | typedef struct {
type audio_out_block (line 195) | typedef struct {
type _freenect_device (line 204) | struct _freenect_device {
FILE: libs/libfreenect/src/loader.h
type bootloader_command (line 33) | typedef struct {
type cemdloader_command (line 42) | typedef struct {
type bootloader_status_code (line 51) | typedef struct {
FILE: libs/libfreenect/src/registration.c
function freenect_init_depth_to_rgb (line 60) | static void freenect_init_depth_to_rgb(int32_t* depth_to_rgb, freenect_z...
function unpack_8_pixels (line 77) | static inline void unpack_8_pixels(uint8_t *raw, uint16_t *frame)
function FN_INTERNAL (line 104) | FN_INTERNAL int freenect_apply_registration(freenect_device* dev, uint8_...
function FN_INTERNAL (line 172) | FN_INTERNAL int freenect_apply_depth_to_mm(freenect_device* dev, uint8_t...
function freenect_create_dxdy_tables (line 194) | static void freenect_create_dxdy_tables(double* reg_x_table, double* reg...
function freenect_init_registration_table (line 264) | static void freenect_init_registration_table(int32_t (*registration_tabl...
function freenect_raw_to_mm (line 297) | static uint16_t freenect_raw_to_mm(uint16_t raw, freenect_registration* ...
function complete_tables (line 306) | static void complete_tables(freenect_registration* reg) {
function freenect_camera_to_world (line 318) | void freenect_camera_to_world(freenect_device* dev, int cx, int cy, int ...
function FN_INTERNAL (line 335) | FN_INTERNAL int freenect_init_registration(freenect_device* dev)
function freenect_registration (line 353) | freenect_registration freenect_copy_registration(freenect_device* dev)
function freenect_destroy_registration (line 367) | int freenect_destroy_registration(freenect_registration* reg)
FILE: libs/libfreenect/src/tilt.c
function freenect_raw_tilt_state (line 42) | freenect_raw_tilt_state* freenect_get_tilt_state(freenect_device *dev)
function freenect_update_tilt_state (line 47) | int freenect_update_tilt_state(freenect_device *dev)
function freenect_set_tilt_degs (line 80) | int freenect_set_tilt_degs(freenect_device *dev, double angle)
function freenect_set_led (line 95) | int freenect_set_led(freenect_device *dev, freenect_led_options option)
function freenect_get_tilt_degs (line 106) | double freenect_get_tilt_degs(freenect_raw_tilt_state *state)
function freenect_tilt_status_code (line 111) | freenect_tilt_status_code freenect_get_tilt_status(freenect_raw_tilt_sta...
function freenect_get_mks_accel (line 116) | void freenect_get_mks_accel(freenect_raw_tilt_state *state, double* x, d...
FILE: libs/libfreenect/src/usb_libusb10.c
function FN_INTERNAL (line 36) | FN_INTERNAL int fnusb_num_devices(fnusb_ctx *ctx)
function FN_INTERNAL (line 59) | FN_INTERNAL int fnusb_list_device_attributes(fnusb_ctx *ctx, struct free...
function FN_INTERNAL (line 119) | FN_INTERNAL int fnusb_init(fnusb_ctx *ctx, freenect_usb_context *usb_ctx)
function FN_INTERNAL (line 140) | FN_INTERNAL int fnusb_shutdown(fnusb_ctx *ctx)
function FN_INTERNAL (line 150) | FN_INTERNAL int fnusb_process_events(fnusb_ctx *ctx)
function FN_INTERNAL (line 155) | FN_INTERNAL int fnusb_process_events_timeout(fnusb_ctx *ctx, struct time...
function FN_INTERNAL (line 160) | FN_INTERNAL int fnusb_open_subdevices(freenect_device *dev, int index)
function FN_INTERNAL (line 425) | FN_INTERNAL int fnusb_close_subdevices(freenect_device *dev)
function iso_callback (line 450) | static void iso_callback(struct libusb_transfer *xfer)
function FN_INTERNAL (line 532) | FN_INTERNAL int fnusb_start_iso(fnusb_dev *dev, fnusb_isoc_stream *strm,...
function FN_INTERNAL (line 570) | FN_INTERNAL int fnusb_stop_iso(fnusb_dev *dev, fnusb_isoc_stream *strm)
function FN_INTERNAL (line 601) | FN_INTERNAL int fnusb_control(fnusb_dev *dev, uint8_t bmRequestType, uin...
function FN_INTERNAL (line 607) | FN_INTERNAL int fnusb_bulk(fnusb_dev *dev, uint8_t endpoint, uint8_t *da...
function FN_INTERNAL (line 612) | FN_INTERNAL int fnusb_num_interfaces(fnusb_dev *dev) {
FILE: libs/libfreenect/src/usb_libusb10.h
type fnusb_ctx (line 64) | typedef struct {
type fnusb_dev (line 69) | typedef struct {
type fnusb_isoc_stream (line 75) | typedef struct {
type freenect_device_attributes (line 88) | struct freenect_device_attributes
type timeval (line 93) | struct timeval
FILE: libs/libusb-1.0/include/libusb-1.0/libusb.h
function libusb_cpu_to_le16 (line 100) | static inline uint16_t libusb_cpu_to_le16(const uint16_t x)
type libusb_class_code (line 125) | enum libusb_class_code {
type libusb_descriptor_type (line 168) | enum libusb_descriptor_type {
type libusb_endpoint_direction (line 212) | enum libusb_endpoint_direction {
type libusb_transfer_type (line 226) | enum libusb_transfer_type {
type libusb_standard_request (line 242) | enum libusb_standard_request {
type libusb_request_type (line 285) | enum libusb_request_type {
type libusb_request_recipient (line 303) | enum libusb_request_recipient {
type libusb_iso_sync_type (line 324) | enum libusb_iso_sync_type {
type libusb_iso_usage_type (line 345) | enum libusb_iso_usage_type {
type libusb_device_descriptor (line 361) | struct libusb_device_descriptor {
type libusb_endpoint_descriptor (line 415) | struct libusb_endpoint_descriptor {
type libusb_interface_descriptor (line 465) | struct libusb_interface_descriptor {
type libusb_interface (line 513) | struct libusb_interface {
type libusb_config_descriptor (line 527) | struct libusb_config_descriptor {
type libusb_control_setup (line 570) | struct libusb_control_setup {
type libusb_context (line 600) | struct libusb_context
type libusb_device (line 601) | struct libusb_device
type libusb_device_handle (line 602) | struct libusb_device_handle
type libusb_context (line 621) | typedef struct libusb_context libusb_context;
type libusb_device (line 638) | typedef struct libusb_device libusb_device;
type libusb_device_handle (line 649) | typedef struct libusb_device_handle libusb_device_handle;
type libusb_error (line 657) | enum libusb_error {
type libusb_transfer_status (line 706) | enum libusb_transfer_status {
type libusb_transfer_flags (line 733) | enum libusb_transfer_flags {
type libusb_iso_packet_descriptor (line 749) | struct libusb_iso_packet_descriptor {
type libusb_transfer (line 760) | struct libusb_transfer
type libusb_transfer (line 771) | struct libusb_transfer
type libusb_transfer (line 779) | struct libusb_transfer {
type libusb_error (line 840) | enum libusb_error
type libusb_device_descriptor (line 852) | struct libusb_device_descriptor
type libusb_config_descriptor (line 854) | struct libusb_config_descriptor
type libusb_config_descriptor (line 856) | struct libusb_config_descriptor
type libusb_config_descriptor (line 858) | struct libusb_config_descriptor
type libusb_config_descriptor (line 860) | struct libusb_config_descriptor
type libusb_transfer (line 910) | struct libusb_transfer
type libusb_control_setup (line 927) | struct libusb_control_setup
type libusb_transfer (line 928) | struct libusb_transfer
type libusb_control_setup (line 930) | struct libusb_control_setup
function libusb_fill_control_setup (line 955) | static inline void libusb_fill_control_setup(unsigned char *buffer,
type libusb_transfer (line 967) | struct libusb_transfer
type libusb_transfer (line 968) | struct libusb_transfer
type libusb_transfer (line 969) | struct libusb_transfer
type libusb_transfer (line 970) | struct libusb_transfer
function libusb_fill_control_transfer (line 999) | static inline void libusb_fill_control_transfer(
function libusb_fill_bulk_transfer (line 1030) | static inline void libusb_fill_bulk_transfer(struct libusb_transfer *tra...
function libusb_fill_interrupt_transfer (line 1058) | static inline void libusb_fill_interrupt_transfer(
function libusb_fill_iso_transfer (line 1087) | static inline void libusb_fill_iso_transfer(struct libusb_transfer *tran...
function libusb_set_iso_packet_lengths (line 1111) | static inline void libusb_set_iso_packet_lengths(
type libusb_transfer (line 1136) | struct libusb_transfer
type libusb_transfer (line 1178) | struct libusb_transfer
function libusb_get_descriptor (line 1221) | static inline int libusb_get_descriptor(libusb_device_handle *dev,
function libusb_get_string_descriptor (line 1243) | static inline int libusb_get_string_descriptor(libusb_device_handle *dev,
type timeval (line 1263) | struct timeval
type timeval (line 1266) | struct timeval
type timeval (line 1269) | struct timeval
type timeval (line 1272) | struct timeval
type libusb_pollfd (line 1277) | struct libusb_pollfd {
type libusb_pollfd (line 1312) | struct libusb_pollfd
FILE: libs/libusb-win32/include/lusb0_usb.h
type usb_descriptor_header (line 74) | struct usb_descriptor_header
type usb_string_descriptor (line 81) | struct usb_string_descriptor
type usb_hid_descriptor (line 89) | struct usb_hid_descriptor
type usb_endpoint_descriptor (line 100) | struct usb_endpoint_descriptor
type usb_interface_descriptor (line 126) | struct usb_interface_descriptor
type usb_interface (line 146) | struct usb_interface
type usb_config_descriptor (line 155) | struct usb_config_descriptor
type usb_device_descriptor (line 173) | struct usb_device_descriptor
type usb_ctrl_setup (line 191) | struct usb_ctrl_setup
type usb_device (line 257) | struct usb_device
type usb_bus (line 276) | struct usb_bus
type usb_version (line 289) | struct usb_version
type usb_dev_handle (line 308) | struct usb_dev_handle
type usb_dev_handle (line 309) | typedef struct usb_dev_handle usb_dev_handle;
type usb_device (line 329) | struct usb_device
type usb_device (line 370) | struct usb_device
type usb_bus (line 371) | struct usb_bus
type usb_version (line 406) | struct usb_version
FILE: src/ofxBase3DVideo.h
function class (line 29) | class ofxBase3DVideo: public ofBaseVideo {
FILE: src/ofxKinect.cpp
function ofVec3f (line 338) | ofVec3f ofxKinect::getWorldCoordinateAt(int x, int y) {
function ofVec3f (line 343) | ofVec3f ofxKinect::getWorldCoordinateAt(float cx, float cy, float wz) {
function ofColor (line 370) | ofColor ofxKinect::getColorAt(int x, int y) {
function ofColor (line 382) | ofColor ofxKinect::getColorAt(const ofPoint & p) {
function ofPixels (line 406) | ofPixels & ofxKinect::getPixelsRef(){
function ofPixels (line 410) | ofPixels & ofxKinect::getDepthPixelsRef(){
function ofShortPixels (line 414) | ofShortPixels & ofxKinect::getRawDepthPixelsRef(){
function ofFloatPixels (line 418) | ofFloatPixels & ofxKinect::getDistancePixelsRef(){
function ofTexture (line 423) | ofTexture& ofxKinect::getTextureReference(){
function ofTexture (line 431) | ofTexture& ofxKinect::getDepthTextureReference(){
function ofPoint (line 480) | ofPoint ofxKinect::getRawAccel() {
function ofPoint (line 485) | ofPoint ofxKinect::getMksAccel() {
function string (line 587) | string ofxKinect::getSerial() {
function string (line 637) | string ofxKinect::nextAvailableSerial() {
function sortKinectPairs (line 772) | static bool sortKinectPairs(ofxKinectContext::KinectPair A, ofxKinectCon...
function ofxKinect (line 979) | ofxKinect* ofxKinectContext::getKinect(freenect_device* dev) {
function string (line 1032) | string ofxKinectContext::nextAvailableSerial() {
FILE: src/ofxKinect.h
type LedMode (line 252) | enum LedMode {
function class (line 405) | class ofxKinectContext {
Condensed preview — 71 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (555K chars).
[
{
"path": ".gitignore",
"chars": 287,
"preview": "\n.svn/\nobj/\nbin/\nbuild/\n!data/\nipch/\n\n# mac Finder index files\n.DS_*\n\n# mac apps\n*.app*\n\n# xcode user project files\n*.pb"
},
{
"path": "LICENSE.txt",
"chars": 1134,
"preview": "Copyright (c) 2010, 2011 ofxKinect Team\n\nThe MIT License <http://www.opensource.org/licenses/mit-license.php>\n\nPermissio"
},
{
"path": "README.md",
"chars": 11692,
"preview": "ofxKinect\n=========\n\n**Note: As of OpenFrameworks 0.8.0, ofxKinect has been integrated into the OF core. All future deve"
},
{
"path": "addon_config.mk",
"chars": 7415,
"preview": "# All variables and this file are optional, if they are not present the PG and the\n# makefiles will try to parse the cor"
},
{
"path": "kinectExample/addons.make",
"chars": 20,
"preview": "ofxKinect\nofxOpenCv\n"
},
{
"path": "kinectExample/src/main.cpp",
"chars": 164,
"preview": "#include \"testApp.h\"\n#include \"ofAppGlutWindow.h\"\n\nint main() {\n\tofAppGlutWindow window;\n\tofSetupOpenGL(&window, 1024, 7"
},
{
"path": "kinectExample/src/testApp.cpp",
"chars": 7733,
"preview": "#include \"testApp.h\"\n\n\n//--------------------------------------------------------------\nvoid testApp::setup() {\n\tofSetLo"
},
{
"path": "kinectExample/src/testApp.h",
"chars": 1586,
"preview": "#pragma once\n\n#include \"ofMain.h\"\n#include \"ofxOpenCv.h\"\n#include \"ofxKinect.h\"\n\n// Windows users:\n// You MUST install t"
},
{
"path": "libs/libfreenect/APACHE20",
"chars": 11358,
"preview": "\n Apache License\n Version 2.0, January 2004\n "
},
{
"path": "libs/libfreenect/CONTRIB",
"chars": 600,
"preview": "For a list of libfreenect authors, please see the Git history of the project,\nsuch as with 'git log'. This file will con"
},
{
"path": "libs/libfreenect/GPL2",
"chars": 18011,
"preview": "\t\t GNU GENERAL PUBLIC LICENSE\n\t\t Version 2, June 1991\n\n Copyright (C) 1989, 1991 Free Software Foundation, Inc."
},
{
"path": "libs/libfreenect/include/libfreenect-registration.h",
"chars": 3683,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2011 individual OpenKin"
},
{
"path": "libs/libfreenect/include/libfreenect.h",
"chars": 24840,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/platform/linux/udev/51-kinect.rules",
"chars": 343,
"preview": "# ATTR{product}==\"Xbox NUI Motor\"\nSUBSYSTEM==\"usb\", ATTR{idVendor}==\"045e\", ATTR{idProduct}==\"02b0\", MODE=\"0666\"\n\n# ATTR"
},
{
"path": "libs/libfreenect/platform/linux/udev/README",
"chars": 96,
"preview": "Simply place this file in /etc/udev/rules.d and you'll no longer need\nto run your apps as root.\n"
},
{
"path": "libs/libfreenect/platform/windows/README.TXT",
"chars": 18144,
"preview": "======================================================================================\n\nSUMMARY\n*******\n\n1) libfreenect:"
},
{
"path": "libs/libfreenect/platform/windows/inf/xbox nui audio/libusb-win32-bin-README.txt",
"chars": 904,
"preview": "libusb-win32-bin v1.2.2.0 (10/02/2010) - [Package Information]\n\nALL ARCHITECTURES:\n x86\\libusb0_x86.dll: x86 32-bit lib"
},
{
"path": "libs/libfreenect/platform/windows/inf/xbox nui audio/license/libusb-win32/installer_license.txt",
"chars": 43302,
"preview": "Copyright (c) 2002-2004 Stephan Meyer, <ste_meyer@web.de>\nCopyright (c) 2000-2004 Johannes Erdfelt, <johannes@erdfelt.co"
},
{
"path": "libs/libfreenect/platform/windows/inf/xbox nui camera/libusb-win32-bin-README.txt",
"chars": 904,
"preview": "libusb-win32-bin v1.2.2.0 (10/02/2010) - [Package Information]\n\nALL ARCHITECTURES:\n x86\\libusb0_x86.dll: x86 32-bit lib"
},
{
"path": "libs/libfreenect/platform/windows/inf/xbox nui camera/license/libusb-win32/installer_license.txt",
"chars": 43302,
"preview": "Copyright (c) 2002-2004 Stephan Meyer, <ste_meyer@web.de>\nCopyright (c) 2000-2004 Johannes Erdfelt, <johannes@erdfelt.co"
},
{
"path": "libs/libfreenect/platform/windows/inf/xbox nui motor/libusb-win32-bin-README.txt",
"chars": 904,
"preview": "libusb-win32-bin v1.2.2.0 (10/02/2010) - [Package Information]\n\nALL ARCHITECTURES:\n x86\\libusb0_x86.dll: x86 32-bit lib"
},
{
"path": "libs/libfreenect/platform/windows/inf/xbox nui motor/license/libusb-win32/installer_license.txt",
"chars": 43302,
"preview": "Copyright (c) 2002-2004 Stephan Meyer, <ste_meyer@web.de>\nCopyright (c) 2000-2004 Johannes Erdfelt, <johannes@erdfelt.co"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/failguard.cpp",
"chars": 1696,
"preview": "#include \"failguard.h\"\n#include \"libusbemu_threads.h\"\n\nint ThreadFailGuardProc(void* params);\n\nnamespace libusbemu\n{\n\nna"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/failguard.h",
"chars": 224,
"preview": "#ifndef LIBUSBEMU_FAIL_GUARD_H\n#define LIBUSBEMU_FAIL_GUARD_H\n\nnamespace libusbemu\n{\n namespace failguard\n {\n const"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusb.h",
"chars": 7025,
"preview": "/*\n* This file is part of the OpenKinect Project. http://www.openkinect.org\n*\n* Copyright (c) 2010 individual OpenKinect"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu.cpp",
"chars": 35741,
"preview": "/*\n* This file is part of the OpenKinect Project. http://www.openkinect.org\n*\n* Copyright (c) 2010 individual OpenKinect"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu_internal.h",
"chars": 10867,
"preview": "/*\n* This file is part of the OpenKinect Project. http://www.openkinect.org\n*\n* Copyright (c) 2010 individual OpenKinect"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu_threads.h",
"chars": 2177,
"preview": "/*\n* This file is part of the OpenKinect Project. http://www.openkinect.org\n*\n* Copyright (c) 2010 individual OpenKinect"
},
{
"path": "libs/libfreenect/platform/windows/libusb10emu/libusb-1.0/libusbemu_threads_win32.h",
"chars": 8378,
"preview": "/*\n* This file is part of the OpenKinect Project. http://www.openkinect.org\n*\n* Copyright (c) 2010 individual OpenKinect"
},
{
"path": "libs/libfreenect/platform/windows/stdbool.h",
"chars": 1212,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/platform/windows/unistd.h",
"chars": 1453,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/src/cameras.c",
"chars": 47523,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/src/cameras.h",
"chars": 1433,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010-2011 individual Op"
},
{
"path": "libs/libfreenect/src/core.c",
"chars": 7586,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/src/freenect_internal.h",
"chars": 6428,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010-2011 individual Op"
},
{
"path": "libs/libfreenect/src/loader.h",
"chars": 1775,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2011 individual OpenKin"
},
{
"path": "libs/libfreenect/src/registration.c",
"chars": 14086,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2011 individual OpenKin"
},
{
"path": "libs/libfreenect/src/registration.h",
"chars": 1491,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2011 individual OpenKin"
},
{
"path": "libs/libfreenect/src/tilt.c",
"chars": 3983,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/src/usb_libusb10.c",
"chars": 19807,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libfreenect/src/usb_libusb10.h",
"chars": 3561,
"preview": "/*\n * This file is part of the OpenKinect Project. http://www.openkinect.org\n *\n * Copyright (c) 2010 individual OpenKin"
},
{
"path": "libs/libusb-1.0/include/libusb-1.0/libusb.h",
"chars": 45029,
"preview": "/*\n * Public libusb header file\n * Copyright (C) 2007-2008 Daniel Drake <dsd@gentoo.org>\n * Copyright (c) 2001 Johannes "
},
{
"path": "libs/libusb-win32/AUTHORS.txt",
"chars": 304,
"preview": "\nLibrary, Test Programs:\n\nStephan Meyer, <ste_meyer@web.de>\nJohannes Erdfelt, <johannes@erdfelt.com>\nThomas Sailer, <sai"
},
{
"path": "libs/libusb-win32/COPYING_LGPL.txt",
"chars": 7651,
"preview": " GNU LESSER GENERAL PUBLIC LICENSE\n Version 3, 29 June 2007\n\n Copyright (C) 2007"
},
{
"path": "libs/libusb-win32/README.txt",
"chars": 457,
"preview": "\nThis is libusb-win32 (http://libusb-win32.sourceforge.net) version 1.2.6.0. \nLibusb-win32 is a library that allows user"
},
{
"path": "libs/libusb-win32/include/lusb0_usb.h",
"chars": 11452,
"preview": "#ifndef __USB_H__\n#define __USB_H__\n\n#include <stdlib.h>\n#include <windows.h>\n\n/*\n * 'interface' is defined somewhere in"
},
{
"path": "scripts/update_freenect.sh",
"chars": 864,
"preview": "#! /bin/bash\n\nWD=$(dirname $0)\n\nDEST=../libs/libfreenect\nSRC=libfreenect\n\n###\n\ncd $WD\n\n# get latest source\n#git clone gi"
},
{
"path": "scripts/update_libusb-win32.sh",
"chars": 1057,
"preview": "#! /bin/bash\n\nWD=$(dirname $0)\n\nVER=1.2.6.0\n\nDEST=../libs/libusb-win32\nSRC=libusb-win32-bin-$VER\n\n###\n\ncd $WD\n\n# make fo"
},
{
"path": "src/ofxBase3DVideo.h",
"chars": 1758,
"preview": "/*==============================================================================\n\n Copyright (c) 2010, 2011 ofxKinect"
},
{
"path": "src/ofxKinect.cpp",
"chars": 28558,
"preview": "/*==============================================================================\n\n Copyright (c) 2010, 2011 ofxKinect"
},
{
"path": "src/ofxKinect.h",
"chars": 14544,
"preview": "/*==============================================================================\n\n Copyright (c) 2010, 2011 ofxKinect"
}
]
// ... and 20 more files (download for full content)
About this extraction
This page contains the full source code of the ofTheo/ofxKinect GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 71 files (515.5 KB), approximately 133.8k tokens, and a symbol index with 322 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.