Dear GMT community,
I do not have a deep knowledge in GDAL and the structure of various grid files, so the solution to the problem I am facing is probably simple. After updatig GMT (GMT 6.5.0, GDAL 3.10.2), my existing script that used to work with the previous version (do not remember) no longer plots TIFF files. I have tried grdsample and QGIS to resize the files but it did not help. The file is in NTF (Paris) / Lambert zone II coordinate system but I use a linear projection (-JX), normally it works fine for my small area. Here is the grdinfo of the TIFF file:
argentiere_map_georef.tif: Title: Grid imported via GDAL
argentiere_map_georef.tif: Command:
argentiere_map_georef.tif: Remark:
argentiere_map_georef.tif: Pixel node registration used [Cartesian grid]
argentiere_map_georef.tif: Grid file format: gd = Import/export through GDAL
argentiere_map_georef.tif: x_min: 953645.7836 x_max: 964983.2466 x_inc: 2.65638776945 name: x n_columns: 4268
argentiere_map_georef.tif: y_min: 2112041.2055 y_max: 2121250.9018 y_inc: 2.65638774156 name: y n_rows: 3467
argentiere_map_georef.tif: v_min: 1.79769313486e+308 v_max: -1.79769313486e+308 name: z
argentiere_map_georef.tif: scale_factor: 1 add_offset: 0
argentiere_map_georef.tif: Default CPT:
+proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0 +k_0=0.99987742 +x_0=600000 +y_0=2200000 +ellps=clrk80ign +pm=paris +towgs84=-168,-60,320,0,0,0,0 +units=m +no_defs
GMT prints some warning messages, which I used to ignore. These messages disappear after resizing the TIFF file, so I don’t think they are the root cause of the problem:
grdimage [WARNING]: (w - x_min) must equal (NX + eps) * x_inc), where NX is an integer and |eps| <= 0.0001.
grdimage [WARNING]: w reset from 958000 to 957999.603154
grdimage [WARNING]: (e - x_min) must equal (NX + eps) * x_inc), where NX is an integer and |eps| <= 0.0001.
grdimage [WARNING]: e reset from 962000 to 962000.123135
grdimage [WARNING]: (s - y_min) must equal (NY + eps) * y_inc), where NY is an integer and |eps| <= 0.0001.
grdimage [WARNING]: s reset from 2115000 to 2114997.76506
grdimage [WARNING]: (n - y_min) must equal (NY + eps) * y_inc), where NY is an integer and |eps| <= 0.0001.
grdimage [WARNING]: n reset from 2119000 to 2119000.94138
basemap [ERROR]: Option -L: Not allowed for Cartesian projections
I am wondering whta have been changes in the new verions of GMT. I would appreciate any help or hints.
Regards,
Anuar