Posted: Wed Jan 05, 2022 1:56 am Post subject:
Resizing RA2 shp files to TS
Subject description: 3 tools used to keep the quality
I want to share how i've resized some ra2 shp files smaller, keeping the quality pretty good as opposed to SHP builder's resizer makes things a bit pixely. Tools i used are easy and free. For the tutorial i'll be using the Nod conyard's buildup animation from the RA2 Mod 'Reign Of Steel' this method takes just a few extra steps but its worth it, so here's how to do it:
Exporting frames: there are multiple ways to export frames. I prefer shp builder (1) and XCC Mixer (2). XCC mixer can export frames for multiple shp files at the same time
(1)First, load the SHP you want to convert in SHP Builder. Make sure you have set the right palette (ctrl+p), then export the frames:
Click on File > Export > SHP -> Images
Choose an empty folder to save the frames in. Type the filename, and make sure to save as PNG
(2) Using XCC Mixer to export frames.
Open xcc mixer, browse to your shp file(s) in the left column and set the right palette (ctrl+p). In the middle column, browse to an empty folder. Select the shp files you want in the left column. (You can select multiple files holding ctrl or shift or shift+ctrl).
Make sure only SHP files are selected and right click > export to PNG.
All frames will now be exported in the empty folder
Replacing background to transparency:
Use a batch image tool to replace the background to transparency. The easiest one i enountered is Imbatch: Download ImBatch (click here )
Load all frames (drag & drop or load)
Add task: 'Replace colors' then click on it:
You can leave Original Color to 'color'
Click the little icon next to 'Fill color' and pick the background color, Make sure the background color (blue, black or pink) is selected and press OK
Now under New Color, we select Transparency. Start of transparency has to be 0, and the end of transparency 255
Press Run batch, and it will quickly remove the background from all the frames.
Under Resize, pick Percentage and pick 80% (ra2 to ts size)
Click Process Batch. (it will process them superquick, even if you have 10.000 frames) Then Download all. A zip file will be downloaded with all your resized frames
(I use Redketchup.io for resizing because it keeps excellent quality, but you can also batch resize with gimp and photoshop, they process them a bit slower. Irfanview does an excellent job on resampling too, here is a tutorial: https://www.ofzenandcomputing.com/batch-resize-images-irfanview/ If you can find out how to replace background color to transparency with irfanview at the same batch process, please let me know )
Import frames to SHP
Extract your frames in a new folder.
In SHP Builder, press File > Import> Image -> SHP
hit Browse and pick the first frame (it should still have 0000 in its name)
Hit OK.
Click on View > Preview, and pick a color to make sure the remap looks fine.
Fix remap if needed
If the remap is not ok, some reds have turned into non-remap red. You can apply this color scheme to turn all the reds into remap reds: redtoremappa.cscheme. (see attached file)
To Install a color scheme: drop the redtoremappa.cscheme in the SHPBuilder directory: \cscheme\Custom (For example: C:\Program Files (x86)\CnCTools\OS SHP Builder\cscheme).
Then click Colour schemes > Update colour scheme list, and now you can go to Custom Schemes > Red > Red to remap harder 2x
Fix shadows if needed: press alt+i (turn on shadows first in Options)
Save, and that should be it!
A Question i get many times with my finalsun tutorials, is how i get the black theme for the windows? Its just a windows 10 theme, its called Dark eve, here is the download: https://github.com/nitschis/GreyEveTheme
My recommended method is to use XCC Mixer to convert the SHP into PCX files, resize them in Photoshop (you can make an action script to batch edit them) & then again use XCC Mixer to convert the PCX files back to SHP. _________________
Thanks Mig Eater. I forgot to mention XCC mixer. I updated tutorial. Xcc mixer also allows to export multiple shps at the same time.
Photoshop does a good job indeed, but i see no difference between photoshop and redketchup resize quality. Photoshop took 20 minuts for me for 900 frames, redketchup 10 seconds lol. Also you gotta remove the background first before resizing or the background color will blend with the edges of the image. I havnt found a way in photoshop's actions to do that for bulk process. QUICK_EDIT
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum