DDS—DirectDraw曲面

司机简称

DDS

生成依赖项

紧缩库

微软公司的DirectDraw Surface文件格式(使用文件扩展名DDS)是一种标准,用于存储用有损S3纹理压缩(S3TC)算法压缩的数据。DDS格式和压缩由crunch库提供。

GDAL 3.1增加了对阅读的支持。以前的版本只支持写操作。

驱动程序支持以下纹理格式:DXT1、DXT1A、DXT3(默认)、DXT5和ETC1。可以使用“创建选项格式”设置纹理格式。

驱动程序支持以下压缩质量:SUPERFAST、FAST、NORMAL(默认)、BETTER和UBER。可以使用创建选项quality设置压缩质量。

More information about Crunch Lib (see below for build instructions of a working fork of that repository)

注:执行为 gdal/frmts/dds/ddsdataset.cpp .

驱动程序功能

Supports CreateCopy()

This driver supports the GDALDriver::CreateCopy() operation

生成说明

建设紧缩可能有点困难。这个 build_fixes 分公司https://github.com/rouault/crunch/包括一个CMake构建系统,以及一些在上游存储库中找不到的修复程序

构建crunch

Linux系统

git clone -b build_fixes https://github.com/rouault/crunch
cd crunch
mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=$HOME/install-crunch -DCMAKE_BUILD_TYPE=Release
make -j8 install

Windows

git clone -b build_fixes https://github.com/rouault/crunch
cd crunch
mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=c:\dev\install-crunch -G "Visual Studio 15 2017 Win64"
cmake --build . --config Release --target install

摆脱困境建立 GDAL

Linux系统

./configure --with-dds=$HOME/install-crunch

Windows

nmake.local 中,添加以下行:

CRUNCH_INC = -Ic:\dev\install-crunch\include\crunch
CRUNCH_LIB = c:\dev\install-crunch\lib\crunch.lib