Skip to content

A JavaScript implementation of the TUIO protocol for multitouch and tangible interaction for NodeWebkit (nwjs).

License

Notifications You must be signed in to change notification settings

fthozdemir/tuio-nw

 
 

Repository files navigation

tuio-nw NPM version Build Status Dependency Status Coverage percentage

A JavaScript implementation of the TUIO protocol for multitouch and tangible interaction for NodeWebkit (nw).

Install

$ npm install tuio-nw

Usage

var Tuio = require('tuio-nw');
var tuioClient = new Tuio.Client({
  host: '127.0.0.1',
  port: 3333
});

var onAddTuioCursor = function (addCursor) {
  console.log(addCursor);
},

onUpdateTuioCursor = function (updateCursor) {
  console.log(updateCursor);
},

onRemoveTuioCursor = function (removeCursor) {
  console.log(removeCursor);
},

onAddTuioObject = function (addObject) {
  console.log(addObject);
},

onUpdateTuioObject = function (updateObject) {
  console.log(updateObject);
},

onRemoveTuioObject = function (removeObject) {
  console.log(removeObject);
},

onRefresh = function (time) {
  console.log(time);
};

tuioClient.on('addTuioCursor', onAddTuioCursor);
tuioClient.on('updateTuioCursor', onUpdateTuioCursor);
tuioClient.on('removeTuioCursor', onRemoveTuioCursor);
tuioClient.on('addTuioObject', onAddTuioObject);
tuioClient.on('updateTuioObject', onUpdateTuioObject);
tuioClient.on('removeTuioObject', onRemoveTuioObject);
tuioClient.on('refresh', onRefresh);

tuioClient.listen();

License

MIT © Diego Montesinos

About

A JavaScript implementation of the TUIO protocol for multitouch and tangible interaction for NodeWebkit (nwjs).

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%