This document originated on GitHub
This is a plug-in for reading and writing the DirectDraw Surface (DDS) format in Adobe After Effects and Photoshop. DDS uses compression formats that can be decompressed in a GPU, so the format is commonly used to store textures. It also supports other relevant features such as mipmaps.
Written by Brendan Bolles of fnord software. Made possible by the sponsorship of Walter Soyka of Keen Live and Cameron Yeary of UVLD.
Manually copy the plug-in to your host application's plug-in folder. Double-clicking the plug-in file will not install it.
Format | Channels | Alpha Type | Premultiplied |
DXT1 | RGB | None | N/A |
DXT1A | RGBA | 1-bit | N/A |
DXT2 | RGBA | Explicit | Yes |
DXT3 | RGBA | Explicit | No |
DXT4 | RGBA | Interpolated | Yes |
DXT5 | RGBA | Interpolated | No |
DXT5A | A | Alpha as Luma | N/A |
3Dc | XY | None | N/A |
DXN | YX | None | N/A |
Uncompressed | RGB(A) | Uncompressed | Undefined |
The difference between the DXTn formats is how they handle alpha. DXT2/3 are better suited for alpha channels with hard edges, while DXT4/5 are better suited for soft-edged alphas. DXT 2 & 4 expect the RGB to be premultiplied, while DXT 3 & 5 do not.
Managing the premultiplied state of the alpha is left up to the user. In After Effects, you should set the output module's premultiplied state to match the format you're going to be using. In Photoshop, the plug-in provides an option to preform a premultiplication, and it is left up to the user to do use this feature where appropriate.
DXT5A saves only the alpha channel, at high quality. 3Dc and DXN are intended for normal maps. Uncompressed storage is not supported by most applications that use DDS.
The plug-in can create a DDS cube map if your Photoshop document is in a vertical cross arrangement. The plug-in will make sure your file is 4/3 as tall as it is wide. It also requires that the height be a power of 2 for some reason.
Copyright (c) 2014, Brendan Bolles
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
Relies heavily on crnlib by Rich Geldreich, which uses the zlib license:
Copyright (c) 2010-2012 Rich Geldreich and Tenacious Software LLC
This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.
Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:
1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.