GENERATE_CONTOURS

The GENERATE_CONTOURS command allows for the generation of contour lines (isolines of equal elevation) from any or all currently loaded elevation data or point cloud data. To generate contours directly from point cloud data, a Global Mapper Pro license is required. The following parameters are supported by the command.

  • FILENAME - filename of the layer(s) to contour. If an empty value is passed in, all loaded terrain data will be used. This parameter can be listed more than once to specify multiple input files, like FILENAME="FILENAME_1" FILENAME="FILENAME_2".
  • ELEV_UNITS - specify elevation units to use in export
    • FEET - export in US feet
    • METERS - export in meters
  • INTERVAL - specifies the contour interval to use, or the single contour level if SINGLE_LEVEL_ONLY=YES is provided. If a contour interval, this must be a number greater than 0. The units are specified with the ELEV_UNITS parameter described above. If you wanted to generate a contour file with an interval of 20 feet, you would use INTERVAL=20 ELEV_UNITS=FEET in the parameter list. If no interval is provided, a default one is guessed based on the elevation range of the loaded elevation data.
  • SINGLE_LEVEL_ONLY - specifies that the INTERVAL value is actually a value indicating the only height that a contour should be generated at. Use a value of YES to turn this functionality on.
  • GEN_FROM_TIN_AREAS - specifies that the contours should be generated from any loaded TIN (3D triangle) areas rather than from loaded terrain data. Add GEN_FROM_TIN_AREAS=YES to command to use TINs.
  • MULT_MINOR - specifies how many contours apart every intermediate contour is. For example, use MULT_MINOR=5 to make every 5th contour an intermediate contour. So using INTERVAL=10 and MULT_MINOR=5 creates intermediate contours every 50 meters.
  • MULT_MAJOR - specifies how many contours apart every major contour is. For example, use MULT_MAJOR=10 to make every 10th contour an intermediate contour. So using INTERVAL=10 and MULT_MINOR=10 creates major contours every 100 meters.
  • MIN_ELEV - minimum elevation to consider for contours. Must be specified in conjunction with MAX_ELEV in order to restrict the range of contour generation to anything other than the full range of loaded elevation values. Units are specified by ELEV_UNITS parameter.
  • MAX_ELEV - maximum elevation to consider for contours. Must be specified in conjunction with MIN_ELEV in order to restrict the range of contour generation to anything other than the full range of loaded elevation values. Units are specified by ELEV_UNITS parameter.
  • SPATIAL_RES - specifies spacing of grid points used to determine contour position. A smaller grid spacing results in higher fidelity, but larger, contours. Typically you'll want to use the default value which is the minimum spatial resolution of all loaded data. Should be formatted as x_resolution,y_resolution. The units are the units of the current global projection. For example, if UTM was the current global projection and you wanted to use a grid with a 30 meter spacing, the parameter/value pair would look like SPATIAL_RES=30.0,30.0. You can also specify as a percentage of the default resolution by adding a percentage. For example to get half the detail, double the spatial resolution value, so you would use SPATIAL_RES="200%,200%".
  • SPATIAL_RES_METERS - specifies spatial resolution to use in meters. The value in meters will automatically be converted to the current view/export projection units. For example, to do an export at 2.0 meter spacing (or as close as you can get to that in the current units), use SPATIAL_RES_METERS=2.0, or to do an export at 1.0 meters in X by 1.5 meters in Y, use SPATIAL_RES_METERS="1.0,1.5".
  • SIMPLIFICATION - specifies the simplification threshold to use when generating the contours. This specifies how far off a straight line (in the units of the current projection) that a point has to be before it is kept. Generally you should not specify a simplification value as the default value of one tenth of the sample spacing works quite well. This is an option for advanced users only.
  • SAMPLING_METHOD (elevation and raster only) - specifies the sampling method to use when resampling this layer. The following values are supported: 
    • DEFAULT - Use either automatic resampling based on export or layer resampling, depending on setting of global flag about whether to resample on export
    • AUTO - Automatically select a resampling method based on how the export resolution and bounds compare to the original layout for a layer. For example if you export to a lower resolution a box averager of appropriate size may be used automatically
    • LAYER - Use the sampling method set for each layer
    • The list of SAMPLING_METHOD values for the IMPORT command can also be specified to use a particular sampling method for all layers being exported.

  • GEN_HEIGHT_AREAS - generate area features colored based on the current elevation shader in addition to generating contour lines. Use a value of YES to enable the generate of the height areas.
    • NON_OVERLAPPING - with the GEN_HEIGHT_AREAS enabled NON_OVERLAPPING=YES will ensure the generated areas do not overlap. NON_OVERLAPPING=NO will create areas that overlap.
  • GEN_SPOT_ELEVATIONS - generate spot elevations at min/max elevations. Use a value of YES to enable the generate of min/max spot elevation points.
  • FILL_GAPS - specifies that small gaps in between and within the data sets being used to generate the contours will be filled in by interpolating the surrounding data to come up with an elevation for the point in question. This option is on by default, specify FILL_GAPS=NO to turn off.
  • LAYER_DESC - specifies the name to assign to this layer. If no layer description is provided, the default name of "GENERATED CONTOURS" will be used.
  • INC_UNIT_SUFFIX - specifies whether or not a unit suffix (either "m" or "ft") should be appended to the numeric label of generated features. By default this is enabled, so specify INC_UNIT_SUFFIX=NO to turn unit suffixes off. This is useful if the data the contours are being generated over doesn't actually represent elevation.
  • SMOOTH_CONTOURS - specifies whether or not generated contour line and area features should have smoothing applied to improve appearance. This option is enabled by default. Use SMOOTH_CONTOURS=NO to disable smoothing.
  • CREATE_ON_WAY_DOWN - specifies whether contours are created as the terrain passed from a higher elevation to a contour height (CREATE_ON_WAY_DOWN=YES) or the default way of being created when the terrain passes from a contour height to lower elevation values (CREATE_ON_WAY_DOWN=NO).
  • MIN_CONTOUR_LEN - specifies that any closed contour lines less than the specified length (in meters) will be marked as deleted. This is useful for cleaning up contours in very rugged and detailed terrain, like from Lidar. The default is to keep all generated contour lines.
  • FIND_PEAKS - specifies whether to find isolated peak points on the surface. Use FIND_PEAKS=YES to enable.
    • MAX_PEAK_DIST - The maximum distance in meters between two points sharing a key contour.
    • MIN_PEAK_SLOPE - specifies the minimum slope (in degrees) required between concentric contours to consider a local extrema to be a peak or depression.
    • MIN_CONCENTRIC - The minimum number of concentric contours needed to define a candidate peak.
    • MIN_SADDLE - The minimum amount of elevation drop between close peaks to recognize them as separate.