Permalink
Browse files

Merge branch 'MSKinectAPI'

  • Loading branch information...
Gerhard Reitmayr
Gerhard Reitmayr committed Feb 26, 2013
2 parents df56e92 + b0a1f17 commit 3d757c10f7604c4e7cfc9734c0ea4645478a1b59
Showing with 374 additions and 124 deletions.
  1. +18 −13 CMakeLists.txt
  2. +2 −3 Makefile
  3. +19 −5 README.md
  4. +305 −0 interface.cpp
  5. +9 −0 interface.h
  6. +21 −103 kinect.cpp
View
@@ -10,6 +10,7 @@ find_package(OpenGL)
find_package(Freenect)
find_package(GLUT)
include_directories(
${CMAKE_BINARY_DIR}/include
${TOON_INCLUDE_PATHS}
@@ -34,19 +35,7 @@ cuda_add_library(kfusion STATIC
-O3
)
if (GLUT_FOUND AND FREENECT_FOUND)
include_directories(${FREENECT_INCLUDE_PATHS} ${GLUT_INCLUDE_DIR})
add_executable(kfusion_kinect
kinect.cpp
)
target_link_libraries(kfusion_kinect kfusion ${FREENECT_LIBRARIES} ${GLUT_LIBRARIES} ${OPENGL_LIBRARIES} )
endif()
if(GLUT_FOUND)
if (GLUT_FOUND)
include_directories(${GLUT_INCLUDE_DIR})
@@ -55,5 +44,21 @@ if(GLUT_FOUND)
)
target_link_libraries(kfusion_test kfusion ${GLUT_LIBRARIES} ${OPENGL_LIBRARIES})
if(FREENECT_FOUND)
include_directories(${FREENECT_INCLUDE_PATHS})
add_definitions(-DLIBFREENECT_INTERFACE)
add_executable(kfusion_kinect
kinect.cpp interface.h interface.cpp
)
target_link_libraries(kfusion_kinect kfusion ${GLUT_LIBRARIES} ${OPENGL_LIBRARIES} ${FREENECT_LIBRARIES})
else()
include_directories($ENV{KINECTSDK10_DIR}/inc)
add_definitions(-DMS_KINECT_INTERFACE)
add_executable(kfusion_kinect
kinect.cpp interface.h interface.cpp
)
target_link_libraries(kfusion_kinect kfusion ${GLUT_LIBRARIES} ${OPENGL_LIBRARIES} $ENV{KINECTSDK10_DIR}/lib/amd64/Kinect10.lib)
endif()
endif()
View
@@ -1,6 +1,6 @@
CXX = nvcc
CC = nvcc
CPPFLAGS=-I../include -I../include/libfreenect -I/usr/loca/cuda/include -I/opt/local/include
CPPFLAGS=-I../include -I../include/libfreenect -I/usr/loca/cuda/include -I/opt/local/include -DLIBFREENECT_INTERFACE
CXXFLAGS=-g -m64 -O3 -use_fast_math
## -ptx -src-in-ptx
LDFLAGS=-g -m64 -L../lib -lfreenect -Xlinker -framework,OpenGL,-framework,GLUT
@@ -12,8 +12,7 @@ all: kinect test
test: kfusion.o helpers.o test.o
kinect: kfusion.o helpers.o kinect.o
kinect: kfusion.o helpers.o kinect.o interface.o
clean:
rm *.o test kinect
View
@@ -1,8 +1,8 @@
KFusion 0.3.1
KFusion 0.4
=============
Copyright TU Graz, Gerhard Reitmayr, 2011 - 2012
Copyright TU Graz, Gerhard Reitmayr, 2011 - 2013
This is an implementation sketch of the KinectFusion system described by
Richard Newcombe et al. in "KinectFusion: Real-Time Dense Surface Mapping and Tracking",
@@ -19,17 +19,30 @@ Requirements
KFusion depends on the following libraries:
* http://www.edwardrosten.com/cvd/toon.html
* http://openkinect.org/
* GLUT
On Windows use the MS Kinect SDK:
* http://www.microsoft.com/en-us/kinectforwindows/develop/overview.aspx
while on other platforms use libfreenect:
* http://openkinect.org/
and of course the CUDA 5 SDK by NVidia
* http://developer.nvidia.com/cuda
Install
-----
To get started, tweak the Makefile for your setup and have a look at kfusion.h
to set some defines to adapt to your compute capabilities. Then make.
Use CMake to create build files for your platform. Some tips and tricks
- On Windows, make sure to use a 64-bit version of GLUT
- On Apple OSX, set CUDA_HOST_COMPILER to /usr/bin/g++
Altenatively, On Unix/OSX platforms, tweak the Makefile for your setup, then make.
Have a look at kfusion.h for a description of most parameters and kinect.cpp for setting them.
Todo
-----
@@ -40,6 +53,7 @@ Todo
Done
-----
- MSKinect SDK interface for Windows, libfreenect on other platforms
- rendering with static model view + projected RGB + interactive viewpoint
- registered depth input from libfreenect, uses more time unfortunately
- integration speed up
Oops, something went wrong.

0 comments on commit 3d757c1

Please sign in to comment.