Engines Home  |  CONTOUR

Contour

CONTOUR.EXE is the standalone version of the MS3D contouring tool that is run from the command line.  It is used to contour a MineSight shell file and output the result to a .srv survey file.  To display the available options for CONTOUR.EXE use either the -h or -v option switches.

Options:

 

Elevation based surface contouring utility

-h

-v

Display the program command line help

 

-ishl file

Input from a MineSight® shell file (*.shl)

-osrv file

Output strings to a single survey file

-l

Elevation level(s)

Levels separated by commas

User [start,step,count] for range

-idx

Output contour index level in survey file as name

-e

Exact contours (do not "bump up")

-t value

Coincident points tolerance (optional)

-b value

Elevation "bump up" value (optional)

-q

 

Quiet mode

 

Required switches:

The -ishl (input file), -osrv (output file) and -l levels switches are REQUIRED.  

Input & Output files

The -ishl and -osrv switches are used with the names of a input shell file and an output survey file.   The input and output filenames should not contain spaces in the name.  However, if there are spaces in the input or output filenames, use double quotes around the, i.e. -ishl "topo file.shl" and -osrv "elevation of topo.srv".

Levels

The levels ("-l") option is used to specify the elevation levels to be contoured. A range of levels can be specified using a starting elevation, a step size and the number of levels to contour, or you can specify the individual levels to contour with comma separation. You can also use a combination of both methods.

Use the -l switch to specify the elevation levels in the format, level,[base,step,count].  

So that:

-l 150 - contour only level 150

-l 150,151 - contour only the specified levels, 150 and 151

-l [10,5,2] - means to contouring starts at level 10, step by 5 to the next level, and contour 2 levels;  this results in contouring levels 10, 15, and 20

-l 150,[10,5,2],151 - will contour level 150, then level10, step by 5 to contour 2 levels (levels 15, 20), and contour level 151.

Do not use spaces in the levels format.  If spaces must be used, then put double quotes around them, i.e. "1, 2, 3, [4, 1, 10]"

Optional switches:

  • -idx   - This option is used to output the contour index level in the output survey file as the point code (output in columns 1-4 in the output file).  If this option is not used, then a point code of "none" is used (default), as shown below.

For example, if you use the "-idx" option;  the contours are on the 40th level from the specified base elevation, the point code will be "0040" as shown below.

 

Output not using the -idx option

* * * Top of File * * *

Output using the -idx option

* * * Top of File * * *

  • The -e option results in exact contours.  This is the same as the contour coincident faces and edges option in the Contour Tool in MS3D.

The exact option is used to force the program to use exact contours and not “bump up” the values.  This option is the same as the Contour coincident faces and edges option in the Contour Tool inside MS3D. It is used when a contour edges fall exactly on one of the specified contour increments.

When using the "-e" option, numerous polyline segments are generated and all are along the exact contours.  Without using the "-e" option, if points are detected exactly on a level, then contours are bumped up by a very small amount (an amount equal to float epsilon, a very small number).

  • The -t option is used to set the value for coincident points detection.  Set to larger values for "noisy" data (noisy, being those areas on the shell where there are numerous minute changes within the tolerance range).

Tolerance option is used in conjunction with a given tolerance value to detect coincident points.  It should be used when the surface contains many areas with numerous minute changes within the tolerance range.

  • The -b option is used to specify the amount to bump up the elevation to remove coincident faces and edges when not using the exact contours (-e) option.  Used with a specified value, this option is used for bumping up the elevation to remove coincident faces and edges.  It can only used when the -e option is not specified.

  • The -q option suppresses all output except for error messages.  Except for any error messages, the Quiet option is used to suppress all screen output.

Usage

Using the Contour engine, a surface .shl file can be contoured using the following syntax:

contour.exe -ishl topography.shl -osrv topolines.shl -l [2000,15,64]

In the image below, the resulting contours are shown in lime green lying on the topography surface displayed in light brown.