Load DDS Image
Open .dds files in ComfyUI — the thing normal LoadImage can't do
- image
- mask
- filename
- path
- format
- color_space
ComfyUI's built-in Load Image chokes on .dds files. That's a real problem if your game project stores its textures as DirectDraw Surfaces - the standard for most engines - because every texture you want to touch needs to be decoded before it becomes an image, and decoded properly so the compressed BC format doesn't turn into garbage. Load DDS Image is the fix.
It's part of ComfyUI-Leputen-Utils, and it's honestly the reason most people install this pack at all. There are very few DDS-capable nodes for ComfyUI, and this one does the job with the actual DirectX texture tooling rather than a fragile pure-Python reimplementation.
How it works
The node decodes the DDS through the bundled texconv library (Microsoft's DirectXTex, shipped in the pack's bin/), which understands every BC format the format dropdown lists. It then hands you the image plus two extra niceties:
- Alpha bleeding - un-premultiplies alpha so you don't get ugly halos around transparent edges. This is the "essential for game assets" checkbox, and for most game textures you want it on.
- Blur during bleeding -
blur_radius(0–10) softens the RGB bleed into the transparent regions; the pack suggests 1.0–3.0 for smoother in-engine blending.
Inputs and outputs
Required: image (a dropdown of .dds files in your ComfyUI input folder - the tooltip notes it has to live there) and alpha_bleed (default on). Optional: blur_radius and invert_mask (flips the output mask so white becomes black).
Outputs:
imageandmask- the decoded pixels and alpha mask.filenameandpath- strings you can use to mirror naming when you re-save.formatandcolor_space- combo outputs carrying the original file's compression format and color space. The pack's smart-connection feature means these wire directly into Save DDS Image, so a load → save round-trip preserves the source format automatically.
Install
Same pack, same steps:
cd ComfyUI/custom_nodes
git clone https://github.com/lilquail/ComfyUI-Leputen-Utils
Restart ComfyUI and it shows up under Leputen-Utils → DDS. Windows gets the bundled texconv.dll; macOS/Linux users need to place the matching libtexconv.* from the Texconv-Custom-DLL releases into bin/ for anything DDS to work.
Troubleshooting
- BC5 files crash it. This is a documented known issue, not you doing something wrong: BC5-compressed images (commonly normal maps) can be saved but not loaded, and attempting a load errors and requires restarting ComfyUI. If your normals are BC5, load them as BC1/BC3 or from a non-DDS source.
- "File not found" - DDS files must be in the ComfyUI
inputdirectory (subfolders work, but it's the input dir, not the output dir). - Halo fringes on transparent decals - that's what
alpha_bleedis for; turn it on and nudgeblur_radiusto ~2. E_NOINTERFACE/RPC_E_CHANGED_MODEconsole warnings - ignore them. The node falls back to callingtexconv.exein a subprocess and proceeds normally.
One habit worth building: whenever you load a DDS you plan to re-save, keep the format and color_space wires attached. It's the difference between "round-trip, format intact" and "accidentally converted my normal map to BC1".
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| image | COMBO | Select a DDS image file to load. This should be placed in the ComfyUI input directory. | |
| alpha_bleed | BOOLEAN | true | Enable alpha bleeding (un-premultiply alpha) to prevent halo artifacts around transparent areas. Essential for game assets. |
| blur_radiusopt | FLOAT | 0.00–10 | Apply a blur to the RGB channels during alpha bleeding for smoother transitions. Only active if Alpha Bleed is enabled. |
| invert_maskopt | BOOLEAN | false | If enabled, the output MASK will be inverted (white becomes black, and vice-versa). |
Outputs (6)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| mask | MASK | — |
| filename | STRING | — |
| path | STRING | — |
| format | BC1_UNORM,BC2_UNORM,BC3_UNORM,BC4_UNORM,BC5_UNORM,BC6H_UF16,BC6H_SF16,BC7_UNORM,R16G16B16A16_FLOAT,R32G32B32A32_FLOAT,R8G8B8A8_UNORM,B8G8R8A8_UNORM,B8G8R8X8_UNORM,R10G10B10A2_UNORM | — |
| color_space | sRGB,Linear | — |