# ECW -- ERMapper Compress Wavelets (.ecw)

GDAL supports .ecw format for read access and write. The current implementation reads any number of bands but returns only as eight bit image data. Georeferencing transform information is read, but projection and datum definitions are ignored.

## Caveats and Limitions

1. Windows Only: Currently it appears that the ECW SDK is avalable only for Windows, so ECW support in GDAL is only available on windows.

2. Compilation Optional: Inclusion of ECW support in GDAL is a build time option, and disabled by default. GDAL for windows will not support ECW if it was not configured in during the build of the GDAL librarys (controlled by uncommenting and adjusting the lines starting with ECW in the gdal\nmake.opt file).

3. Extra DLLs Required: To work, the ECW support requires that the ECW SDK DLLs NCSEcw.dll, NCSEcwC.dll, NCSUtil.dll and NCScnet.dll be somewhere in the path, for instance in the same directory as the GDAL DLL.

## Creation Issues

The free ECW compression kit only supports compression of images up to 500MB. To compress very large images it is necessary to license ECW technology from ERMapper. Files to be compressed into ECW format must also be at least 128x128. Non-eight bit source data will be rescaled by the ECW SDK in some manner that I don't understand ... the resulting image is effectively eight bit.

While georeferencing information is written to the ECW file, the coordinate system definition is currently not (this could be corrected).

Creation Options:

- TARGET=percent: Set the target size reduction as a percentage of the original. If not provided defaults to 75 for an 75% reduction.

- BLOCKXSIZE=n: Width of blocks to use for compression. Must be one of 64, 128, 256, 512, 1024, 2048. Default is 256.

- BLOCKYSIZE=n: Width of blocks to use for compression. Must be one of 64, 128, 256, 512, 1024, 2048. Default is 256.

- BLOCKSIZE=n: Same as setting BLOCKXSIZE and BLOCKYSIZE.

ECW format does not support creation of overviews since the ECW format is already considered to be optimized for "arbitrary overviews".

See Also:

- Implemented as `gdal/frmts/ecw/ecwdataset.cpp`.

- ECW Page at www.ermapper.com.