javascript osc library?
Asked Answered
K

4

10

Does an open sound control library exists for javascript? I cant seem to find any information on this.

Klinges answered 30/3, 2011 at 13:42 Comment(5)
In what context are you hoping to use such a thing? That is, are you hoping to use this in a browser, or are you working with something like node.js or Rhino?Nore
At the moment for use with Titanium SDK for iOS devices via TCP.Klinges
Take a look at what Charlie Roberts is doing with Control: OSC music controllers written in JS.Insectarium
If the question is how to get OSC support on iOS using Titanium SDK, one option is to write a custom module using the module SDK. It wouldn't be too difficult to write a module that wraps oscpack.Biotic
Control Certainly looks interesting, and maybe I could give PhoneGap a try instead. I was hoping there might be some existing way, since I don't yet feel I could write a module.Klinges
E
2

Web sockets are, indeed, the best way to implement OSC in a browser - but, with lacking support, the next-best thing is a custom HTTP server. An effort is underway to build one - I've not checked out the process, so have a look yourself to see if it fits your purposes.

Eskill answered 28/11, 2011 at 21:36 Comment(0)
P
13

Implemented, client-side, in my KievII library. Here's a link to the code. Works nicely with my server-side, node.js, OSC Proxy.

Pagepageant answered 26/11, 2012 at 9:36 Comment(2)
seconded. Kiev is awesome.Middlebrow
Great if you're building a visual instrument interface for manual audio or lighting control.Dyspeptic
F
3

I've recently worked on a OSC library (UMD module written in ES6) named osc-js for different JavaScript applications (Node.js, Electron, Chrome Apps, webpages) with address pattern matching, WebSocket-/UDP Plugins and some solutions to connect it to MaxMSP/PureData/etc.:

https://github.com/adzialocha/osc-js

Fucus answered 14/5, 2014 at 15:18 Comment(1)
Excellent utility libraryDyspeptic
B
2

I think a JavaScript OSC library, that works in the conventional way (e.g. using a UDP or TCP transport) is not possible due to the lack of low-level networking functionality provided in current browser-based implementations of the JavaScript. Cross-domain scripting limitations would also limit the usefulness of a browser-based OSC implementation IMO.

JavaScript OSC is possible by using custom XPCOM components, but at best, such solutions are going to be browser-specific.

One possibility might be to run OSC over a higher-level protocol. OSC over JSONP springs to mind as a potential area for exploration. Something similar to the MaxJax project, which implements OSC for the Python Twisted web server.

Biotic answered 5/4, 2011 at 13:25 Comment(1)
Thanks for the info, I wasn't really aware of what would be possible. MaxJax looks pretty interesting too.Klinges
E
2

Web sockets are, indeed, the best way to implement OSC in a browser - but, with lacking support, the next-best thing is a custom HTTP server. An effort is underway to build one - I've not checked out the process, so have a look yourself to see if it fits your purposes.

Eskill answered 28/11, 2011 at 21:36 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.