How to batch process textures with xBR filter?

Rebirth Gaming

New Member
Jul 29, 2019
360
0
0
Ok, first, some background.

I'm trying to create a resource pack for my Tradewinds modpack. This resource pack is straight forward - x32 versions of every texture of every mod in my modpack. Sounds tedious, I know, but I found an easier way to do this.

I learned about a filter that's used in game emulation communities that uses an algorithm to upscale 8/16/32 bit textures.

One of these filters is called xBR. I quite like the results it gives, and it can upscale 16x16 textures to 32x32 quite nicely without making them blurry or too jagged.

Here's a couple examples: (Left is original x16, right is upscaled to x32 using this algorithm)

nO5Jksr.png


CeyjVKI.png


Here's the problem. These algorithms exist solely as, well, stuff used for emulators and such, and not really for processing image files like PNGs.

I did come across one program however called ImageResizer, which lets me open an image, set the algorithm (xBR in this case), upscale, then save. And I must do this for every single image... there's potentially hundreds or thousands of image files between all of the mods in my modpack... so you can see that this is not a viable option.

I tried searching around to see if this software had some extended functionality for batch processing, but the only thing I found is that it has the ability to load a script. So, I can script the functions of the software.... but that means I have to manually type in each and every file name (for both input and output).

Is there a way to perhaps automate the process of creating a script file so I can batch process texture images through this software?

What would be even more ideal is if a Photoshop plugin existed using the open sourced code for this xBR algorithm, since I'm quite familiar with PS and its droplet/batch process/macro function. Googling around has led me either to results and forum posts that don't deal with my unique needs here, or lead to outdated and broken links...

Hoping someone who's a guru with batch processing, macroing, etc that can perhaps lend me a hand to make this process a matter of just batch processing all texture files I extract from individual jars.