osc: receive osc bundles
This commit is contained in:
parent
4552bd6657
commit
a8bbb02c67
2 changed files with 9 additions and 4 deletions
|
|
@ -101,9 +101,13 @@ var oscOutFilter = function(data){
|
|||
}
|
||||
|
||||
|
||||
oscServer.on('message', function (msg, bundle, info) {
|
||||
var data = oscInFilter({address: msg.address, args: msg.args, host: info.address, port: info.port})
|
||||
receiveOsc(data)
|
||||
oscServer.on('message', function (msg, timetag, info) {
|
||||
var delay = timetag? Math.max(0,timetag.native - Date.now()) : 0,
|
||||
timer = delay ? setTimeout : setImmediate
|
||||
setTimeout(()=>{
|
||||
var data = oscInFilter({address: msg.address, args: msg.args, host: info.address, port: info.port})
|
||||
receiveOsc(data)
|
||||
}, delay)
|
||||
})
|
||||
|
||||
oscServer.on('error', function (error) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue