15. Automating Your Work with Actions


What You’ll Do

Examine the Actions Palette

Build a New Action

Record an Action

Add a Stop to an Action

Control the Playback of a Command

Add a Command to an Action

Delete a Command from an Action

Work with Modal Controls in an Action

Change the Order of Commands in an Action

Copy an Action

Run an Action Inside an Action

Save Actions into Sets

Save Actions as Files

Move and Copy Actions Between Sets

Insert a Non-Recordable Command into an Action

Use Enhanced Scripting

Enhance the Process with Droplets

Use a Droplet


Introduction

Actions are only one of the Adobe Photoshop Automate commands; however, they’re so important to consistency and efficiency, they deserve their own chapter. Actions are Photoshop’s way of relieving you of the mind-numbing task of repeating an operation over and over again. For example, you’re recovering 55 images from your digital camera, and each image needs to be converted into a specific size and resolution. Instead of repeating the conversion process 55 times, you perform the conversion process once, and save it as a repeatable action.

Actions are similar to recording information on a tape; they record Photoshop commands and, like a tape recorder, can be played back at any time. Actions can be applied to any number of images. You can modify existing actions, and save them into a user-defined set. It’s even possible to save them and send them to any other Photoshop user. Actions have been a part of Photoshop since version 5, and each evolution of the Actions palette has seen new features and abilities. In Photoshop, it’s now possible to create an action out of almost any command, filter, or adjustment; including blending mode operations to layers. This chapter is dedicated to the masses of Photoshop users who are tired of doing something over and over again. If you have ever considered using actions as a part of your design workflow, then you’re in for a wonderful journey of discovery.

You can also enhance your actions by creating a droplet. A droplet is an action that appears as a file on your hard drive. For example, you could create a droplet that performs a generic color correction operation. To perform the operation on a Photoshop document, you would not have to open Photoshop; you would simply drag the image file over the droplet, and release—the droplet does the rest.

Examining the Actions Palette

PS 10.1

image

The Actions palette is where you create, save, modify, and store all of your actions. The analogy of a tape recorder is used often in discussions of the Actions palette, but besides the overuse of the term, it’s actually a good way to view actions. The action itself is a tape, and the Actions palette is the tape recorder. When you begin an action, the palette records each step in the process, saves them, and then lets you play them back on another image. In order to record and play actions, you need to understand how to use the Actions palette.

Examine the Actions Palette

image Select the Actions palette.

image Check the toggle box to toggle an action on or off.

image Click the dialog box to toggle the dialog function on or off.

image Click the expand triangle to expand or contract an action or set.

image Click the Actions Options button to access all of the Actions palette options.

image


Did You Know?

You can use the Window menu to display the Actions palette. Click the Window menu, and then click Actions.


image The following buttons are accessible at the bottom of the Actions palette, from left to right:

  • Stop. Click to stop recording and save an action.
  • Record. Click to begin recording an action.
  • Play. Click to begin execution of the selected action.
  • Create New Set. Creates a new action set.

Sets are like file folders; they store individual actions.

  • Create New Action. Starts the process of creating a new action.
  • Delete. Click to delete the selected action or set.

image

image


Did You Know?

You can convert your Actions into single-click buttons. Click the Actions Options button, and then click Button Mode. When the Actions palette is in Button Mode, you cannot access or edit the steps in the individual actions. To access the standard Actions palette, click the Actions Options button, and click Button Mode to uncheck the option.


Building a New Action

PS 10.1

image

Building an action is almost as simple as clicking the record button on a tape recorder. Actions are simply a series of program instructions. When you build an action, you’re instructing Photoshop what to name the file, where to store it, and what functions keys, if any, will be used to activate the action. Since an action is simply a record of the work performed on an image, it’s a good idea to plan out what you intend to do, and then build the action. Remember actions are tasks you plan to do repeatedly. It wouldn’t make sense to create an action for a one-time use.

Build a New Action

image Open a document.

image Select the Actions palette.

image Click the Create New Action button.

image

image Enter a name for the action in the Name box.

image Click the Set list arrow, and then select what set to save the Action.

image Click the Function Key list arrow, and then click F1 - F12 to assign your new action to a function key.

image Select the Shift or Command check boxes to require the pressing of the Shift key, or the Ctrl (Win) or image (Mac) key in conjunction with the function key.

For example, F1, or Shift+F1, or Ctrl+F1, or Shift+Ctrl+F1.

image Click the Color list arrow, and then select from the available colors.

image Click Record to begin creating the action.

image

Important

If you choose a color for the action, they will only be available if the actions are viewed in Button Mode.

Recording an Action

PS 10.1

image

Once you’ve set up, or built the action, it’s a simple matter of clicking the Record button and performing a pre-determined set of commands to the image. Photoshop watches you like a hawk; faithfully recording each step in the process. Once complete, Photoshop stores the file in the Actions palette, where it’s ready when needed. When you end the action, Photoshop stores the program instructions in a file, and displays all the files, by name, in the Actions palette. Then it’s a simple matter of clicking the Play button to apply the instructions to another document.

Record an Action

image Open a document.

image Select the Actions palette.

image

image Specify the action settings.

image Click Record.

image

image Edit the image. Each time you perform an edit, such as filters, adjustments, or commands, the operation is listed as a step in the Actions palette.

Important

The Actions palette doesn’t record the speed you perform a command, only you performed it. So take your time, and work carefully through the process. Creating an action right the first time, save editing hassles later.

image Click the Stop button on the Actions palette.

The action is saved and listed in the current Action Set.

image

Adding a Stop to an Action

PS 10.1

image

There are times when you want to make changes, based on a specific image. For example, you create an action to balance the contrast in an image, and one of the commands you use is the Levels adjustment. Although all of the other commands do not need modification, the Levels adjustment is specific to each individual image. What you want is the action to perform (automatically) all of the action steps, except Levels. For the Levels adjustment, you want the action to stop, and let you make changes, and then after you click the OK button, to move on and complete the rest of the steps.

Add a Stop to an Action

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to modify.

image Click the command directly above where you want to place the action.

image Click the Actions Options button, and then click Insert Stop.

image Enter a text message associated with the purpose of the stop action.

image Select the Allow Continue check box to add a Continue button to the stop alert box.

image Click OK.

image

image Click the Play button on the Actions palette to run the action.

image

Controlling the Playback of a Command

PS 10.1

image

Not all actions are created perfect. Sooner or later, you’ll work through the process of action building only to find out (after the action is saved), you forgot a step, or need to remove or modify an existing step. You might even need to change the order of the commands in the action. Fortunately, Photoshop doesn’t make you recreate the action; all you have to do is modify it. When you create an action, all of the commands execute in the order they appear in the command list. However, it’s possible you might occasionally want to skip one of the commands in the list, without permanently deleting it.

Control the Playback of a Command

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to modify.

image Uncheck the command or commands you do not want to execute.

image Click the Play button on the Actions palette to run the action without executing the unchecked command.

image

image

image Recheck the command to return it to executable status.


See Also

See “Working with Batch File Processing” on page 398 for information on applying an action to multiple files at once.


Adding a Command to an Action

PS 10.1

image

Actions are very versatile; in fact almost anything that can be done to an image can be placed into an action. You might find that as you perform an action, you need to add an additional command. You can do this with ease, that’s why actions are so great to work with. For example, you might create an action to convert an image from the RGB to the CMYK mode, and after you save the action; you decide it would be great to include a Curves adjustment. You don’t have to throw away the old action and start all over, all you have to do is select where the command will be inserted, restart the action and perform the new step. The Actions palette is a powerful time-saving tool, and if you forget a step, it’s also a breeze to modify.

Add a Command to an Action

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to add the command.

image Click the command directly above where you want to insert the new command.

image Click the Actions Options button, and then click Start Recording.

image

image Add the additional command by selecting the filter, adjustment, or any other Photoshop option.

image When you’re finished adding commands, click the Stop button on the Actions palette.

The next time the action is run, the additional command will be performed.

image

Deleting a Command from an Action

PS 10.1

image

Occasionally, you may want to permanently delete a command from an existing action. If that’s the case, Photoshop makes the process quick and easy. An action consists of a group of steps. As the action executes, each step is completed in the order that they appear within the action list. No one step is dependent upon another, so if the case arises you want to remove a step, it’s a simple process of deletion. Once the command is removed the action will perform as if the deleted command never existed.

Delete a Command from an Action

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to delete the command.

Important

You cannot delete a command from a running action.

image Click the command you want to delete.

image

image Select from three deletion methods:

  • Drag the command over the Delete button.
  • Click the command, click the Delete button, and then click OK in the Delete This Selection alert box.
  • Click the command, and then hold down the Alt (Win) or Option (Mac) key, and then click the Delete button to delete the command without the alert box message.

image

Working with Modal Controls in an Action

PS 10.1

image

Modal controls are pauses in an action; which allow you to modify a command before proceeding with the action. Modal controls are available for every Photoshop command that utilizes a dialog box, or any command that requires the pressing of the Enter/Return key to process the effect. For example, you create an action that utilizes a Levels and Curves adjustment, and you want the option to control the Levels adjustment each time the action is run.

Work with Modal Controls

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to modify.

image Click the second column from the left to activate the Modal Control button.

image Click an existing modal control button to deactivate the control.

image Click the Play button on the Actions palette to run the action.

The action stops and lets you control the command.

image

image Adjust the image using the Exposure dialog box.

image Click OK to continue the action.

image

Changing the Order of Commands in an Action

PS 10.1

image

When an action runs, it performs each command in the order that they appear in the action list. Since the order a filter or adjustment is applied to an image determine the final document, it’s important to be able to adjust the order that the commands are executed. For example, if you create an action that contains a Curves adjustment followed by a Gaussian Blur filter, and you move the Gaussian Blur filter above the Curves adjustment, it will totally change the look of the final image. Since the order of execution is important to the outcome of the image, the Actions palette gives you the ability to change the order in which commands are executed.

Change the Order of Commands

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to change.

image Drag the command you want to change up or down in the action stack.

image

image Release the mouse when you see a dark line underneath the command you want the dragged one to be placed.

image


Did You Know?

You can choose the speed at which an action executes when you’re playing it. Click the Actions Options button, and then click Playback Options. Click Accelerated, Step By Step, or Pause for a predetermined number of seconds. You can even have it pause for any audio annotations. Clicking a slower speed lets you view each step, and is useful when performing editing on an action.


Copying an Action

PS 10.1

image

What if you need to create an action with several commands, and you need another similar action; possibly one action that performs several commands and ends with the Curves adjustment. And then another action that performs the same commands and ends with the Levels adjustment. If that’s the case, there is no need to reinvent the wheel, just create the first action, make a copy, and then modify the copy.

Copy an Action

image Open a document, and then select the Actions Palette.

image Click the expand triangle of the action you want to change.

image

image Select how you want to duplicate the action:

  • Drag the action over the Create New Action button on the Actions palette.
  • Select the action, click the Actions Options button, and then click Duplicate.

image

Running an Action Inside an Action

PS 10.1

image

You can make an action run within another action, thus reducing action complexity. For example, you could create an action that performs a dozen or more commands (it’s not unusual), or you could create two simpler actions, and have one action load and run the other action. That way, when it comes time to modify the action, you have a smaller list of commands to deal with. You can also call actions from more than one source, giving you the ability to create small action codes that can be used over and over again.

Run an Action Inside an Action

image Open a document, and then select the Actions palette.

image Click the expand triangle of the action you want to modify.

image Click the command directly above where you want to insert the run step for the other action.

image Click the Record button.

image Click the action to be added.

image Click the Play button to record the second action into the first action.

image Click the Stop button.

The second action is recorded inside the first action.

image

Important

When you click the Play button, the action executes on the active document, so you might want to perform this on a duplicate image.

Saving Actions into Sets

PS 10.1

image

Once you discover the advantage to using actions, you’ll be creating actions for all those dull, boring repetitive tasks, and life inside Photoshop will never be the same again. As the days go on, you’ll see your list of actions growing longer and longer. Sooner or later (probably sooner), you’ll develop so many actions that scrolling down the Actions palette to find you favorite actions becomes a job in itself. The Actions palette has the ability to hold as many actions as you need, and it also gives you the ability to organize those actions into sets. Action sets are like file folders; they hold groups of actions. For example, you might have a group of actions that perform image restoration, and another group for color correction. Using the Actions palette, you can create two sets, one for each kind. Once a set is created, it can be removed from the Actions palette, and reloaded when needed. Action sets can also be distributed to other users.

Save Actions into Sets

image Open a document, and then select the Actions palette.

image Click the Create New Set button.

image Enter a name for the new set.

image Click OK.

The new set is added to the Actions palette.

image

image

Saving Actions as Files

PS 10.1

image

When you create a new set of actions, Photoshop displays the actions in the Actions palette, but the actions are not permanently saved to the hard drive. That means if you delete an unsaved action or action set, they will be gone forever. To stop that from happening, you need to save the sets. Not only does this give you the ability to save your precious actions, it lets you share you actions with other Photoshop users. For example, you have a friend that’s having trouble performing color correction to an image. The problem is she lives 800 miles away. So you create an action that performs color correction, save the action as a file, and e-mail her the file. Now, all she has to do is click the Actions Options button, and then click Load Actions. She now has the action to color correct her images.

Save Actions as Files

image Select the Actions palette.

image Click the set you want to save.

image Click the Actions Options button, and then click Save Actions.

image

image Enter a name for the action set.

The default name will be the original name of the set.

image Click the Where (Mac) or Save In (Win) list arrow, and then click where to save the set.

image Click Save.

image


Did You Know?

You can access your new Action Set directly from the Actions dialog box. If you save the new action set in the Photoshop Actions folder, the actions appears at the bottom of the Actions Options dialog box.


Moving and Copying Actions Between Sets

PS 10.1

image

Once you’ve created an action set, it’s a simple matter to organize all of your timesaving actions. Think of an action set as a file drawer. When you need a specific action, you expand the set, and then locate the proper action. You might want to create sets with names such as Color Correction or Special Effects, for easier retrieval. Then you can create new or move existing actions into your organized sets. Once the perfect action set is created it can be saved, and even e-mailed to other Photoshop users.

Move and Copy Actions Between Sets

image Select the Actions palette.

image Click a pre-existing set, and then click the expand triangle to open the set.

image Use the following move or copy method:

  • To move an action, drag the action from one set
  • To copy an action, hold down the Alt (Win) or Option (Mac) key, and then drag the action from one set.

image Release when your mouse hovers over another set.

image

Inserting a Non-Recordable Command into an Action

PS 10.1

image

When you create an action, you cannot record mouse movements, such as a brush stroke, or any of the view, and window commands. However, you can insert many non-recordable commands into an action using an Insert Menu Item command. The Insert Menu Item command can be used when recording an action or after it has been recorded. Inserted commands do not execute until the action is played, so the file remains unchanged when the command is inserted. This gives you the ability to experiment with different non-recordable commands without the possibility of damaging a valuable image.

Insert a Non-Recordable Command into an Action

image Select the Actions palette.

image

image Click an action, and click the expand triangle.

image Click the name of the action to insert the item at the end of the action, or click an action step to insert the item after the selected step.

image Click the Actions Options button, and then click Insert Menu Item.

image

image Select a command from the available options (the command is selected by clicking and selecting an item from Photoshop’s drop-down menu system).

image Click OK.

The non-recordable command is added to the action steps.

image

Important

When you use the Insert Menu Item command for a command that opens a dialog box, you cannot disable the modal control in the Actions palette.

Using Enhanced Scripting

PS 10.4

image

A script is a series of commands that instructs Photoshop to perform a set of specified actions or commands. These actions can be as simple as affecting only a single object or more complex, affecting many objects. The actions can call Photoshop alone or invoke other applications such as Adobe Illustrator. Scripts are useful for repetitive tasks and can be used as a creative tool to streamline tasks that are time consuming and boring. For example, you could write a script to access your digital camera. It could then process the images, create and save the documents in a folder that automatically includes the current date in the folder name, like Nikon 5700-12.12.2005. A scripting language lets you ask a question (an event), and use the answer to that question to perform any commands (an action) that are available in Photoshop. To create your own scripts you need a working knowledge of scripting languages such as JavaScript, and either a script-editing application or simply a text editor, such as NotePad (Win), TextEdit (Mac) BBEdit or even MS Word. The languages you can use to perform scripting are varied and include Visual Basic, AppleScript, and JavaScript, to name a few. As a matter of fact, the Scripts Events Manage lets you set JavaScript, and Photoshop Actions to run automatically when a specified Photoshop event occurs.

Use Enhanced Scripting

image Open a text editor, and then create the script using any approved scripting language.

image

image Save the document with the correct extension. For example, ActiveLayer.js for JavaScript.

image To access the script in Photoshop, click the File menu, point to Scripts, and then click Browse.

image Click the From (Mac) or Look In (Win) list arrow, and then select your script editor file.

image Click the script in which you want to run.

image Click Load to run the script.

Your script appears in a browse window.

image


See Also

For more information on Enhanced Scripting, open the Photoshop applications folder, and then navigate to the Scripting Guide folder for access to several PDF tutorial files, and sample scripts.



For Your Information: Using Built-in Scripts

You can save time by automating repeated tasks, such as outputting your layers to files or saving Layer Comps as separate pages of an Adobe PDF file using user-defined or Photoshop’s enhanced built-in scripts. Click the File menu, point to Scripts, and then select from the available option presets. For more information on how to write your own scripts, see the documentation available in your Adobe Photoshop CS3/Scripting Guide folder.


Enhancing the Process with Droplets

PS 10.2

image

When you apply an action to an image, you open Photoshop, open the document, open the Actions palette, select the action, and then click the Play button. While that process is easier than having to redo all the steps in a complicated action, there is simpler way, create a droplet. Droplets are Photoshop Actions that appear as a file on your hard drive, or organized within a folder. For example, you could create a droplet that performs a generic color correction operation. To perform the operation on a Photoshop document, you would not have to open Photoshop; simply drag the image file over the droplet, and release—the droplet does the rest.

Create a Droplet

image Click the File menu, point to Automate, and then click Create Droplet.

Important

Droplets are created from existing actions.

image Click Choose, and then select a location to store the droplet.

image Click the Set list arrow, and then select from the available sets.

image Click the Action list arrow, and then select the action you want to convert into a droplet.

image Select from the available Play options (see table).

image


image


image Click the Destination list arrow, and then select from the following options:

  • None. The file remains open after the droplet ends.
  • Save And Close. The file is resaved (loss of original).
  • Folder. The file is saved in a new folder (user selected), with the option of renaming the file and extension.

image Select from the following File Naming options:

  • Document Name. Use the original name of the document, or click to choose from the naming schemes; including incrementing the files by number (001, 002, etc).
  • Extension. Use the original extension of the document, or click to choose from the extension options, such as using the date or sequenced serial number.
  • Starting Serial Number. If you select to use a serial number, you can select a starting value for the sequence.
  • Compatibility. Select the check boxes you want between Windows, Mac OS, or Unix.

image To create an error log file, click the Errors list arrow, and then click Log Errors To File.

The error log records any problems associated with applying the droplet to the image file.

image To specify an error log file name and location, click Save As.

image Click OK.

image

image

Using a Droplet

PS 10.2

image

Once you’ve created a droplet, it’s a simple matter of streamlining your workload. For example, you’ve created a droplet that converts an image into the grayscale color mode, and lowers the image to a monitor resolution of 72ppi. To convert an image file, just drag and drop. Droplets are files that hold the action instructions. Once a droplet is created, you can store them anywhere you can store a file. It’s not a bad idea to create file folders that hold specific types of droplets, such as color correction droplets, or image enhancement droplets. To use a droplet, it’s as easy as clicking an image file, dragging, and then dropping it over the droplet.

Use a Droplet

image Open the folder that contains your droplets.

image

image Open the folder that contains the image file, or files you need to convert.

image Drag an image file directly over the droplet, and then release.

Photoshop automatically opens and performs the selected droplet.

image


Did You Know?

You can use droplets with more than one file. To use a droplet on more than one image file, hold down the Shift key, select all the image files you want to apply the single droplet, and then drag over the droplet. Photoshop performs the droplet on all selected files.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset