this ofxOscReceiver doesn't terminate when receive broken packet.
based on ofxOsc@oF0.9.2
.
this addon trashes broken packets with error messages.
i think, this error handling is not best but, as better than app terminate.
(i posted PR about this problem to openFrameworks community.)
PLEASE USE AT YOUR OWN RISK.
basicly, same as ofxOsc
.
add 1 future. got event as:
void setup() {
ofAddListener(receiver.gotOscError, this, &ofApp::oscError);
if(!receiver.setup(8888)) {
ofLogError() << "setup failured";
}
}
void oscError(std::string &what) {
ofLogWarning() << what;
}
- change return value of
setup
to bool. ifsetup
got failure then return false.
- simplify.
- add future: notify gotError event with error message.
- post PR on openFrameworks#4998 without notify event. (maybe if occurs diff of API, will not merge while oF0.9.x) and, i can't get no.5000.
- first aid.
MIT License.
- Ross Bencina
- rossb@audiomulch.com
- Copyright (c) 2004
- ISHII 2bit [bufferRenaiss co., ltd.]
- ishii[at]buffer-renaiss.com