spceaza / libfreenectr

Interfaces to R

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

libfreenectr

Installation

Install the development version from GitHub:

$ git clone --recursive https://github.com/cesandovalp/libfreenectr
$ R CMD build libfreenectr;
$ R CMD INSTALL libfreenectr_0.1.tar.gz

Examples

SetTiltDegrees

library(libfreenectr)

CreateSimpleDevice()

SetTiltDegrees( 30 )
Sys.sleep( 2 )
SetTiltDegrees( 0 )
Sys.sleep( 2 )
SetTiltDegrees( -30 )
Sys.sleep( 2 )
SetTiltDegrees( 0 )

SetLed

library(libfreenectr)

CreateSimpleDevice()

SetLed( "red" )
Sys.sleep( 2 )
SetLed( "green" )
Sys.sleep( 2 )
SetLed( "off" )

Take a photo

library(libfreenectr)
library(pixmap)

CreateSimpleDevice()
StartVideo()
photo = GetPhoto( )
plot( photo )

SetHighResolution()
photo = GetPhoto( )
plot( photo )

Take a depth photo

library(libfreenectr)
library(pixmap)

CreateSimpleDevice()
StartDepth()
photo = GetDepth( )
plot( photo )

StartVideo

library(libfreenectr)

CreateSimpleDevice()
StartVideo()
StartGLUTVideo( )

StartVideo Max Resolution

library(libfreenectr)

CreateSimpleDevice()
StartVideo()
SetHighResolution()
StartGLUTVideo( )

About

Interfaces to R


Languages

Language:C++ 87.1%Language:R 12.9%