← Back

ofxOsc

github.com/hideyukisaito/ofxOsc · @hideyukisaito
OF 0.7 Web/Networking

openframeworks OSC addon added event dispatching functionality when the receiver gets OSC message(s).

8 2 Last commit 13y ago Created 14y ago

README

hideyukisaito/ofxOsc

based on the ofxOsc included in of_preRelease_v007_osx changes: ofxOscReceiver dispatches ofEvent "onMessageReceived" with ofxOscMessage as ofEventArgs on received new message. So we can get ofxOscMessage without using receiver.hasWaitingMessages\(\). i.e.
void testApp::setup()
{
    receiver.setup(10000);
    ofAddListener(receiver.onMessageReceived, this, &testApp::onMessageReceived);
}

void testApp::onMessageReceived(ofxOscMessage &msg)
{
    string addr = msg.getAddress();
    string message = msg.getArgAsString();
}

Get this addon

HTTPS
SSH