OSC addresses (specifically for the old Hexler TouchOSC app)
The XY pad will show up in the app with an address like :
/1/xy1
To use this message you'll want to use code that is similar to:
void ofApp::update(){
while (osc.hasWaitingMessages()) {
ofxOscMessage m; //m for message, a variable which is a message
osc.getNextMessage(&m);
if (m.getAddress() == "/1/xy1") {
oscx = m.getArgAsFloat(0);
}
if (m.getAddress() == "/1/xy1") {
oscy = m.getArgAsFloat(1);
}
}
}
For full OSC code refer to Lewis Lepton's tutorial on youtube -
https://youtu.be/vMgADShsAuI?list=PL4neAtv21WOlqpDzGqbGM_WN2hc5ZaVv7
Comments
Post a Comment