Author Topic: png2dds script  (Read 222 times)


  • No life
  • *
  • Posts: 1561
  • Karma: 34
  • Dark Lord of the Savegame
    • View Profile
    • Blackchocobo
png2dds script
« on: 2020-05-15 03:06:57 »
Hey all. I wrote this little script for users on linux or mac os who want to convert png2dds files.

1. Install imagemagick from your package manager
2. Save this a
Code: [Select]
for D in `find . -type d`
    for file in "$D"/*.png
        if [ "$file" != "./*.png" ]; then
            convert $file "$(echo $D | cut -c3-)/$(basename "$file" .png).dds"
run with it will convert every png file from this folder recursively into a dds file with the same name in the same path as the png file.

To remove png files after the script is done
Code: [Select]
find . -name *.png -delete


  • Insane poster
  • *
  • Posts: 497
  • Karma: 71
    • View Profile
    • My softs (french only)
Re: png2dds script
« Reply #1 on: 2020-05-15 05:57:11 »
DDs is a contairer with can use several compression m├ęthods.
ATM imagemagick can't use dc7, it's use dxt5 max so you'll realy loose in quality comparing to dc7.