Last active
February 26, 2022 22:58
-
-
Save nihirash/8c36680992f6b13811a316758fb34e17 to your computer and use it in GitHub Desktop.
Convert any image to DXT1 texture(for Apollo V4 computers). Requires imagemagick installed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| if [ $# -ne 2 ] | |
| then | |
| echo "Usage: img2dxt1 <source-image> <output-name>" | |
| exit 1 | |
| fi | |
| if [ ! -f "$1" ] | |
| then | |
| echo "Input file does not exists!" | |
| exit 1 | |
| fi | |
| convert "$1" -resize "256x256!" -depth 8 -define dds:compression=dxt1 DXT1:"$2" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment