UPDD Commander can function as a TUIO server, that can be enabled to direct touches to a TUIO client application, and also as a TUIO client, to receive data from an independent TUIO server used to control touches on a system monitor.
TUIO Client applications are applications that have be written, or have an option, to receive touch information via the TUIO protocol.
The pathway schematic being:
Touch hardware > UPDD driver > UPDD API > UPDD Commander TUIO Server > TUIO client application > End user interaction
TUIO server can be set to run at the system wide level or at the application / group level.
You add the TUIO server using the add gesture control. Select the 'All Applications' or the desired Group or Application entry in the Application list and select the 'Add' gesture control:
This will add the TUIO server entry into the gesture list within the selected Application list entry:
Set the TUIO settings as required.
TUIO Application presets
Application Presets exist to set All Applications exclusively to TUIO whereby gesture functionality is disabled.
You can also use the Preset option to set the Browser Group to work as a TUIO server within the web content UI element by switching to the 'Browser (TUIO)' configuration:
Individual application TUIO configuration
Specifying a TUIO client application in UPDD Commander is very straight-forward:
- Add the TUIO Client application in the Application list
- Add the All Touches - Convert Touches to TUIO option for the application
- Set the required application settings (defaults are likely to be OK if the Client application is running on the same computer)
- Disable inherited settings if gestures are not required to be posted to the TUIO client application
TUIO settings fall into two categories, application and global.
Application TUIO settings
These setting relate to the application level.
Host and server port
Defines the local IP address and post on which to transmit all touch data.
In most usage cases the TUIO server will be running locally on the same computer as the TUIO client program then a reasonable default configuration is for it to use localhost with the default TUIO IP address (127.0.0.1), port number (3333)
When an application is configured to run as a TUIO server there are some additional advanced options.
In the TUIO server application component select the Advanced Options... button:
Configure TUIO servers separately for each UPDD device
If required you can configure TUIO to send touches to different hosts and ports depending on which touch device it comes from, in essence running multiple TUIO servers at once. This checkbox switches between using the same TUIO host and port for all touch devices, and using different settings for each touch device. When checked, it lists each device configured in the driver and gives a field for setting its host and port. Each device does not need to have a unique TUIO host and port, and multiple devices can be configured to use the same TUIO host and port if you wish. Since most usage cases for a TUIO server is to have it running locally on the same computer that the TUIO client programs are running on, a reasonable default configuration is for it to use localhost with the default TUIO port number 3333.
TUIO touch positions
Relative to display: the positions of the TUIO cursors will be calculated using the entire area of the display, such that touches in the top-left corner of the display will have a normalized coordinate of (0,0) and touches in the bottom right corner will have normalized coordinates of (1,1).
Relative to display, dividing X axis evenly between touch devices: Similar to "Relative to display", TUIO cursor positions are calculated using the entire area of the display, but each device that is configured to use the same TUIO host and port will be scaled and translated horizontally so that it occupies a different equally-wide portion of the X axis, using the left-to-right order of the monitors as they are arranged in the system configuration.
- If two devices are using the same host and port, then the device that occupies the leftmost region of the system's desktop will have its TUIO cursors' X coordinates range from 0.0 to 0.5, and the device that uses the rightmost region will have its TUIO cursors' X coordinates range from 0.5 to 1.0.
- If there are four UPDD devices, then all touches on the leftmost device will be converted to TUIO cursors where their minimum X value is 0 and their maximum X value is 0.25. The touches on the second device from the left will have a range of 0.25 to 0.5, the third device will have a range of 0.5 to 0.75, and so on.
The left to right order is determined by the system's display configuration.
Therefore, to get the proper coordinates for a TUIO device, simply define the X coordinates to a range of 0.0 to 1.0. The Y coordinates are unaffected.
This allows a single TUIO client to distinguish which TUIO cursor originated from which device.
Relative to window: the positions of the TUIO cursors will be calculated relative to the frame of the window that the touches fall within, such that touches at the top-left corner of the window will have a normalized coordinate of (0,0) and touches at the bottom-right corner will have a normalized coordinate of (1,1).
Global TUIO settings
These setting relate to the global level.
These settings relate to the UPDD TUIO server and are located in the main Settings dialog, TUIO tab:
Send TUIO packets at the same rate as the UPDD
The TUIO server time stamps TUIO frames. By default this is as close as possible to 60 frames per second as per the TUIO specification. This setting can be used to transmit the frames at the same rate they are received from the driver albeit this does not conform to the TUIO specification. Any application written to retrieve frame times will also receive valid timestamps.
In our tests we achieved a UPDD TUIO data rate up to about 200 packets per second, although this speed will vary depending on hardware in use.
Send TUIO packets using WebSocket protocol in addition to UDP
This setting indicates that TUIO packets are transmitted using the WebSocket protocol in addition to the UDP protocol. This is required to satisfy Browsers using our Browser TUIO bridge implementation.
These settings relate to the UPDD Commander running as a TUIO client application configured to receive data from an independent TUIO server to control touch on a specified monitor:
To enable this function enable the ‘Receive touches from TUIO’ and specify the relevant port. Further, in a multi-monitor system select the monitor to be controlled.
Within UPDD Commander web browsers can be configured in a number of ways:
|| Emulate iOS (iPhone/iPad) browser function - singe touch can be used to scroll browser content
|| Interact in the same manner as a standard trackpad - single touch performs click and drag
|| Receive touch via TUIO to satisfy multi-touch browser applications as described here.
UPDD Test has an option to Render Touches from TUIO Interface and thus acting as a TUIO client. It is for this reason UPDD Test is defined in the Application List as a separate entry such that it is configured as a TUIO Client application (as shown in the application settings example above).