TransWikia.com

ECW support for Java development

Geographic Information Systems Asked on August 3, 2021

I’m trying to add support for the ECW file format in a Java application the last few days without any success.

My development env is
OS: Windows 10 (x64)
JDK: openjdk 15
IDE: Eclipse

On my pom I added suppport for the GeoTools:

<dependency>
  <groupId>org.geotools</groupId>
  <artifactId>gt-imageio-ext-gdal</artifactId>
  <version>25.1</version>
</dependency>

I installed the GDAL library, and GDAL data and also create the env variables that the docs suggested.
GDAL_DATA that point to the gdal-data downloaded from gdal
GDAL_DRIVER_PATH that points to GDAL dll’s, GDAL plugins (default, extra and optional)

I also installed the ERDAS ECW/JP2 SDK and added the x64 dll’s containing folder to the GDAL_DRIVER_PATH env variable.

Another thing I installed was the JAI imageio-ext as suggested in some stackoverflow/stackexchange.

I can confirm that GDAL is working on the machine with support for ECW,
gdalinfo --formats shows ECW support, but when I try to use the ECWReader in my Java application it says that the format isn’t supported with message:

The provided input is not supported by this reader.

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP