Skip to content

Commit

Permalink
Modified build process for Kinect support.
Browse files Browse the repository at this point in the history
Can now be disabled by the DISABLE_KINECT define.
Also better output for users when running qmake.
  • Loading branch information
Bryant committed Feb 13, 2014
1 parent 1fcd392 commit 9b3fcdd
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
13 changes: 7 additions & 6 deletions QGCExternalLibs.pri
Original file line number Diff line number Diff line change
Expand Up @@ -312,23 +312,24 @@ LinuxBuild : contains(MAVLINK_DIALECT, pixhawk) {
}

#
# libfreenect Kinect support
# [OPTIONAL] Kinect support using libfreenect on POSIX systems.
#

MacBuild | LinuxBuild {
contains(DEFINES, DISABLE_KINECT) {
message("Skipping support for the Kinect (manual override)")
} else:MacBuild | LinuxBuild {
exists(/opt/local/include/libfreenect) | exists(/usr/local/include/libfreenect) {
message("Including support for libfreenect")
message("Including support for the Kinect")

#INCLUDEPATH += /usr/include/libusb-1.0
DEFINES += QGC_LIBFREENECT_ENABLED
LIBS += -lfreenect
HEADERS += src/input/Freenect.h
SOURCES += src/input/Freenect.cc
} else {
message("Skipping support for libfreenect")
warning("Skipping support for the Kinect (missing libraries, see README)")
}
} else {
message("Skipping support for libfreenect")
message("Skipping support for the Kinect (unsupported platform)")
}

#
Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,11 @@ The OpenSceneGraph libraries provide 3D rendering to the map overlays that QGC c

OpenSceneGraph support is built-in to Mac OS X. On Linux it is commonly available through the libopenscenegraph and libopenscenegraph-qt developer packages. Windows support does not currently exist. This functionality with be automatically built if the proper libraries are installed.

### Kinect support
Microsoft's Kinect can be used by some autopilots for additional functionality. This is provided by the libfreenect libraries available on the Mac and Linux platforms.

This support is enabled by default and built-in when the appropriate libraries exist. To disable this behavior set the DISABLE_KINECT define when running qmake.

### XBee support
QGroundControl can talk to XBee wireless devices using their proprietary protocol directly on Windows and Linux platforms. This support is not necessary if you're not using XBee devices or aren't using their proprietary protocol. On Windows, the necessary dependencies are included in this repository and no additional steps are required. For Linux, change to the `libs/thirdParty/libxbee` folder and run `make;sudo make install` to install libxbee on your system (uninstalling can be done with a `sudo make uninstall`). qmake will automatically detect the library on Linux, so no other work is necessary.

Expand Down

0 comments on commit 9b3fcdd

Please sign in to comment.