|
|
|
@ -7,7 +7,7 @@
@@ -7,7 +7,7 @@
|
|
|
|
|
* |
|
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
9000 => int OSCPort; |
|
|
|
|
7777 => int OSCPort; |
|
|
|
|
31000.0 => float Amplitude; |
|
|
|
|
|
|
|
|
|
OscOut xmit; |
|
|
|
@ -15,13 +15,7 @@ float dx, dy;
@@ -15,13 +15,7 @@ float dx, dy;
|
|
|
|
|
|
|
|
|
|
xmit.dest("localhost", OSCPort); |
|
|
|
|
|
|
|
|
|
// ---- clear the screen |
|
|
|
|
xmit.start("/joystick/b"); |
|
|
|
|
50 => xmit.add; 1 => xmit.add; |
|
|
|
|
xmit.send(); |
|
|
|
|
xmit.start("/joystick/b"); |
|
|
|
|
50 => xmit.add; 0 => xmit.add; |
|
|
|
|
xmit.send(); |
|
|
|
|
clear_the_screen(); |
|
|
|
|
|
|
|
|
|
for (0 => int foo; foo<25800; foo++) { |
|
|
|
|
<<< foo >>>; |
|
|
|
@ -34,7 +28,15 @@ for (0 => int foo; foo<25800; foo++) {
@@ -34,7 +28,15 @@ for (0 => int foo; foo<25800; foo++) {
|
|
|
|
|
Std.ftoi(dy) => xmit.add; |
|
|
|
|
xmit.send(); |
|
|
|
|
|
|
|
|
|
0.03::second => now; |
|
|
|
|
|
|
|
|
|
0.02::second => now; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
fun void clear_the_screen() |
|
|
|
|
{ |
|
|
|
|
xmit.start("/joystick/b"); |
|
|
|
|
50 => xmit.add; 1 => xmit.add; |
|
|
|
|
xmit.send(); |
|
|
|
|
xmit.start("/joystick/b"); |
|
|
|
|
50 => xmit.add; 0 => xmit.add; |
|
|
|
|
xmit.send(); |
|
|
|
|
} |
|
|
|
|