Controlling aerender via Scripting
Posted: September 25th, 2013, 6:07 am
Hello,
i am having a little bit of a problem in understanding how to control the aerender via scripting. The aerender is a command line or terminal app that requires arguments executed in the terminal in order to work. What is the best way to have a script pass these arguments to the terminal? Here is what i tried:
1. Creating a text file, saving it as a .command file and have the script manipulate the content of this file (adding new directories for instance), then execute. However, this fails because in order to be executable after each modification, the file must receive admin rights over and over again (it keeps asking for it no matter what i do). So this is not practical really and i would prefer to have a more direct way anyways.
2. Use apple script to first open the terminal and then passing arguments to it. But here is where i fail: I am using the system.callSystem(); thing in order to run the applescript. The following was just pieced together from various sources, including a post in this forum:
It's really weird. Sometimes this code works and actually manages to run the aerender. Of course without the arguments, the renderer won't work. When i add the arguments though, the whole thing fails. From that point on, nothing will work. I am not a huge expert for applescript but it feels like something i could understand quickly. But i am not sure if this is even necessary?
I don't want to bore you with too many details. What i need is really straight forward: I need a way to have a script pass command line arguments to the terminal in order to tell aerenderer what it needs to render and how. Somehow it feels like i am really close already. I might just need a small wink to the right direction.
i am having a little bit of a problem in understanding how to control the aerender via scripting. The aerender is a command line or terminal app that requires arguments executed in the terminal in order to work. What is the best way to have a script pass these arguments to the terminal? Here is what i tried:
1. Creating a text file, saving it as a .command file and have the script manipulate the content of this file (adding new directories for instance), then execute. However, this fails because in order to be executable after each modification, the file must receive admin rights over and over again (it keeps asking for it no matter what i do). So this is not practical really and i would prefer to have a more direct way anyways.
2. Use apple script to first open the terminal and then passing arguments to it. But here is where i fail: I am using the system.callSystem(); thing in order to run the applescript. The following was just pieced together from various sources, including a post in this forum:
Code: Select all
system.callSystem('osascript -e \' activate application "Terminal"\'') ;
system.callSystem('osascript -e \' tell application "Terminal" to open ["/Applications/Adobe\\ After\\ Effects\ CS5.5/aerender"] \'');
I don't want to bore you with too many details. What i need is really straight forward: I need a way to have a script pass command line arguments to the terminal in order to tell aerenderer what it needs to render and how. Somehow it feels like i am really close already. I might just need a small wink to the right direction.