How to incrementally save images using a hotkey

What I'm hoping to accomplish is as follows:
Draw a line, then
Press a hotkey to Play an Action.
     The action needs to save an incremental .jpeg
     and then select the previous history state.
The goal being that everytime I try to undo a mark, I have a copy of the image with the mistake, creating a record of the process. I have absolutely no knowledge of scripting. I will basically use this as an alternative undo key.
I am working on a project in which I need to save "snapshots" of my progress. Basically I'm working on a digital sketchbook and am trying to record the progress of every mark I make on the page. My workflow for this project entails the drawing of a line and then selecting of the previous history state, erasing the lines I do not want and layering the ones I do. The idea being that I can catologue my entire workflow and progress in a series of images to post to my sketchbook blog. This is part of a longterm project to track improvement and I'm am following this ideal for multitudes of images each day.
I suppose all I'm asking for here is a script that will run and save a .jpeg of the current .psd, adding a "_001, _002, _003" suffix to the filename, checking to see if the current suffix is taken and changing to the next one. This way I can catalogue the "snapshots" of mutiple images in the same folder.
Using Photoshop CS5 on OSX Snow Leopard.

Try this....
#target photoshop
main();
function main(){
if(!documents.length) return;
var Name = app.activeDocument.name.replace(/\.[^\.]+$/, '');
try{
var savePath = activeDocument.path;
}catch(e){
    alert("You must save this document first!");
var fileList= savePath.getFiles(Name +"*.jpg").sort().reverse();
var Suffix = 0;
if(fileList.length){
    Suffix = Number(fileList[0].name.replace(/\.[^\.]+$/, '').match(/\d+$/));
Suffix= zeroPad(Suffix + 1, 3);
var saveFile = File(savePath + "/" + Name + "_" + Suffix + ".jpg");
SaveJPEG(saveFile, 8);
function SaveJPEG(saveFile, jpegQuality){
jpgSaveOptions = new JPEGSaveOptions();
jpgSaveOptions.embedColorProfile = true;
jpgSaveOptions.formatOptions = FormatOptions.STANDARDBASELINE;
jpgSaveOptions.matte = MatteType.NONE;
jpgSaveOptions.quality = jpegQuality;
activeDocument.saveAs(saveFile, jpgSaveOptions, true,Extension.LOWERCASE);
function zeroPad(n, s) {
   n = n.toString();
   while (n.length < s)  n = '0' + n;
   return n;

Similar Messages

  • How do I save images in mail to photos on iPhone iOS 7

    How do I save images in Mail to Photos on iPhone using iOS 7?

    Thanks.  It worked this time.  I tried the same earlier when it did not.
    Thanks. AJ

  • How do I save images?

    its probably very simple and ill feel stupid reading the answer but how do i save images while browsing on my phone

    dmcritchie that won't work on Firefox mobile.
    If you can open the image directly such as http://upload.wikimedia.org/wikipedia/en/7/73/UpHellyAa7%28AnneBurgess%2930Jan1973.jpg if you long click on the image you will get a context menu with save image as an option. If the image is part of a page I don't think you will be able to save the image.

  • How to increment the date using sequence?

    how to increment the date using sequence?
    01-jan-10
    02-jan-10
    30-jan-10

    794244 wrote:
    how to increment the date using sequence?
    01-jan-10
    02-jan-10
    30-jan-10This doesn't look like a task where a sequence is usefull.
    A sequence is a number generator that guarantees that multiple sessions will all get a different number.
    Even if the sequence is fetched for differnent users (=sessions) that the same time.
    This in turn means that the value returned by the sequence will depend on actions done in other sessions.
    Typical task: create a new unique primary key number. The number MUST be different in all sessions.
    In your case I guess that the same logic should work regardless of the session that executes it. So you need a "number generator" that works indepented from other session values. There are several ways to create such a numbered list.
    The basic idea is to create a select statement that simply returns as many rows as you need. And then use ROWNUM as the number generator. Examples how to do this have already been given. LEVEL works also in hierarchical queries.
    if my interpretation of your requirement is right, then all answers that really used a sequence seem to be wrong. Even if the output looks ok. At best they are just slow. To create new sequence values is a complex task and the database needs a little time for all the synchonization issues that come with it. At worst it will have gaps in the sequence because other sessions used the same value while the numbers were created.
    Edited by: Sven W. on Sep 20, 2010 2:08 PM

  • How can I save images in usb connected to NI 1772C camera using labview?

    Hi, I am trying to save acquired images in usb connected to smart camera using labview.
    I want to know file path (address of usb connected to the camera)  for save images but I have no idea to find that.
    I will appriciate it for any advice about how to figure the file path or how to access the usb by max or anything.
    Thank you!
    Dana Choi

    An external USB key connected to that camera should be accessible as U:\.
    Eric

  • Save image using write file2

    I am acquiring real time images using laptop web camera.
    I want to save them and read them to use in another application.
    I connected the vision acquisition express to imaq write file 2.
    I used imaq read file to read the written image files.
    When I tried I encountered the following problem."Error -1074395989 occurred at IMAQ ReadFile
    Possible reason(s):
    IMAQ Vision: Unable to read data"
    Thank you for your help.

    Hello,
    Can you show the VI you are using to save and to load the image file?
    Here's a little example for how to read an image from file and display it :
    Hope this helps
    When my feet touch the ground each morning the devil thinks "bloody hell... He's up again!"

  • How do I save image and text as a single image in InDesign CS5.0?

    How do I save an image and text as one image in InDesign CS5.0? NOT 5.5.
    I need to save the image as a 72-dpi, jpg file for ePub purposes. I designed a book and am handing it off to someone for ePub.
    This is what I've tried:
    1) Copied from InDesign, pasted into a PhotoShop doc as a Smart Object. Saved it as 72 dpi jpg, then imported back into ID.
    2) Took a screenshot of ID page, placed it in PS, saved as 72 dpi, imported into ID
    3) Saved page as a PDF from InDesign, then saved PDF as 72 dpi jpg, then imported into ID.
    4) Save page as a PDF from InDesign, placed into Photoshop and saved
    as 72 dpi, then imported into ID.
    5) Saved as an EPS from InDesign, placed in PS, then imported back to ID.
    In all cases, the type looks terrible. It doesn't seem to matter whether I copy or place into Photoshop, though placing is slightly better.
    HELP!!!

    In all cases, the type looks terrible. It doesn't seem to matter whether I copy or place into Photoshop, though placing is slightly better.
    Naturally what you did will result in rasterized text. Did you preview with high quality settings?
    Are you sure the people who will handle that downstream need pixel images and do you have the exact pixel dimensions needed?
    Why did you place the image back in Indesign, by the way? 

  • How do I save images from Finder to iPhoto?, How do I save images from Finder to iPhoto?

    Hi. How do I save my images from Finder into iPhoto? Every time I try nothing happens accept that the images keep dublicating themselves in Finder! On the verge of throwing the new Computer out of the window.
    I dont know why they say that mac is easy......
    Thanks

    File -> Import to Library
    Drag to the iPhoto Window
    Drag to the iPhoto icon.
    Every time I try nothing happens accept that the images keep dublicating themselves in Finder
    Where do you see this happen?

  • How do I "Save Image As"?

    In Netscape I can click (I have a standard mouse, not one with right and left clicks) on an image and get a list of choices, one in particular called "Save Image As..." When I click onto that I am able to not only save the image from the webpage but I am also able to rename the file and download it into any file of my choosing that I have on my computer. How can you do this in Safari? I have tried the 'control' 'option' and apple' keys, and all they will do is allow me to download the image onto my desktop. I then have to rename the file and then drop it into the proper file. This is a lot of hassle and work compared to Netscape. Is there a way to do this in Safari, and if not, Apple would you please incorporate that feature into a future update release for Safari? Does anyone have any ideas?
    Thanks!

    Lisa,
    Welcome to Apple Discussions.
    Control + Click on the image (release the control key, but continue to hold the mouse click) then depress the Option Key which will change the "Save Image to the Desktop" command to read "Save Image As..." and then select the Save Image As... link. You will then see the the "Save As:" field which can be expanded by clicking on the ▼ arrow. You will now be able to name the file and navigate to the desired save location.
    ;~)

  • How to display dynamic images using Struts

    I am storing the image name in bean. I want to use the <html:img> tag to display my images. How can i do that using struts.
    Something or sort..
    <html:img src=bean:write name="pageEntry" property="pageImg"/>
    Thank You

    * In your web.xml file, add the struts-html-el.tld definition from the struts\contrib\struts-el\lib directory
    * Add this tag library to your JSP page; something like:
    <%@ taglib uri="WEB-INF/struts-html-el.tld" prefix="html-el" %>* Refer to the following example:
    <html-el:img src="${pageEntry.pagePic}" />* This assumes that pageEntry is a Bean, and pagePic is a bean variable accessed by the getPagePic() method.

  • Can you guide me how to mirror an image using Photoshop CS4 ME ?

    hello guys...
    as I was surfing the InDesign forum, I just found this which is exactly like the question I was about to ask, but since I read that it's not that easy to do it with InDesign, I am sure that it's doable by Photoshop, but how ???
    any way to do it ???
    thank you very much .

    Unfortunately I'm not too good for recommending good tutorials, as I'm almost 100% self-taught (experiment, try, fail, try again, succeed, that kind of thing).
    A Google search for "create mirrored image using Photoshop" does turn up a lot of tutorial content, e.g., http://www.photoshop911.com/tricks/mirror_image.html
    With Photoshop you can do anything to an image given sufficient time and effort.
    Enjoy the journey!
    -Noel

  • How do I load images using nio?

    Beyond using the toolkit to load an image, I don't know how to load an image. I looked at the javax.imageio package briefly, but I'm not sure where to start there.
    I would like to be able to load images with nio Ii.e. memory map the files) and display them on screen.
    Any advice and help would be appreciated.
    Thanx
    Bill

    from java api 1.4
    BufferedImage bi = ImageIO.read(File)
    BufferedImage bi = ImageIO.read(InputStream)
    BufferedImage bi = ImageIO.read(ImageInputStream)
    BufferedImage bi = ImageIO.read(URL)

  • How to display an image using MIDP on Palm?

    How can I display an image using MIDP on Palm? The following code works on the Siemens SL45i, but not on Palm:
    public class Test extends List
    Image image = Image.createImage("/images/test.png");
    append("item 1", image);

    Have found the exact same problem when trying to display an image (other then the default (null)) in a list, on a Palm.
    The image displays correctly on a form, but when set on an element in the list, it does not display. (mind you this is in both emulator mode and on the real device)
    It does not seem to be related to size of the image.
    The Sun documetation states, that you should not rely on it been displayed (obviously it's an implementation issue with the Palm, and other devices I have not tried)
    But like to hear definitively from Sun though!

  • How to change the images used in the "Named people" tiles?

    After working on adding people/faces for a while, I find that in many cases the image used in the "Named people" tile for a particular person is the worst one possible.
    Is there a way to tell Lightroom to use a different image?

    Agreed. The people grid looks horrible after a while. I went looking for a way to identify a key tile and couldn't find it.

  • How can i save images in my pc without redownloading from net? windows 7 64bit + last vertion of firefox

    I do right-click on the loaded and displayed image on browser and select "Save Image As" and locate the address to save and click on save, but i see that image start to redownload and save in my pc, but why?! why redownload?! please help me to save instantly from cached data in firefox

    You can look at this extension:
    *Save Images: https://addons.mozilla.org/firefox/addon/save-images/

Maybe you are looking for

  • Printer spool issue with HP LaserJet 1018

    I seem to be having a recurring problem with the HP LaserJet 1018 that I am hoping someone has also had and can help me resolve.  When I go to print I get a message that I need to set up a printer (it does not recognize the printer is there).  When I

  • Can't figure out how to open multiple projects in imovie

    I want to copy clips from one project into another. I've read you simply open the two projects and drag clips from one to the other. I may be missing something quite basic, but I cannot figure out how to get two projects open at once. If I open from

  • Add SQL Table to SAP DB Outside of SAP?

    I can't seem to find documentation on this, is it OK to add a table to the SAP database in SQL Server? I am trying to writeback tracking numbers, which can only be done through an ODBC DSN which would require writing into a table directly - since thi

  • Approach on Cost Center for Vehicles

    Hi Experts, I have a requirement to analyze the cost and profit of the vehicles internally. These vehicles can be assigned from one plant to another every month. Right now the setup for cost centers is grouped by the company site only. What is the be

  • How to set NTFS and share permissions for Users share for home directories in Server 2012

    I have a new Server 2012 server, and I want to set up a Users share, that will contain subfolders of each user's username and contain their home directory.  But what do I set the share and NTFS permissions as on the root level, lets call the folder U