1 @echo off & setlocal enableextensions enabledelayedexpansion
\r
2 :: ============================================================
\r
3 :: This script compresses all .png images.
\r
5 :: By default all images in all languages will be handled.
\r
6 :: You can specify a group of files to check using the first
\r
8 :: adjustimages en\Rev*.png
\r
10 :: ============================================================
\r
13 if '%1' == '' goto :DoDefault
\r
14 for %%? in (%1) do Call :ProcAdjustFile %%?
\r
18 for %%? in (en\*.png) do Call :ProcAdjustFile %%?
\r
19 endlocal & goto :EOF
\r
20 ::===============================================================
\r
21 :ProcAdjustFile FileName
\r
24 type %1 | pngquant.exe 256 > 8bit.tmp
\r
26 move 8bit.tmp %1 >nul
\r
27 optipng.exe -o7 -quiet %1
\r
28 pngout.exe %1 /y /d0 /s0 /mincodes0 >nul
\r
30 endlocal & goto :EOF
\r