next up previous contents
Next: Source Code Up: C Implementation of SmartForest Previous: xlibgui.lib
Go to: SmartForest Home Printer-friendly: sf-impl.pdf

Running SmartForest

The SmartFOGL executable has several optional parameters. The first is a parameter that affects X-Windows. Valid values for this parameter are -installc and -autopref. The remaining five parameters are file names.

The command that runs the program is:

SmartFOGL x_parms dem_mapname stand_name treelist_name stemlist_name trans_name

where
x_parms May be -installc or -autopref or both.
dem_mapname Contains ground height data. Has an extension of .elev
stand_name Defines stand identifiers on a grid-by-grid basis. Has an extension of .stnd
treelist_name Maps trees to stands. Has an extension of .trl
stemlist_name Defines stand characteristics. Has an extension of .slf
trans_name Translation map from 26-char stand id to 32-bit integers. Has an extension of .trans

The parameters may be specified in any order. If the files exist and are formatted properly, SmartForest will display the Map View screen and the Forest View screen. The application is now considered running.

Parameters 2-5 have default file names. The user need only provide these parameters on the command-line if they want to override the default file names. The default file names are smartforest.elev, smartforest.stnd, suppose.trl and suppose.slf. The last parameter does not have a default name and must be explicitly listed on the command-line when the user wants a translation file. If a parameter ending in .trans is not specified, then SmartForest assumes that all of the stand ids in the .slf file will fit properly into a 32-bit integer.

SmartForest is designed to work in tandem with INFORMS. There are two environment variables that, if set, help SmartForest determine where to find the input files. The two environment variables are INFORMS_LOCALGIS and INFORMS_LOWPROJID. These two environment variables, when supplied, are concatenated together and used as the subdirectory that stores the input file names. For example, if INFORMS_LOCALGIS = /usfs/home and INFORMS_LOWPROJID = /jmarston, then SmartForest will look in /usfs/home/jmarston for all of the input files. If these two environment variables are not set, then SmartForest will look for the input files in the same subdirectory where the executable resides.


next up previous contents
Next: Source Code Up: C Implementation of SmartForest Previous: xlibgui.lib
Matthew S. Davis
2002-08-07