OpenFrameworks in max? also launching applications from Max?
Two questions:
1. Are there any sets of objects available for working with OpenFrameworks (e.g. running patches or interfacing to it)?
2. Is there a way to use max to launch other external applications located on the HD?
To launch applications (mac) put this in a message box:
;max launchbrowser "file:///Applications/iTunes.app/"
Replace "iTunes" with the app of your choice. Works the same for PC except your file path will be different? I think you need the file:/// regardless of PC or MAC
what object do I connect the message to?
is it also possible to close apps that you have opened?
nothing. just click it.
ah cool thanks!
any way to close the app once it has been opened?
I am looking through the "messages to max" and don't see it.
In fact if I had read the helpfile on this I never would have known I can use "launchbrowser" for anything other than opening a URL in a web browser/
Me neither, I only know about that command bcs I searched the forums the other day. Not sure how to close an application. Are you on a mac or pc? If Mac, maybe you can use a shell object (someone made one) and send a message to the terminal telling it to kill an application... I do not know :[
You could use thomas grill's py/pyext python externals to launch and control other apps. Depends how happy you are with python.
I'm quite keen on your first question, its very relevant to a project I'm collaborating on, is there a way to open and talk to OpenFrameWorks patches within max? In the same way you would with a bpatcher?
I know that there is an external for executing AppleScript in Max. And in AppleScript you can use the Scripting-Functions of an application or simply access the Cocoa-Accessibility-Framework which lets you explore and control every User-Interface (if it is using the Accessibility Framework which normally every UI-Element does) ...
Also, in most cases, you can access Data through the AppleScript-Bridge...
Just check' that out!
Simon
To quit apps, I use the same launch browser message as mentioned above, but then compile an apple script as an application, using the following:
tell application "[Application Name]"
quit
end tell
replacing [Application Name] with the name of your app (the name that appears in the dock when the application is run )
you can communicate with OpenFrameworks using udpsend / udpreceive
you may or may not want to format the messages as OSC. if so, you'll probably want to download the osc-route object from cnmat.
Hi I'm getting this
Max could not launch URL. err = -666
when i send
;max launchbrowser “file:///Applications/iTunes.app/“
did some body knows what happens ?
please
thanks
Tochtli, just remove the ""
in fact if you copy paste "" from the forums, you'll have troubles often, so just remove the "" you copypasted and type them back on. If you do this in a max message box for
;max launchbrowser “file:///Applications/iTunes.app/“
you'll see that the "" disappear. It's a problem of "" formatting : when on the forum, they are converted to ““ instead of "". As i'm typing it, i'm not even sure it will show any difference when this message will be posted, but the characters remain 'silently' different when you copypaste them.