ExportSTL - MapleSim Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


Terrain

  

ExportSTL

  

export STL files for the terrain

 

Calling Sequence

Parameters

Options

Description

Examples

Calling Sequence

ExportSTL(T, filedir, opts)

T:-ExportSTL(filedir, opts)

Parameters

T

-

Terrain; the Terrain object

filedir

-

string; the directory into which to write the STL files

opts

-

(optional) equation(s) of the form option = value; specify options for the ExportSTL command

Options

checkered = truefalse

Specifies whether the terrain is checkered. The default is true.

overwrite = truefalse

Specifies whether existing STL files are overwritten. The default is true.

Description

The ExportSTL method creates and exports the STL files representing the terrain visualization. Before using this procedure, a normal or checkered plot should have been previously generated.

Examples

withTires:

Define the terrain equation.

eq0.1tanhx5tanhx30:

Generate a Terrain object using the defined equation. Select the z-axis as the up direction. The order of the two independent variables is [x,y]. Assign the range for x to be -10 to 100, and for y to be -10 to 10. Also, assign 50 grid points for the x-axis and 10 for the y-axis. Finally, set the title to myTerrain.

terrainGenerateTerraineq,10..100,10..10,50,10,up_direction=z,title=myTerrain:

Create a checkered plot of the terrain.

terrain:-CheckeredPlotsize=2,2,res_size=2,2

Export the STL files for the checkered plot.

terrain:-ExportSTLFileTools:-TemporaryDirectory

true,/tmp/mpldoc3/myTerrain_1.stl,/tmp/mpldoc3/myTerrain_2.stl

(1)

See Also

Terrain

Tires