Fallout 4

File information

Last updated

Original upload

Created by

dc - dont care

Uploaded by

DullCandle29

Virus scan

Safe to use

Tags for this mod

About this mod

Simple batch script I made that converts images in a folder to DDS with DirectXTex TexConv.exe, a free DDS converter made by microsoft.

Requirements
Permissions and credits
Changelogs
If you would like to edit existing DDS images, paint.net https://www.getpaint.net/ is a free image editing program that can open and save DDS images.

Check out my batch BSA/BA2 extractor/packer script for BSArch https://www.nexusmods.com/newvegas/mods/69145?tab=description

=== WorkInProggress ===
Feedback appriciated, let me know if any features are missing, or any errors/mistakes encountered.

You can read more info on TexConv in the github wiki:
https://github.com/microsoft/DirectXTex/wiki/Texconv

Script Formats:
You can change the @FORMAT variable to equal any of the formats listed below, let me know if any information I have is wrong or outdated.

BC7_UNORM - Optimized For SSE & Fallout 4 (BC7 Compressed)
BGRA - High Quality, Large Image File Size (Uncompressed?)
DXT5 - Legacy Low Quality Format, For Pre OldRim games* (BC3 Compressed?)

*The engine before OldRim A.K.A. Skyrim LE does not support the new BC7 format (Not the SSE or the special edition, that one does support BC7) So Oblivion, Skyrim LE, Fallout 3 and New Vegas, all use DXT1, DXT5, or BGRA formats since that's what DirectX9 was capable of back then.

Known Errors:
> Converting images with the same file name but different formats will be overwritten with the last image converted.
ex: converting test.jpg and test.png will create test.dds and test.dds, since there's already a test.dds, the png image will overwrite it thus the output will only have 1 converted image instead of 2.


Instructions:

1) Download the latest version of texconv.exe

https://github.com/Microsoft/DirectXTex/releases

2) Download/extract my bat script

3) Copy/Move the texconv.exe & my bat script to a new empty/working folder with user permissions.

4) Double click the batch script to make the input and output folders.

5) Place your BMP, JPG, JPEG, PNG, DDS (yeah you can convert a DDS image to another DDS image), TGA, HDR, TIF, TIFF, WDP, HDP, JXR, PPM, or PFM images in the "InputImages" folder.

6) Double click the batch script again to convert the images in the "InputImages" folder to DDS in the "OutputImages".

-------------------------------------------------------------------------
Here is the batch script reduced to 7 lines, it does not include the error check for texconv.exe that is in the main script.
As of v0.2 the script can now convert sub directories, this v0.1 script can only convert a single folder.

TexConv - DXT5 Convert InputImages v0_1.bat


@ECHO OFF
COLOR B
IF NOT EXIST InputImages MKDIR InputImages
IF NOT EXIST OutputImages MKDIR OutputImages
echo: & "texconv.exe" -srgb -f DXT5 InputImages\* -o OutputImages\ -y
ECHO: && ECHO: && ECHO=== Script Complete === && ECHO:
pause

-------------------------------------------------------------------------

Configurable Variables:


@FORMAT=BGRA
::This variable is the DDS format, you can change it to any of the following formats:
:: You can double click a format to select the whole thing, since they're seperated by spaces.


RGBA BGRA DXT1 DXT2 DXT3 DXT4 DXT5 BC6H_UF16 BC6H_SF16 BC7_UNORM BC7_UNORM_SRGB

R32G32B32A32_FLOAT R32G32B32A32_UINT R32G32B32A32_SINT R32G32B32_FLOAT R32G32B32_UINT R32G32B32_SINT R16G16B16A16_FLOAT R16G16B16A16_UNORM R16G16B16A16_UINT R16G16B16A16_SNORM R16G16B16A16_SINT R32G32_FLOAT R32G32_UINT R32G32_SINT R10G10B10A2_UNORM R10G10B10A2_UINT R11G11B10_FLOAT R8G8B8A8_UNORM R8G8B8A8_UNORM_SRGB R8G8B8A8_UINT R8G8B8A8_SNORM R8G8B8A8_SINT R16G16_FLOAT R16G16_UNORM R16G16_UINT R16G16_SNORM R16G16_SINT R32_FLOAT R32_UINT R32_SINT R8G8_UNORM R8G8_UINT R8G8_SNORM R8G8_SINT R16_FLOAT R16_UNORM R16_UINT R16_SNORM R16_SINT R8_UNORM R8_UINT R8_SNORM R8_SINT A8_UNORM R9G9B9E5_SHAREDEXP R8G8_B8G8_UNORM G8R8_G8B8_UNORM BC1_UNORM BC1_UNORM_SRGB BC2_UNORM BC2_UNORM_SRGB BC3_UNORM BC3_UNORM_SRGB BC4_UNORM BC4_SNORM BC5_UNORM BC5_SNORM B5G6R5_UNORM B5G5R5A1_UNORM B8G8R8A8_UNORM B8G8R8X8_UNORM R10G10B10_XR_BIAS_A2_UNORM B8G8R8A8_UNORM_SRGB B8G8R8X8_UNORM_SRGB

AYUV Y410 Y416 YUY2 Y210 Y216 B4G4R4A4_UNORM FP16 FP32 BPTC BPTC_FLOAT

:: DXT5 Has compression artifacts, BGRA is basically uncompressed, BC7 is the recommended format to use for fallout 4


@FINPUT=InputImages\*
:: This variable is the input folder, you can change it to a full direct path like F:\Modding\My Custom Images\* just don't use quotes and make sure to have the * at the end or the script wont work

@FOUTPUT=OutputImages\

:: This variable is the same as above but it's the output folder where the DDS images will be created.

-------------------------------------------------------------------------

Changelog:

v0.2
- Added support for converting sub-directories, which will also have their folder structure preserved.
- Added BC7 Format Script
- v0.2.4 Changed BC7_UNORM_SRGB to BC7_UNORM due to strange color glitch

v0.1 - Made simple working batch script

I'm working on a scripted installer that makes scripts for the formats the user chooses configured with settings set by the user, but it will take a while to make all of the menus work together.