[gdal-dev] Using GDALTranslateOptions with '-a_ullr' doesn't work
Paul Meems
bontepaarden at gmail.com
Mon Jan 16 23:59:30 PST 2017
Hi list,
I'm using GDAL v2.1.2 from GisInternals.com on Win10 with the C#-bindings.
I'm trying to recreate this gdal_translate command in C#:
gdal_translate -of GTiff -a_nodata 65535 -a_srs "+proj=stere +lat_0=90
+lon_0=0 +lat_ts=60 +a=6378.14 +b=6356.75 +x_0=0 y_0=0" -a_ullr 0.0,
-3650.000, 800.000, -4415.000 "HDF5:\"in.h5\"://image1/image_data" "out.tif"
This is my C#-code:
var options =
new GDALTranslateOptions(new[]
{
"-of", "GTiff",
"-a_nodata", "65535",
// "-a_srs", "\"+proj=stere +lat_0=90 +lon_0=0 +lat_ts=60
+a=6378.14 +b=6356.75 +x_0=0 y_0=0\"",
//"-a_ullr", "0.0, -3650.000, 800.000, -4415.000"
});
var newDs = Gdal.wrapper_GDALTranslate(outputFile, ds, options, null, null);
The above code works, because I commented the last two GDALTranslateOptions.
When I enable the -a_srs option I get this error: Failed to process SRS
definition
When I enable the -a_ullr option I get Unknown option name '-a_ullr'
So it seems I'm not doing it right. I tried looking for examples but
couldn't find any.
Can anybody assist?
Thanks,
Paul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20170117/35032d74/attachment.html>
More information about the gdal-dev
mailing list