LoginSignup
1
0

More than 5 years have passed since last update.

openFrameworksによるSonicPiとのOSC通信

Last updated at Posted at 2017-05-07

openFrameworksによるSonicPiとのOSC通信のメモ
sendMessage()のwrapInBundleをfalseに設定しなければいけない。

//--------------------------------------------------------------
void ofApp::setup(){
    // HOSTは"127.0.0.1" PORTは4557
    sender.setup(HOST, PORT);
}

//--------------------------------------------------------------
void ofApp::mousePressed(int x, int y, int button){
    ofxOscMessage message;
    message.setAddress("/run-code");
    message.addStringArg("from oF");
    message.addStringArg("play :C4");
    sender.sendMessage(message, false);
}

これでマウスをクリックしたらC4の音がなるはず。

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0