TOPIC: This Tech Tip explains how to export RiverTools Grid (RTG) files so that they can be imported by Arc/Info and other GIS programs. DISCUSSION: RiverTools can derive measurements such as contributing area, slope, aspect, curvature, flow distance, relief, Horton-Strahler order, flow directions and many others from the single input of a DEM (digital elevation model). Most of these derived grids are created with dialogs in the Extract menu. In the common case of fixed-angle or "geographic" DEMs, the measurements in RiverTools are computed as accurately as possible by integrating on the ellipsoid model of your choice rather than first distorting the data with a map projection. RiverTools appears to be the only GIS program available that always takes latitude-dependence of pixel geometry into account when making measurements. Grids computed by RiverTools are saved as binary files in the simple and optimally-efficient RiverTools Grid (RTG) format. This format is fairly generic, so that BIL, FLT, HGT (SRTM), and ENVI IMG files are all special cases. The only difference between these formats is the format of the associated ASCII header file that contains the georeferencing information. For BIL and FLT files, the header file has the same prefix and the extension HDR. For RTG files, the header file also has the same prefix but the extension RTI (RiverTools Information). All of the RTG files derived from a given DEM have the same georeferencing information as the DEM except for the data type (BYTE, INTEGER, FLOAT, LONG, or DOUBLE), so there is often only a single RTI file in a directory that contains RTG files. In this case, the data type listed in the RTI file is for the associated DEM, and the data type of the other RTG files is determined as needed from filesize and a special file in the RiverTools 4.0 "resource" folder called "lon_list.txt" that lists the extensions of files that are known to contain 4-byte long integer numbers as opposed to 4-byte floating-point numbers. The path to the RiverTools "resource" folder on Windows is typically: "C:\Program Files\RiverTools_4.0\menu". Alternately, each RTG file can have its own RTI file, and some routines in the Extract menu that create RTG files also create a matching RTI file that contains the data type of that RTG file. An RTG file with a data type of INTEGER is equivalent to an Arc/Info BIL file, and an RTG file with a data type of FLOAT is equivalent to an Arc/Info FLT file. So exporting RTG grids to Arc/Info really only requires the creation of an Arc/Info HDR file. This is a small, ASCII/text file that contains keywords followed by corresponding georeferencing and byte order information. The RTG file can simply be renamed to have the BIL or FLT extension, as appropriate, to avoid confusion. To create the HDR file that Arc/Info needs for the georeferencing information, you use the File > Export Grid dialog, select an RTG file (or renamed/copied file with extension BIL or FLT) from the working directory and then choose ARC Raster Grid from the dialog's list of file formats. A text file with the same prefix as the RTG file you selected and the extension HDR will be created in the same directory. You would then copy the binary file (RTG, BIL or FLT) and the new header file (HDR) into an Arc/Info working directory and import it into Arc/Info with either the IMAGEGRID or FLOATGRID commands. Arc/Info also has commands called GRIDIMAGE and GRIDFLOAT that do the opposite of IMAGEGRID and FLOATGRID. This allows Arc/Info grids to be imported into RiverTools. These are discussed in a separate Tech Tip. You can also export RTG files in GeoTIFF format, which is readable by many other GIS programs. If you have any additional questions or comments, please contact Rivix Technical Support for assistance. Copyright (C) RIVIX, LLC. 1998-2024 |