Does an open sound control library exists for javascript? I cant seem to find any information on this.
-
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? – Pointy Mar 30 '11 at 13:44
-
At the moment for use with Titanium SDK for iOS devices via TCP. – davivid Mar 30 '11 at 13:49
-
Take a look at what Charlie Roberts is doing with [Control](http://charlie-roberts.com/Control/): OSC music controllers written in JS. – forresto Apr 04 '11 at 20:38
-
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](http://developer.appcelerator.com/doc/mobile/iphone/module_sdk). It wouldn't be too difficult to write a module that wraps [oscpack](http://www.rossbencina.com/code/oscpack). – j b Apr 07 '11 at 12:08
-
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. – davivid Apr 07 '11 at 15:15
4 Answers
Implemented, client-side, in my KievII library. Here's a link to the code. Works nicely with my server-side, node.js, OSC Proxy.

- 6,333
- 8
- 55
- 73
-
2
-
Great if you're building a visual instrument interface for manual audio or lighting control. – doublejosh Jul 03 '17 at 01:05
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.:

- 81
- 5
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.

- 5,147
- 5
- 41
- 60
-
Thanks for the info, I wasn't really aware of what would be possible. MaxJax looks pretty interesting too. – davivid Apr 07 '11 at 15:17
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.

- 4,030
- 2
- 19
- 17