Skip to content

futureinv/tuio_scratch

Repository files navigation

(English version below)

Scratch_TUIO

TUIO, come si può leggere sul sito di riferimento, è un protocollo di comunicazione per superfici multitouch. Il protocollo TUIO consente la trasmissione di una descrizione astratta, come la posizione o la direzione di cursori o markers, tramite superfici interattive. Questo protocollo codifica i dati da un'applicazione tracker (ad esempio basata sulla visione artificiale) e li invia a qualsiasi applicazione client in grado di decodificare il protocollo.

Scratch_TUIO è un'estensione di Scratch che consente l'utilizzo di dati TUIO tramite un client server, per produrre una nuova modalità di interazioine

Requisiti

  • OS
    • Windows 8
    • Windows 10
    • MacOS
    • iOS
  • Browser
    • Chrome
    • Safari(iOS)
  • server
  • software aggiuntivi
    • reactivision
  • simulatore
  • webcam

Installazione

Windows

  • Scarica l'installer di NodeJS da qui. Una volta scaricato fai doppio click per installare: per mandare avanti l'installazione è sufficiente cliccare sempre su Next, ma nella seconda schermata è necessario selezionare "I accept the terms in the license Agreement". L'installazione può richiedere qualche minuto e il sistema potrebbe chiedere di inserire la password di amministratore.
  • Scarica ReacTIVision da questo link. Scompatta lo Zip.
  • Scarica il server TUIO da questo link e scompatta lo Zip.
  • Se vuoi usare l'estensione offline scaricala da questo link e scompatta lo Zip, se invece vuoi usarla online questo passaggio non è necessario.

Come usare l'estensione

  • Nella cartella reacTIVision fai partire reacTIVision.exe.
  • Nella cartella in cui hai scaricato il server TUIO fai partire server.bat.
  • Apri nel tuo browser preferito l'estensione scratch. Se vuoi usarla online la trovi qui. Se invece vuoi usarla offline apri la cartella con l'estensione che hai scaricato e lancia index.html.

Esempi d'uso

Importare i blocchi dell'estensione

  1. Clicca il pulsante "Aggiungi estensione" in basso a sinistra.

  1. Seleziona "scratch_TUIO".

  1. Adesso puoi utilizzare i blocchi dell'estensione.

  1. IMPORTANTE Affinchè i comandi dell'estensione funzionino, c'è bisogno di stabilire un collegamento con il server. Questo comando deve essere sempre presente.

Controllare il movimento dello Sprite

Assicurarsi di selezionare il numero del Marker che si sta utilizzando nel menù a tendina.

Controllare la rotazione dello Sprite

Da questo mnenù a tendina è possibile decidere se controllare la posizione o la rotazione dello SPrite tramite il Marker.

Tracciare una linea colorata

Nel caso in cui dovesse continuare a comparire una linea colorata anche dopo aver eliminato il codice, cliccare sul comando "penna su" nella lista dei comandi.

Cambiare lo sfondo

Creare una pallina che rimabalza

Applicare il primo codice sullo Sprite controllato dal Marker.

Selezionare poi la palla o l'oggetto da far rimbalzare.

Licenza

Distribuito con licenza BSD 3-Clause "New" or "Revised" License. Vedi il file LICENSE.txt per ulteriori informazioni.

Ringraziamenti

Ulteriori informazioni tecniche (per sviluppatori)

Dipendenze

  • Node-LTS-Hydrogen 18.19.0
  • scratch-gui v. 3.0.5
  • scratch-vm v. 2.0.3

Prerequisiti

  • Yarn npm install --global yarn

Installazione

cd tuio-client && yarn install && yarn link
cd scratch-vm && yarn link tuio-client && yarn install && yarn link
cd scratch-gui && yarn link scratch-vm && yarn install
cd tuio-server && yarn install

Esecuzione

cd scratch-gui && yarn start &
node ../tuio-server/index.js &

Apri il browser a localhost:8601

English version:

Scratch_TUIO

TUIO is a communication protocol for multitouch surfaces, more information can be read on the reference site . The TUIO protocol allows the transmission of an abstract description, such as the position or direction of sliders or markers, via interactive surfaces. This protocol encodes data from a tracker application (e.g., machine vision-based) and sends it to any client application that can decode the protocol.

Scratch_TUIO is an extension to Scratch that allows TUIO data to be used via a client server, to produce a new mode of interazioine

technical requirements

  • OS
    • Windows 8
    • Windows 10
    • MacOS
    • iOS
  • Browser
    • Chrome
    • Safari(iOS)
  • server
  • additional software
    • reactivision
  • simulator
  • webcam

Installation

Windows

  • Download the NodeJS installer from here. Once downloaded, double-click to install: to send the installation forward, always click Next; on the second screen you must select “I accept the terms in the license Agreement.” The installation may take a few minutes and the system may ask you to enter the administrator password.
  • Download ReacTIVision from this link. Unzip.
  • Download TUIO server from this link and unzip it.
  • If you prefer to use the extension offline, download it from this link unzip it, if you prefer to use it online, this passage is not necessary.

Come usare l'estensione

  • In reacTIVision folder launch reacTIVision.exe.
  • In TUIO server folder launch server.bat.
  • Use the extension in your favourite browser. You find it online here. If ypou prefer to use it offline, open the folder you downloaded and launch index.html.

Examples of use.

Import the extension blocks.

  1. Click the “Add Extension” button in the lower left corner.

  1. Select “scratch_TUIO.”

  1. Now you can use the extension blocks.

  1. IMPORTANT In order for the extension commands to work, you need to establish a connection with the server. This command must always be present.

Translated with DeepL.com (free version)

Check the movement of the Sprite.

Be sure to select the number of the Marker you are using in the drop-down menu.

Control the rotation of the Sprite.

From this drop-down mnenu you can decide whether to control the position or rotation of the SPrite by the Marker.

### Draw a colored line.

In case a colored line continues to appear even after deleting the code, click on the “pen on” command in the command list.

Change the background

Creare una pallina che rimabalza

Applicare il primo codice sullo Sprite controllato dal Marker.

Selezionare poi la palla o l'oggetto da far rimbalzare.

Licenza

Distribuito con licenza BSD 3-Clause "New" or "Revised" License. Vedi il file LICENSE.txt per ulteriori informazioni.

Ringraziamenti

Ulteriori informazioni tecniche (per sviluppatori)

Dipendenze

  • Node-LTS-Hydrogen 18.19.0
  • scratch-gui v. 3.0.5
  • scratch-vm v. 2.0.3

Prerequisiti

  • Yarn npm install --global yarn

Installazione

cd tuio-client && yarn install && yarn link
cd scratch-vm && yarn link tuio-client && yarn install && yarn link
cd scratch-gui && yarn link scratch-vm && yarn install
cd tuio-server && yarn install

Esecuzione

cd scratch-gui && yarn start &
node ../tuio-server/index.js &
cd ../tuio-simulator && java -jar TuioSimulator.jar

Apri il browser a localhost:8601

About

Scratch 3 extension for Tuio Markers

Resources

License

Stars

1 star

Watchers

2 watching

Forks

Packages

 
 
 

Contributors