Yup Text to Audio Macro

I do Cartoon Animation with Voice lip syncing so I had to beef up my Automator app to KM. With a few days of hacking scratching and testing I finally got something that works wonderful for me.
I am no programmer and I’ll never to claim to be one, I try my best and this is what I got.
Please feel free to remark and changes that would help this little macro out..

Cheers ヅ,
Bill 
Wednesday, March 16, 2016 10:12 PM

!!Text to audio!!.kmmacros (16.4 KB)

I think you don’t give yourself enough credit, that is a very well done macro - clearly well thought out and including good error reporting and handling.

My only pragmatic suggestion would be to turn on the Asynchronous mode in the Execute Macro actions that restart the macro. The reason for this is that Keyboard Maestro has a limit on the number of macros that can be running simultaneously (by default 50). This limit is really there to catch run away macros (such as one that restarts the macro every time). But its possible if you took a lot of tries to get the speech just right you might hit it. And there is no sense in the macro waiting around for the redo to finish and then continuing on since the very next action will cancel the macro anyway.

The “better” way to do this sort of thing (from a programming pedantic point of view) is something like this:

  • Set variable Done to 0
  • While variable Done is 0
    • Do stuff

Where Do stuff sets the Done variable to 1 or cancels the macro to exit the loop, and otherwise the loop repeats. But pragmatically your “redo” solution is just fine.

Very nice macro, thanks for sharing.

Thank you Peter
I have made the changes and works perfectly.
KM is the best, Thank you :smile:

1 Like