Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
wss.on("connection", function(socket) {
console.log("Connection from Sema Editor");
var socketPort = new osc.WebSocketPort({
socket: socket
});
var relay = new osc.Relay(udp, socketPort, {
raw: true
});
});
wss.on("connection", function (socket) {
websocketPort = new osc.WebSocketPort({
socket: socket,
metadata: true
});
websocketPort.on("ready", function () {
console.log("OSC Relay ready!");
});
websocketPort.on("message", function (m) {
//console.log("An OSC Message was received!", m);
udpPort.send(m, "127.0.0.1", 57120);
});
websocketPort.on("error", function (e) {
console.log("websocketPort error: ", e);
});
wss.on("connection", function (socket) {
console.log("A Web Socket connection has been established!");
var socketPort = new osc.WebSocketPort({
socket: socket
});
var relay = new osc.Relay(udpPort, socketPort, {
raw: true
});
});
wss.on("connection", function (socket) {
console.log("A Web Socket connection has been established!");
var socketPort = new osc.WebSocketPort({
socket: socket
});
var relay = new osc.Relay(udp, socketPort, {
raw: true
});
});