I have a file that converts all photos to the "Compressed" folder. Tell me, please, how can I add a command to this file so that all the photos are converted to webp?
Code: Select all
echo Compress all JPG in a Directory:
echo %Source%
if not exist Compressed mkdir Compressed
for %%i in (*.jpg) do (
convert ^
-quality 88 ^
-filter Lanczos ^
-sampling-factor 4:4:4 ^
-define jpeg:dct-method=float ^
-thumbnail 4100x ^
"%%i" ".\Compressed\%%~ni-JPG.jpg"
echo JPG done!
)