I should have been more clear in my description of option 2: Because the process is cyclic (determine picture -> decide which button (using algorithm written in C++)-> click the button -> determine picture -> etc.), I don't want to keep calling the program from hard disk. Script and Decider should both be running and somehow communicating, that's what option 2 entails. So back to the question: which option is better?