Rocscience International Conference 2025 is going to take place in Sydney, Australia Read more

Search Results

2 - Terrain Generator and Image Segmentation

1.0 Introduction

The Terrain Generator can be used to import digital elevation models and surface textures from satellite data. Image Segmentation can then be applied to the imported surface texture to automatically assign materials to the slope surface.

Topics covered in this tutorial:

  • Import Terrain
  • Topographic Lines
  • Image Segmentation
  • Select Faces by Filter

Finished Product:

The finished product of this tutorial can be found in the Tutorial 02 Terrain Generator and Image Segmentation data file. All tutorial files installed with RocFall3 can be accessed by selecting File > Recent Folders > Tutorials Folder from the RocFall3 main menu.

2.0 Geometry

2.1 Import Terrain

The Terrain Generator tool allows users to quickly create the slope geometry by importing a digital elevation model from satellite data. This feature can only be used when there is internet connection. The terrain location can be specified in several ways: 1) by directly searching a civic address; 2) by entering coordinates for the latitude and longitude; or 3) or by browsing through the provided map. This tutorial uses coordinates for the latitude and longitude.

To use the Terrain Generator, first open a new project in RocFall3, then access the feature as follows:

  1. Select Geometry > Import/Export > Import Terrain Import Terrain icon
  2. Set the Layer as Satellite.
  3. Set the Region Dimensions (km) to Custom and enter:
    • Width = 1.5 km
    • Height = 1 km
  4. Enter the Center Coordinate as 38.86295534611765, -120.071928601074 and click Set. Alternatively, coordinates can be copied and pasted into the Center Coordinate text box.

    Import Terrain Dialog

  5. Check Assign Map Image as Texture, and then click Post-Processing. Post-processing options include geometry simplification and repair.

Import Terrain dialog #2

2.2 Simplify and Repair Geometry

These geometry tools are common in all Rocscience 3D software.
  1. Select Simplify Triangulation.
  2. Under Simplification Level select Custom > By Triangle Count and enter 25000. Notice that the current number of surface triangles is around 215000, which is a large number that may lead to longer compute times.

    Simplify Triangulation dialog

  3. Click OK.

    Note: The number of surface triangles can always be viewed in the simplification tool by selecting Geometry > Surface Triangulation tools > Simplify Triangulation.
  4. After being redirected back to the Import Terrain dialog, select Find and Repair Defects.
  5. Defect counts for the different defect types are shown. Click Repair and then Close.

    The Simplification and Repair Process does not remove the image texture on the terrain. Other geometry processes that can change the overall geometry of the surface can remove the image texture.

    Repair Geometry dialog

  6. Select Done to close the Import Terrain dialog.

The default surface texture may be hard to see due its transparency. To change the transparency, select the Terrain entity in the Visibility Tree, then in the Properties pane change the Transparency to 0%. De-select the Terrain entity by either clicking in the viewport outside the slope or using the Clear Selection toolbar option.

Imported Terrain

2.3 Set Slope Surface

When done editing the slope:

  1. In the Visibility Tree, select the Terrain entity.
  2. Select Geometry > Set Slope Surface menu option.
Once a surface geometry has been "set as slope", its geometry can no longer be modified unless the user selects Geometry > Clear Slope Surface.

2.4 Show Topographic Lines

Topographic lines can serve as a visual aid in the placement of elevation-dependent elements, such as materials, seeders, and protection systems.

  1. Select Annotate > Topographic Lines Topographic lines icon in the menu.
  2. In the Visibility Tree, select the Topographic Annotation entity to access its properties in the Properties Pane below.
  3. Go to the Properties Pane, change the Spacing to 100 and check Show Colors.

Topo Lines

3.0 Slope Materials and Seeder

3.1 Define Material Properties

Define 3 materials for this model.

  1. Select Materials > Define Materials Define Materials icon in the menu.
  2. Use values in the following table to define 3 materials.
  3. Change the color of the water material to a Light Blue.
  4. Name

    Normal Restitution

    DistributionSt. dev. / Rel.Min / Rel.MaxTangential RestitutionDistributionSt. dev. / Rel.Min / Rel.MaxFriction Angle (o)
    Hard0.7Normal0.04 / 0.12 / 0.120.85Normal0.04 / 0.12 / 0.1220
    Soft0.5Normal0.04 / 0.12 / 0.120.8Normal0.04 / 0.12 / 0.12



3.2 Add Material Regions

3.2.1 Automatically Assign Materials by Texture (Image Segmentation)

An imported surface texture can be segmented for defining different material regions. This feature is applied as follows to assign the Hard and Soft materials to the slope surface.

  1. Select Materials > Automatically Assign Materials by Surface Texture Image Segmentation Icon
  2. Notice two images of the slope are shown in the dialog. The original image is shown on the right, and the segmented image is shown on the left.
  3. For the Number of Segmentations, use a value of 2. This field controls the number of segmented regions on the slope.
  4. Under the Segmentations section, a list of segments is provided, along with the corresponding assigned material property and the display colour for each segment. Apply the segmentation as shown below.

    Image Segmentation
  5. Close the dialog by clicking OK.

The Image below illustrates the material assignment by image segmentation. For now, there are two lakes assigned with the Soft material property. The Water property can be defined for the two water bodies by manually implementing material regions (e.g., by drawing) and overriding the image segmentation.

Material Assignment

When material assignment by image segmentation and manually drawn material regions overlap, the drawn material region takes priority and is used in computations.

3.2.2 Drawing Water regions

  1. Select the Material Regions tab located next to the Tree tab in the Visibility pane.
  2. Click Draw New Regions.
  3. Select the Water Property and click OK.
  4. Now in Draw Polyline mode, draw a Water region by left-clicking around the outline of one of the lakes.
  5. Right-click and select Done when finished drawing.
  6. Repeat steps 2-5 to draw a Water material region for the second lake.

Water Region 2

For exact coordinates of the material regions used in this tutorial, open the provided .txt files in the Tutorials folder or download the files linked below. Select Draw New Region, select the Water property, then after entering Draw Polyline mode, select the import option in the Edit Polyline dialog and import the Tutorial 02 Water Region 1.txt and Tutorial 02 Water Region 2.txt files for regions 1 and 2.

When there are overlapping material regions, the material property in the region that's highest in the Defined Regions list is used. Click on the UP/DOWN buttons to adjust the regions' hierarchy.

Click on the Tree tab in the Visibility pane to exit the Material Regions mode.

3.3 Add Line Seeder

  1. Change to the Seeders Flow Tab.
  2. Select Seeders > Define Seeder Properties in the menu.
  3. For Seeder Property 1, set the Number of Rocks to 300.
  4. Leave all other values at their default and click OK to close the dialog.
  5. Select Seeders > Add Line Seeder add line seeder iconin the menu.
  6. Select Height Above Surface and input a height of 3 m.
  7. Click Add Points on Viewport and draw the line seeder by left-clicking along the mountain ridge.
  8. Click Done once done drawing the line seeder.
  9. Click OK to close the dialog.

Line Seeder

For exact coordinates of the line seeder used in this model, open the provided Tutorial 02 Line Seeder.txt file in the Tutorials folder. Alternatively, the .txt file can be saved by right-clicking the link and selecting Save Link As. To import values for a line seeder, first draw a polyline by selecting Geometry > Draw Polyline, and then import the provided .txt file in the Edit Table option. Select the Polyline entity in the Visibility Tree and then convert it into a line seeder by selecting Seeder > Add Line Seeder from Polyline.

4.0 Compute

  1. Click on the Compute Compute icon icon in the toolbar (or select Analysis > Compute icon Compute in the menu).

    5.0 Results

    This model is a great example that showcases the difference between 2D and 3D models. Rock paths are not confined to a 2D plane. Instead, they can curve and tend to congregate at local valleys.


      Rocscience logo, click here to return to the homepage Portal Account Portal Account Log In Log Out Home Shopping Cart icon Click here to search our site Click here to close Learning Tech Support Documentation Info Chevron Delete Back to Top View More" Previous Next PDF File Calendar Location Language Fees Video Click here to visit Rocscience's LinkedIn page Click here to visit Rocscience's YouTube page Click here to visit Rocscience's X page Click here to visit Rocscience's Facebook page Click here to visit Rocscience's Instagram page Click here to visit Rocscience's Reddit page Bookmark Network Scroll down for more Checkmark Download Print Back to top Single User Multiple Users RSLog RocFall3 CPillar Dips EX3 RocFall RocPlane RocSlope3 RocSupport RocTopple RS2 RS3 RSData RSPile Settle3 Slide2 Slide3 SWedge UnWedge RocTunnel RocSlope2 Commercial License Education License Trial License Shop safe & secure Money-back guarantee