I'm using org.geotools.gce.geotiff.GeoTiffFormat to write a GeoTIFF. I would like to use Float32 instead the default Float64. I've tried:

    OutputStream output = ...
    Hints hints = new Hints(Hints.SAMPLE_DIMENSION_TYPE, SampleDimensionType.REAL_32BITS);
    GridCoverageWriter targetWriter = new GeoTiffFormat().getWriter(output, hints);

But it still writes as Float64 (as verified with gdalinfo). Any ideas?

  • what are you writing out? is it a float or double based raster? – Ian Turton Jan 21 '17 at 11:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.