Open all tiffs in a folder and/or subfolders and compress

Upload Photoshop Scripts, download Photoshop Scripts, Discussion and Support of Photoshop Scripts

Moderators: Tom, Kukurykus

garek007

Open all tiffs in a folder and/or subfolders and compress

Post by garek007 »

Run this script:

Pick a top folder or a folder containing images. If you have many folders this will go through each one opening only tiffs and recompressing them with LZW compression. It overwrites the original. If you only have one folder it will do it just for that one folder.

If you get inside the sript at the top there are 3 variables. You can change these so that it opens tiffs saves as pdf or jpeg; opens jpegs and saves as pdf or tif, any combination you want.

There is one problem though; opening pdf that are not raster. I do not have open options in this script. I may get around to adding them someday. What this means is that the script will stop on a vector pdf and ask at what resolution to open.

Finally, this script is probably pointless because although I've never checked out Dr Brown's image processor I assume it does this and more. I'm sure Andrew and/or X have also beat me to the punch also. But here it is anyway, if nothing more than from a simpler mind for newbies.

EDIT: Almost forgot. Thanks to Andrew Hall for the function ScanSubFolders() without which this would not be possible.

Professional AI Audio Generation within Adobe Premiere Pro - Download Free Plugin here

scottg

Open all tiffs in a folder and/or subfolders and compress

Post by scottg »

hi garek007,

first off, thanks for this useful script, this will save me some disk space and i have a lot of images to recompress.

one issue however - when i choose my top-level folder, the script runs, but only seems to work on the images in subfolders... the actual top level directory that i chose when the dialog box popped up didn't appear to be affected.

i script for after effects, but this is my first instance of using scripts for pshop, so i'm learning all the new keywords and functions specific to photoshop - meaning that while i understand your code, i'm not sure why it's not working on my top-level directory.

does anyone have any suggestions?
thanks,
scott.
scottg

Open all tiffs in a folder and/or subfolders and compress

Post by scottg »

hi garek007,

first off, thanks for this useful script, this will save me some disk space and i have a lot of images to recompress.

one issue however - when i choose my top-level folder, the script runs, but only seems to work on the images in subfolders... the actual top level directory that i chose when the dialog box popped up didn't appear to be affected.

i script for after effects, but this is my first instance of using scripts for pshop, so i'm learning all the new keywords and functions specific to photoshop - meaning that while i understand your code, i'm not sure why it's not working on my top-level directory.

does anyone have any suggestions?
thanks,
scott.
garek007

Open all tiffs in a folder and/or subfolders and compress

Post by garek007 »

scott,

I'm glad to see someone get some use out of this script. email me direct and I'll try to work with you to get that working if you still need it. I was aware of it but at the time did not need that functionality. I knew it was something I'd want to add eventually.

Stan
stan_alach AT hotmail DOT com
scottg

Open all tiffs in a folder and/or subfolders and compress

Post by scottg »

Hey Stan,

I emailed you about this script, but never got a response. Just wondering if it ever came through, sometimes my mail plays up. I may possibly have also called you Steve for some bizarre reason, but I think it's unlikely.


Thanks,
Scott.
garek007

Open all tiffs in a folder and/or subfolders and compress

Post by garek007 »

Scott,

I did email you. I said to send me your latest version and let me know what you need, I'll build it right into that. That way I get the advantage of whatever you've added and you don't have to work any changes I make into your script. Email it to me or post it here.

Stan