Feb-17-2017, 12:19 AM
It somewhat depends on how savagely you can kill what is currently running, and/or how often your timer loop gets control. You are using a rather "soft" method which could be adequate in some cases.
The "hard" method would be to spin off a thread to do the work, while the main thead just sleeps 60 seconds. When it wakes up, it kills the other thread and exits. Killing a thread is explained here
The "hard" method would be to spin off a thread to do the work, while the main thead just sleeps 60 seconds. When it wakes up, it kills the other thread and exits. Killing a thread is explained here
Unless noted otherwise, code in my posts should be understood as "coding suggestions", and its use may require more neurones than the two necessary for Ctrl-C/Ctrl-V.
Your one-stop place for all your GIMP needs: gimp-forum.net
Your one-stop place for all your GIMP needs: gimp-forum.net