I have a folders containing EPS of Illustrator and of Photoshop and TIFF. I want to onvert all these EPS and tiff in JPG format.
For example:
Illustrator EPS should be open in Illustrator and save it to JPG at the same location.
Photoshop EPS should be open in Photoshop and save it to JPG at the same location.
TIFF could be open in any application and save it to JPG.
use the creator type in the file to check if it is an illustrator file or photoshop and open in the appropriate app. Export from illustrator and save as out of photoshop.
Some things to consider when dealing with Photoshop TIFFs if you don’t want to have the script interrupted by Save dialog boxes (in CS1, don’t know about CS2, though I’d suspect it’d be the same): JPEGs can’t have extra channels or layers. So you’ll have to delete the extra channels and flatten the image before saving to JPEG. Below is a handler that will prep the passed document for JPEG export. You can pass it a string representing the document name, a number representing the document index, or a document reference.
on prepJPEGExport(targetDocument)
-- targetDocument can be number or string or document reference, i.e. 1 or "test.tif" or document 1
tell application "Adobe Photoshop CS"
if class of targetDocument is string or class of targetDocument is integer then set targetDocument to document targetDocument
tell document 1
-- JPEG can't have more than component channels, so delete them
set ch to channels
set c to component channels
-- have to compare channels names
set componentChannels to {}
repeat with thisC in c
copy name of thisC to end of componentChannels
end repeat
repeat with thisChannel in reverse of ch
if (name of thisChannel) as text is not in componentChannels then delete thisChannel
end repeat
-- JPEG can't contain art layers so flatten
if (count of art layers) > 1 or (count of layer sets) > 0 or ((count of art layers) is 1 and not background layer of layer 1) then flatten
-- JPEG can contain paths, though
end tell
end tell
end prepJPEGExport
Edit: added check for layer sets and a single art layer that isn’t the background layer to the flatten line.
you can applescript this if you want, but i use dropjpeg.
DropJPG is a simple program that converts images dropped on its icon into jpg. DropJPG is compatible with all Quicktime readable images, including PDF screenshots.