3 Replies Latest reply on Feb 23, 2016 6:46 AM by raphaelmatto14

    Is scripting multiple undo a bad idea?

    raphaelmatto14 Level 1

      Hi Premiere api peeps,


      I'm wondering how safe it is to undo an arbitrary number of times via jsx. I have this code:

      for (var i = 0; i < numTransitionsRemoved; i++) {

      ... in a larger script that in total removes all transitions, writes out a fcpxml file, then restores the transitions. I'm doing this because the fcpxml file won't have timecode in/out info unless the transitions are removed. The Premiere project can have lots of transitions. Probably not more than a few hundred, but possibly a thousand or more. I don't see an undo limit in Premiere prefs that would put a cap on the number of undos, but I'm guessing there may be an issue here with memory? Could you folks comment generally on what might go wrong? This seems to work in my tests with lots of transitions (a hundred or so), but I'm hesitant to send this code to my client w/o checking with you guys b/c it's not ideal. I also noticed there's an "undo_stack" method in there. How do I use that method? Could I potentially pinpoint a place in the undo stack with a single command, like:








        This content has been marked as final.  Show 3 replies