How to save multiple .PDF files from the same sketch?

edited May 2016 in How To...

Hey Guys,

So i've currently set a sketch so that it exports a PDF (for editing in Adobe Illustrator), using thebeginRecord(PDF, "example.pdf"); function every time i press the RIGHT key.

//save the file as vector - ready
    void keyPressed () {
      if (key == CODED) {
        if (keyCode == RIGHT) {
              endRecord();

The problem is, that i want to export multiple PDF's at different times when drawing in my sketch. Currently, the sketch will only override the name i've programmed it to save as.

I know that when using the saveFrame function you can add ## to the end and processing will create a counter, but this appears to not be the case with beginRecord .

Any thoughts?

Thanks

Tagged:

Answers

  • Answer ✓

    do you have multiple beginRecord()s as well as multiple endRecord()s? i think you need to.

    just change the filename in the beginRecord(). use a counter, or frameCount, or simpleDateFormat to generate a unique filename.

Sign In or Register to comment.