front_idill/extern/fajran-npTuioClient/example/events.html
author bastiena
Thu, 12 Apr 2012 15:33:25 +0200
changeset 28 9ccef81f02ab
parent 21 e4e5f02787a1
permissions -rw-r--r--
Charset set to UTF-8 without bom tab replaced by 4 spaces \r\n replaced by \n in non cs files
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     1
<!DOCTYPE html>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     2
<html>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     3
<head><title>TUIO Client plugin test</title>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     4
<style type="text/css">
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     5
body { margin: 0px; overflow: hidden; }
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     6
canvas { border: 1px solid black; }
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     7
</style>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     8
<script type="text/javascript" src="tuio.js"></script>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
     9
<script type="text/javascript">
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    10
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    11
function log(text) { 
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    12
    document.getElementById('log').innerHTML += text + "\n";
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    13
}
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    14
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    15
tuio.object_add(function(data) {
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    16
    log("[object] add: x=" + data.x + ", y=" + data.y);
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    17
});
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    18
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    19
tuio.object_update(function(data) {
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    20
    log("[object] update: x=" + data.x + ", y=" + data.y);
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    21
});
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    22
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    23
tuio.object_remove(function(data) {
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    24
    log("[object] remove: x=" + data.x + ", y=" + data.y);
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    25
});
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    26
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    27
tuio.cursor_add(function(data) {
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    28
    log("[cursor] add: x=" + data.x + ", y=" + data.y);
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    29
});
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    30
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    31
tuio.cursor_update(function(data) {
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    32
    log("[cursor] update: x=" + data.x + ", y=" + data.y);
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    33
});
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    34
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    35
tuio.cursor_remove(function(data) {
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    36
    log("[cursor] remove: x=" + data.x + ", y=" + data.y);
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    37
});
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    38
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    39
</script>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    40
</head>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    41
<body>
28
9ccef81f02ab Charset set to UTF-8 without bom
bastiena
parents: 21
diff changeset
    42
    
21
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    43
<object id="tuio" type="application/x-tuio">Plugin FAILED to load</object>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    44
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    45
<pre id="log"></pre>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    46
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    47
</body>
e4e5f02787a1 Front IDILL :
bastiena
parents:
diff changeset
    48
</html>