public static void Main(String[] argv) { TuioDump demo = new TuioDump(); SquareTuioClient client = null; switch (argv.Length) { case 1: int port = 0; port = int.Parse(argv[0], null); if (port > 0) { client = new SquareTuioClient(port); } break; case 0: client = new SquareTuioClient(3333); break; } if (client != null) { client.addTuioListener(demo); client.addSquareTuioListener(demo); client.connect(); Console.WriteLine("listening to TUIO messages at port " + client.getPort()); } else { Console.WriteLine("usage: java TuioDump [port]"); } }
private void wSurface_Loaded(object sender, RoutedEventArgs e) { client = new SquareTuioClient(Settings.Default.TUIO_PORT); client.addTuioListener(this); client.addSquareTuioListener(tsListener); bConnect_Click(null, null); Console.WriteLine("listening to TUIO messages at port " + client.getPort()); }
private void Window_Loaded(object sender, RoutedEventArgs e) { SquareTuioClient client = null; client = new SquareTuioClient(3333); client.addTuioListener(this); client.addSquareTuioListener(this); client.connect(); Console.WriteLine("listening to TUIO messages at port " + client.getPort()); }