hoijui / JavaOSC

OSC content format/"protocol" library for JVM languages
http://www.illposed.com/software/javaosc.html
BSD 3-Clause "New" or "Revised" License
156 stars 43 forks source link

Single socket for sending and receiving data #63

Closed Burtan closed 9 months ago

Burtan commented 2 years ago

Hey,

some clients for OSC like x32 mixer from Behringer require to have one port for incoming and outgoing messages. That is currently not possible. I have merged the functions of the OscPortIn and OscPortOut. Would you take a pull request to include the OscPortInOut?

Thanks :)

nsowen commented 2 years ago

As I also could not make JavaOSC communicate bi-directionally with X32, I submitted the following PR which allows using the OSCPortOut "Transport" to be used in a new OSCPortIn: https://github.com/hoijui/JavaOSC/pull/66

var out = new OSCPortOut(new OSCSerializerAndParserBuilder(), new InetSocketAddress("x32-ip", 10023)); var in = new OSCPortIn(out.getTransport()); in.startListening(); out.send(new OSCMessage("/info"));

Kindly check if that also works for you or maybe your approach is even better?

hoijui commented 9 months ago

Closing as duplicate of #40