Open Sound Control

From JReality Wiki
Jump to: navigation, search

jReality supports Open Sound Control using the NetUtil library. The main motivation is to have the option of creating tools that receive or send OSC messages to programs outside of jReality. Together with JACK input and output, this turns jReality into a universal tool for controlling and spatializing audio.

There isn't much to say about OSC in jReality, except that jReality comes with a utility class, OSCPool, that manages OSC clients and servers per socket. The idea is to make sure that many tools can share a server or client that is attached to a single socket.

When you need an OSC server, for instance, you should not create it directly but rather request one from OSCPool. After you receive an OSC client or server from OSCPool, you can use as usual, except that you shouldn't call its stop() method because you generally won't know whether someone else still wants to use it.