Raster Format Conversion Using gdal translate: Difference between revisions
Content deleted Content added
Ellis Symons (talk | contribs) No edit summary |
Ellis Symons (talk | contribs) No edit summary |
||
Line 48:
:** ''<tt>TABLE=<name></tt>'': Name of the raster within the GPKG to be converted.
<pre>gdal_translate.exe -of GTiff -oo TABLE=DEM_M01_5m DEM_database.gpkg DEM_M01_5m.tif</pre>
==Converting To FLT==
FLT is not supported as a write format in GDAL (the driver name is "AIG" and is read-only - '''<u>[https://gdal.org/drivers/raster/aig.html More Details]</u>'''). Fortunately GDAL does support writing to a similar format, "EHdr", however requires some additional steps to convert the ".hdr" into one that is supported by TUFLOW. The steps below outline this process:
: <b>''Note:''</b> The '''<u>[[ASC_to_ASC | ASC_to_ASC Utility]]</u>''' supports conversion between ASC and FLT, therefore if converting from an ASC it's recommended to use this utility instead of the steps below. It's also possible to use '''gdal_translate.exe''' to convert to an ASC then use ASC_to_ASC.exe to convert the output to FLT. However if the raster is quite large, the interim step can be time consuming and the steps below outline how to go straight from one raster format straight to FLT using '''gdal_translate.exe'''.<Br>
<ol>
<li> Convert to an "EHdr" raster. This example assumes the input file is a GeoTIFF.
<pre>gdal_translate.exe -of EHdr DEM_M01_5m.tif DEM_M01_5m.flt</pre>
<li> The output ".flt" is identical to the "FLT" supported by TUFLOW so no updates to this file are required. The ".hdr" however is slightly different and requires manual updating.
</ol>
| |||