Skip to content

Creating Topology

Introduction

Two models are used for storing vector data:

  • Spaghetti model - the simplest model
  • Topology model - a more advanced model

In the spaghetti model, there are no special points indicating where lines begin and end, or where they intersect. There is no information indicating which lines logically belong together. The lines cross each other like in a pile of spaghetti.

With a technique called topology, you can describe how objects are positioned in relation to other objects, and how they are connected. This technique uses the concepts of lines (links) and nodes.

What is topology?

Topology in practice means that lines are split at all nodes and possibly connected so they hang together (removing loose ends). The same line should also not be stored multiple times (duplicate lines).

Automatic Topology Cleanup

Gemini Terrain has a dedicated function for automatic topology cleanup of lines. You can find this in the context menu when you have selected two or more lines.

Automatic topology cleanup Automatic topology cleanup

Note

All objects that are not lines in the active application layer are automatically removed from the selection. The program displays an error message if fewer than two lines remain in the selection.

The function contains the following topology functions that are important for constructing data for SOSI delivery for zoning plans, FKB, and NVDB:

  1. Remove loops
  2. Split lines at intersection points and connect loose ends (XY)
  3. Connect heights for endpoints (Z)
  4. Remove duplicate lines
  5. Merge lines between node points

Tip

You can perform these operations manually as described in the chapter Editing data in application layers. However, to automate the editing, you can use this function to perform multiple operations on multiple lines simultaneously.

Remove Loops

This option removes loops in lines as shown in the examples below.

Example of loop removal

Examples of loop removal. Loops on the left, cleaned topology on the right

Info

A variant of example two, which can be difficult to find visually, is where the line goes back to the previous point and then forward again to the same point.

Split Lines at Intersection Points and Connect Loose Ends (XY)

Warning

For this process, you must specify a search radius. This should not be too large. Too large a value can lead to the introduction of new errors. You should therefore inspect the data beforehand to determine what value to set.

Examples of Splitting and Connecting

The examples below are split and connected in plan view (XY) as shown:

Splitting lines at intersection points

Example where lines that cross each other in plan view are split and connected

Connecting loose ends

Example where lines that don't meet in plan view are within the search radius, and are therefore extended, split, and connected.

Example that is not split

Example where lines that don't meet are outside the search radius, and remain unchanged.

Handling Heights at Intersection Points

What happens to the line heights at the intersection point? In most cases, the lines will not intersect exactly in height.

Lines crossing each other in 3D

Left: Lines crossing each other in 2D. Right: In 3D you can see that the lines don't cross exactly in height.

The program interpolates the height for each line at the intersection point. This means that the new lines after splitting have different heights.

Lines after height interpolation

Left: Lines crossing each other at intersection point in 2D. Right: In 3D the lines have different heights at the intersection point.

Connect Heights for Endpoints (Z)

Warning

For this process, you must specify a search radius. This should not be too large. Too large a value can lead to the introduction of new errors. You should therefore inspect the data beforehand to determine what value to set.

Meeting lines (two or more lines with the same coordinates in northing and easting) are connected in height (Z) at the endpoints based on the height of the point in the first entered line (lowest ID) in the application layer.

Example of Connecting Heights

Lines with different heights at endpoint

The illustration shows two lines meeting at a point where they have the same coordinates in northing and easting, but different heights.

Lines after height connection

If the height difference is within the specified search radius, the height at the common point is set to the height of the first entered line (here ID 1).

Remove Duplicate Lines

For this process, a tolerance (max. deviation) is specified for when the program perceives lines as identical. You set this in the dialog Gemini Terrain Settings... - Project - General.

Limitation

The function has the following limitation: The lines must have the same number of elements and they must be in the same order (for example line - arc - line).

Examples of Removing Duplicate Lines

Duplicate lines that can be removed

Example 1: The two lines contain the same number of elements and are within tolerance. Duplicate line is removed.

But not these:

Duplicate lines that cannot be removed directly

Example 2: The two lines do not contain the same number of elements, but are within tolerance. Duplicate line is not removed.

Duplicate lines that cannot be removed directly

Example 3: The two lines contain the same number of elements, but are outside tolerance. Duplicate line is not removed.

Tip

If you first run the process Split lines at intersection points and connect loose ends, you can solve the problem with examples 2 and 3. The examples will then first be split and then duplicate lines will be removed as in example 1.

Merge Lines Between Node Points

For this process, a tolerance (max. deviation) is specified for when the program perceives points as identical. You set this in the dialog Gemini Terrain Settings... - Project - General.

This process merges lines between node points as shown in the example below. By default, the function only merges objects with identical properties, meaning all fields must have exactly the same values.

Tip

You can turn off the requirement for identical properties so that lines with different property values can also be merged.

Example of Merging Lines

Lines before merging

Lines before merging

Lines after merging

Lines after merging

Info

This is especially useful if you later want to create parallels to these lines. You also avoid getting warnings in SOSI control if these lines are merged.