@@ -0,0 +1,2669 @@
+  /*%0A *%0A * HYPE_Processing%0A * http://www.hypeframework.org/ & https://github.com/hype/HYPE_Processing%0A * %0A * Copyright (c) 2013-2015 Joshua Davis & James Cruz%0A * %0A * Distributed under the BSD License. See LICENSE.txt for details.%0A * %0A * All rights reserved.%0A *%0A * ----- *%0A * HScreenshot - just a quick and dirty way to grab PNGs for conversion in video / animated gifts etc *%0A * Tested using processing 3.0.1 (It may break on newer versions of processing) *%0A * If you find any issues or make anything cool with this, let me know on twitter at @Garth_D *%0A * Future enhancements would be to change image format / name of output folder *%0A */%0A%0Apackage hype;%0A%0A%0Aimport processing.core.PApplet;%0A%0Apublic class HScreenshot %7B%0A %0A  private String filename;%0A  private int  start, end, frequency;%0A  private int suffix;%0A  private String strNumericAppend;%0A  private int counter;%0A  private boolean isRecording;%0A  private boolean exit;%0A%0A  public HScreenshot() %7B%0A    start = end = 1;%0A    frequency = 1;%0A    exit=false;%0A  %7D%0A%0A  public HScreenshot capture() %7B%0A    start = end = 1;%0A    return this;%0A  %7D%0A%0A  public HScreenshot capture(int frameNum) %7B%0A    start = end = frameNum;%0A    return this;%0A  %7D%0A%0A  public HScreenshot start(int frameNum) %7B%0A    start = frameNum;%0A    return this;%0A  %7D%0A%0A  public int start() %7B%0A    return start;%0A  %7D%0A%0A  public HScreenshot end(int frameNum) %7B%0A    end = frameNum;%0A    return this;%0A  %7D%0A%0A  public int end() %7B%0A    return end;%0A  %7D%0A%0A  public HScreenshot frequency(int f) %7B%0A    frequency = f;%0A    return this;%0A  %7D%0A%0A  public int frequency() %7B%0A    return frequency;%0A  %7D%0A%0A  public boolean isRecording() %7B%0A    return isRecording;%0A  %7D%0A%0A  public HScreenshot exit(boolean b) %7B%0A    exit = b;%0A    return this;%0A  %7D%0A%0A  public boolean exit() %7B%0A    return exit;%0A  %7D%0A%0A  public HScreenshot filename(String s) %7B%0A    filename = s;%0A    return this;%0A  %7D%0A%0A  public String filename() %7B%0A    return filename;%0A  %7D%0A%0A  public void run() %7B%0A    ++counter;%0A%0A    isRecording = false;%0A    %0A    if (H.app().frameCount %3E end %7C%7C H.app().frameCount %3C start) %7B%0A      //don't save anything%0A%0A      if (H.app().frameCount %3E end && exit)%0A      %7B%0A        H.app().exit();%0A      %7D;%0A    %7D else%0A      if (counter%25frequency==0) %7B%0A%0A        isRecording = true;%0A        ++suffix;%0A%0A        if (suffix%3C10) %7B%0A          strNumericAppend = %220000%22;%0A        %7D%0A%0A        if (suffix%3E=10 && suffix%3C100) %7B%0A          strNumericAppend = %22000%22;%0A        %7D%0A%0A        if (suffix%3E=100 && suffix%3C1000) %7B%0A          strNumericAppend = %2200%22;%0A        %7D%0A%0A        if (suffix%3E=1000 && suffix%3C10000) %7B%0A          strNumericAppend = %220%22;%0A        %7D%0A%0A        H.app().saveFrame(%22output/%22 + filename + strNumericAppend + suffix + %22.png%22);%0A      %7D%0A  %7D%0A%7D%0A

Create HScreenshot.java