PhotoShop Batch Resizer

Want hints or tips about creating textures or other resources? This is the place for you.
Post Reply 
User avatar
BDcraft Web Admin
6590 Posts
 x 430

Post 28 Oct 2015, 19:30

PhotoShop Batch Resizer

This is how we at BDcraft resize textures (well, Sphax doesn't use this precisely, he has his own magical setup...). We do it this general way to preserve certain features (like strokes, and shadows/glows).

It requires PhotoShop (probably at least CS2).

Hopefully this should all work and be set up correctly. I did test it, but you never know. :P
Be aware if you have any rasterized layers in your PSD they will look like crap if you use this script as PhotoShop jpegs any rasterized layers when resizing. Also any jagged lines (i.e. if you don't use choke or are using precise over softer) will get very jaggedy as they get smaller.

Also this isn't written very clearly or set out very well :D

Unpack the zip somewhere sensible on your computer. Somewhat out of the way, but easily accessible:
As PhotoShop actions aren't easily editable and they use absolute paths you'll need to map a folder to a drive letter. This is a Windows feature and can actually be done via the command line but VSubst is easier.

  1. In the folder you created and unpacked the zip to open the VSubst folder and run the exe.
  2. At the bottom of the window that opens click the magnifying glass and locate the folder you unpacked the zip to. In the dropdown box to the left select "O:\".
  3. Then click the green plus to add the drive.
  4. Make sure the checkbox for "Apply virtual drives on Windows startup" is checked.
Show Example of VSubst
Image


Next double click the ExportPNG.atn file. It should open PhotoShop and load the action. If it doesn't you'll need to open PhotoShop and press Alt+F9 to open the actions window and then load the action from the top right dropdown menu.
If loaded correctly you should see an "ExportPNG" group in the actions window.

The 8bit NoAA actions are for things that shouldn't have messy pixels around them (like items). As semi-transparent pixels around items will cause visual effects.

The 24bit AA actions are for things that should have transparency (like stained glass) or require more than 256 colours (few BDcraft textures should be that busy though -- it's usually gradients/shadows that bump up colour numbers and you should try to avoid those).

The "All" action will process the PSD in the separate % sizes that are also listed. So if you select a 512x PSD it'll resize it to every resolution. However, if the PSD is 128x, you'll end up going all the way down to a 2x texture ;)

  1. In order to process more than one PSD at a time I recommend you copy whichever PSDs you want to process in to the !input folder.
  2. Then in PhotoShop open the File menu > Automate > Batch.
  3. In the "Play" section select ExportPNG from the Set list and then from the Action list select the relevant action.
  4. For Source choose Folder and select the !input folder. You can include subfolders if you want, but PhotoShop won't place files it finds in subfolders in the same output subfolders. It'll just lump them all together.
  5. Check "Suppress Color Profile Warnings" and in the "Errors" dropdown select "Stop for Errors".
  6. The "Destination" should be set to None as the actions place the files in the specific folders.
  7. Click OK and watch PhotoShop grind along as it resizes the PSDs and exports them as PNGs.
Show Example of Batch Window
Image


The exported PNGs will be in the relative resolution folders depending on the action you chose (i.e. if you selected the 25% action the output is in the 128x folder -- confusing? Yes, but meh).

Next just move all the PNGs to the correct place in the pack.
Profile pic by TsaoShin: https://www.deviantart.com/tsaoshin
If you like our work please consider becoming a Supporter and get an ad-free experience.
User avatar
BDcraft Web Admin
6590 Posts
 x 430

Post 23 Feb 2019, 02:33

This is a thread that's been hidden in the staff section since... well... 2015. Not sure why I never made it public earlier. It's nothing special, but may be helpful to some people.
Profile pic by TsaoShin: https://www.deviantart.com/tsaoshin
User avatar
29 Posts
 x 5

Post 06 May 2019, 19:28

HanFox wrote:
28 Oct 2015, 19:30

The 8bit NoAA actions are for things that shouldn't have messy pixels or any transparency at all. The 24bit AA actions are for things that should have transparency (or require more than 256 colours).
Are you refering to this about resizing image with photoshop, about interpolation?
lets say i have 512x texture, then want resizing to 256x. photoshop set default to bibucic automatic.

putting some test with photoshop, the different is noticeable after resizing, but idk how much it affect the game later
Image

so which way the best for resizing 8bit NoAA & 24bit with AA while i still working the new texture layer by layer, before finalizing the work. thanks
User avatar
BDcraft Web Admin
6590 Posts
 x 430

Post 07 May 2019, 08:00

botaxalim wrote:
06 May 2019, 19:28
...
8bit is for things like items or fully transparent blocks (like glass in vanilla) that don't want any pixels around their edges. Semi-transparent pixels around textures like those will cause weird visual effects.

24bit is for things like stained glass that require semi-transparency. It can also be used for overly busy files that have over 256 colours in them, but then you'd have to be careful about edges going fuzzy yourself.

You generally shouldn't be using the actions whilst still working on the files. They're really just for the final pass.
Profile pic by TsaoShin: https://www.deviantart.com/tsaoshin
User avatar
29 Posts
 x 5

Post 08 May 2019, 05:10

got your point, after tinkering with PNG 8 bit & PNG 24 bit mode about resizing (Save for Web....) in photoshop
Post Reply