Terracopter and Terraformer

3D Model over Monaco combined from ISTAR TrueOrtho™. Copyright © ISTAR 2002 (http://www.istar.com)
Background
Intended audience
Terracopter is a real-time 3D viewer for digital map data. If you have map data that you would like to view in a more realistic way than is possible in traditional 2D applications, Terracopter might be useful for you.
Digital map data
Digital map data comes in many shapes. The most basic type of data is a 2D height field, which is a grid of samples that indicate the elevation above sea level at each point on the ground. This is sometimes referred to as DEM, a Digital Elevation Model.
One way of generating DEM data is by computer analysis of stereo photographs, taken from a plane or from a satellite, or by scanning the ground with a laser beam from the air. The resulting type of data is called DSM.
DSM, or Digital Surface Model, data contains everything and hides nothing. In DSM data of sufficiently high resolution, you can see buildings, trees, and even cars. Well, you can see them in the sense that they will be represented by more or less tiny bumps on the ground - without an aerial photo (and you don't always necessarily have one just because you have DSM elevation data) it might be difficult to determine what they actually are. But they are there. No effort has been made to remove any information or to simplify the data. If you do that, you get a DTM.
DTM, or Digital Terrain Model, is filtered and processed DSM data. The data has been flattened, removing trees and buildings, leaving only the ground. Since there is less sudden variation in elevation, this type of data can be handled by software using less resources than what is the case with the raw DSM data.
Note that the difference between DSM and DTM is purely in the content of the data. Both are represented by two-dimensional grids of elevation samples.
Terracopter supports elevation data only, not vectors or polygon-based buildings. However, Terracopter is powerful enough to use even on high resolution DSM data, which means that it is possible to view unfiltered and unprocessed maps of urban areas with individual buildings clearly visible in 3D.
The Terracopter Vision
Terracopter enables you to fly around in your 3D data in a computer game-like way. The focus is on representing your data as accurately as possible, while using as few hardware and software resources as possible, in order to provide real-time response. The focus is not on providing the most visually pleasing images possible.
When the camera moves, Terracopter reconstructs its polygon-based representation of the terrain on the fly in order to use the available graphics hardware resources where they are needed the most. In practice, this means that a lot of detail (and, therefore, horse-power) is required for the parts of the terrain that are close to the camera, or where there are a lot of sudden changes, such as edges on cliffs or buildings.
By limiting the speed at which you can move the camera, a visually stable and pleasing representation of the terrain could be provided. But Terracopter wants to be a tool you can use to look at your data, not a tool for generating pretty pictures. Therefore, Terracopter does not limit the speed at which you can move the camera. You can zoom out and zoom in again at another spot at lightning speed. When you do this for a large, high resolution area, Terracopter will do its best to keep up with you, but there are cases when you will see the terrain model being reconstructed.
The relationship between Terraformer and Terracopter
In order for Terracopter, which is the 3D viewer, to provide the fastest possible data access, a proprietary database format is used. Terraformer is the import utility you use to convert the mapping data you already own into the format required by Terracopter.
Terraformer
The main Terraformer window looks like this:

Figure 1
You normally work your way from the top of the window to the bottom, filling in the required fields. Much of the lower parts of the window will actually be disabled as long as you haven't provided the necessary information. The workflow is so serial that there are numbered sections in the window. You generally need to complete one section before moving on to the next one.
The available sections are:
- Select project. This is where you decide what project you want to create or edit.
- Locate input data. This is where you tell Terraformer where to find the source data you want to import, and of what type this data is.
- Analyse input data. Pressing this button tells Terraformer to read the input data and to convert parts of it into an intermediate format.
- Select resolution. After having analysed the input data, Terraformer knows what it consists of, and offers you to select which input resolution you want to use. You also get to select the resolution of the generated Terracopter database. This is useful only for reducing the resolution in order to save disk space and to increase 3D viewing performance.
- Edit clutter colours. If you have elected to use clutter (land usage, i.e. terrain type information) as your image source data, the dialog behind this button allows you to select which colours to use.
- Convert input data. Pressing this button creates, after some potentially substantial elaboration, the final Terracopter database.
Working with projects
Everything you do in Terraformer and Terracopter is in the context of a project. A project is what Terracopter loads and displays. You use Terraformer to create these projects.
The directory structure and the Terracopter root
When you install Terracopter, the Setup program creates a directory tree under your PROGRAMFILES directory (c:\Program Files if you have an English-language Windows installation). Part of that tree is where Terraformer will create and Terracopter will look for your projects. The directory is called the Terracopter root directory.
You can not, on a project-by-project basis, decide exactly where to store each individual project. Storing projects in more than one place involves switching the Terracopter root back and forth.
To change the root from Terraformer, press the button to the right of the Terracopter root text box at the very top of the Terracopter window.
Creating a new project
To create a new project, click the button labelled New to the right of the project drop-down list. In the dialog that appears, type the name of the new project and click OK. The name you just entered appears in the project list.
Modifying an existing project
To modify an existing project, just select it in the Project drop-down list. Any settings saved to disk will be read, and the fields of the Terracopter window updated accordingly.
Saving projects
There is no explicit save operation in Terracopter. Project settings are automatically saved to disk, in the corresponding project directory, when the Analyse or the Convert buttons are clicked.
Analysing
As mentioned above, analysing is the process of Terraformer examining the input data to see what it consists of, and to convert it into an intermediate format suitable to further processing.
You need to tell Terracopter what type the data you want to import is, where it is, and how Terracopter should generate texture (i.e. image) data.
Source data type
If you have a valid root directory set and you have selected a project from the list in section 1, you are ready to specify the properties of your source data.
From the drop-down list labelled Source data converter, select the appropriate converter for your source data. In the current release of Terracopter, only Planet-type data is supported, hence there will be only one item to choose from in the list.
The Info button to the right of the Source data converter list brings up a short description of the currently selected converter.
Elevation data
When you have selected a converter in the Source data converter list, the button to the right of the Source height data text box becomes enabled and available. Clicking it brings up a standard Windows directory picker. In this dialog box, select the directory that contains your elevation data.
Image data
When you have specified the location of your elevation data, the check box labelled Use image data becomes enabled. If you check this box, you can specify image data for Terraformer to use.
The term image data refers to the image that gets draped on top of the terrain when viewed in Terracopter. There has to be some sort of image, otherwise Terracopter doesn't have anything to show. The image can be generated in one of three different ways:
- You can import an existing image, such as a satellite photo. To do this, check the Use image data check box and select image from the drop-down list.
- You can let Terraformer generate an image from clutter information. To do this, check the Use image data check box and select clutter from the drop-down list.
- You can let Terraformer generate an image from the elevation data. To do this, uncheck the Use image data check box.
Thus, if all you have is elevation data, you should choose the last alternative. Terraformer then generates a height-coded image, i.e. an image where the colour is a function of the elevation above sea level. This will resemble the appearance of an ordinary 2D printed map.
If you have image or clutter data, select the appropriate item in the drop-down list below the Use image data check box, which should be checked. Then click the button to the right of the Source image data text box, and select the location of your clutter or image data.
Pressing the button
When you press the Analyse button, Terraformer will start to analyse the data you just specified. A progress indicator will pop up, with a Cancel button that allows you to abort the operation.
Depending on the input data you have specified, this process may take some time, probably several minutes, at least.
Converting
When you have analysed your input data, as described in the section Analysing, or when you open a previously created project that has already been put through that process, the fields in section 4 will be enabled and available.
Input resolution filter
Terraformer can only create databases using a specific input resolution. This means that, for source data that consists of multiple resolutions, you must select one resolution at a time, and create separate Terracopter databases if you want to view all input resolution layers.
One common example of a situation where there might exist multi-resolution data is where you have a map of an urban area, surrounded by relatively feature-less rural areas. This data may be packaged as a single map, with a relatively low resolution used for the entire area, and a smaller, higher resolution elevation grid used for the city centre.
Specifying what input resolution to select when building the database is referred to as setting the input resolution filter. You can specify filters independently for elevation and for image data.
In the most common case, there will be only one value to choose from in both the Heights and the Image drop-down lists.
Output resolution
Output resolution refers to the resolution of the Terracopter database that Terraformer creates. You can only reduce the resolution, not increase it (doing that is only possible on television). The only reason you would want to reduce the resolution is if your hardware is not up to the task of handling the size or the I/O demands of the database that results if you use the original resolution.
Note that the actual figures refer to the distance between samples in meters, i.e. higher numerical values mean lower resolution.
Clutter colours
The Clutter colours window is where you map your clutter codes onto the colours they will be represented by when the data is viewed in Terracopter.

Figure 2
The first column consists of the clutter values that Terraformer found when analysing the source data. The second column is the descriptive names associated with the numerical values in the source data. The third column is the colour that has been assigned to that clutter value. The fourth column is a sample of that colour.
If you have specified clutter as the image type to use, you should make sure that all clutter values that Terraformer found in your data are represented by a suitable colour. For clutter values that are left blank, Terraformer will use some unspecified default colour when generating its images. You will definitely want to avoid this.
Pressing the button
When you click the button labelled Convert, a progress indicator will pop up, just as when you clicked Analyse. This time it will take even longer! Remember that you can abort the operation by clicking the Cancel button at any time. If Terraformer doesn't respond immediately, please be patient - it is because is very busy doing its thing. The button click will be handled as soon as possible.
Note that the conversion is sometimes very time consuming. As a rule of thumb, converting a 50 m resulution map with an extent of 1500 km square may take 1 or 2 days(!). Conversion has not yet been optimised, but can definetely be done once we allocate time and resources to do it
When Terracopter has finished converting your project, you are done. A Terracopter project now exists on disk. It is now possible to run Terracopter on this project.
Terracopter
Terracopter is the real-time 3D viewer for your digital terrain data. When you convert a project in Terraformer, the result is a stored in a proprietary format, optimised for fast access, on disk. Before you can do anything else in Terracopter, you need to open one of theses projects.
Working with Projects
From the File menu, select Load project. This brings up the Select project dialog.

Figure 3
Select the project you want to load from the drop-down list. (The last project you worked with in Terracopter will be pre-selected.) When you press OK, Terracopter will load this project and display it in the main area of its window.

Figure 4
You can only have one project at a time open. If you load a project when you already have one open, the first project will be closed.
Navigation
The navigational interface in Terracopter is based on what you find in many popular first-person computer games, such as Quake™, by id software. You use the mouse to look in different directions and the keyboard to move around. However, since the amount of shooting you will have to do in Terracopter is very limited, the left mouse button is used in a different way.
Looking around
To move the camera with the mouse, you need to keep the left mouse button pressed. (In Quake, the camera moves as soon as you move the mouse, and the left mouse button is used to fire the currently selected weapon).
- To look left, move the mouse to the left.
- To look right, move the mouse to the right.
- To look up, move the mouse towards you.
- To look down, move the mouse forward, away from you.
Moving around
Moving he mouse with the left mouse button depressed as described above points the camera in different directions while keeping its position is space constant. The primary means of moving the camera around is by using four keys on the keyboard:
- W (or "arrow-up", if you prefer to use your right hand) means forward.
- S (or "arrow-down") means backward.
- A (or "arrow-left") means left.
- D (or "arrow-right") means right
These four actions are relative to the current camera direction. In addition to this, you can also use:
- U (or numerical keyboard "+") means up, i.e. vertical ascent.
- N (or numerical keyboard "-") means down, i.e. vertical descent.
These two actions are absolute, i.e. independent of the current camera direction.
Continuous forward motion
You can also use the F key to enable continuous forward motion. This is equivalent to holding the W key down.
Height lock
If you tilt the camera forward, looking down at the ground, and then press W (or "arrow-up") to move forward, you will normally move exactly in the direction you are facing, which means that you will descend and move closer and closer to the ground. Sometimes, this is not what you want. It is often useful to be able to move forward at a constant height, while looking down. Pressing H toggles this mode on and off. When the height lock is on, you can still move vertically up and down by using the U and N keys.
Circulating
If you hit the Y key, you can toggle automatic circulation on and off. When this mode is activated, the camera pans continuously around the 360 degrees, on and on until you deactivate the mode by hitting Y again. When this mode is active, you can still look up and down, and even move around.
The C key means almost the same thing, but the panning continues only as long as you hold the key down.
For both the above cases, pressing one of the shift keys reverses the direction of rotation.
Speed
You can control the speed at which the camera moves by pressing the numerical keys located at the top of the keyboard (i.e. not the numerical keyboard), the lowest speed being 1 and the highest speed being 6. The keys 7 through 9 have no effect.
The camera position
Hitting the L key displays the current position of the camera in the status bar. The coordinates are displayed as (x, y, z), and the unit is meters. The x and y coordinates are derived from the real-world extent of the data that was originally imported using Terraformer. The z coordinate is above sea level, not relative to the ground below the camera.
Referencing points on the ground
If you right-click on the terrain with the mouse, Terracopter reports the world coordinates of the clicked position in the status bar. A pop-up menu also appears, with the single item Go here. If you select that menu item, Terracopter positions the camera at the point you clicked. The camera direction remains unchanged.
The menus
The File menu
- File | Load project opens an existing project.
- File | Export lets you save the current view to disk as a BMP file.
- File | Print lets you print the current view.
- File | Exit terminates Terracopter.
The Edit menu
- Edit | Copy copies the current view into the Windows clipboard as BMP (bitmap) data. After having done this, you can paste the resulting image into any application that supports this. You can also access this command from the keyboard by hitting control-c.
- Edit | Setup opens the Setup dialog.
View
- View | Zoom leads to a submenu that lets you choose between camera "objectives", which affects the projection of the terrain on screen - Wide angle lets you see more of the terrain from the given camera position, which is another way of saying that the terrain will appear smaller on screen. Tele lets you see less of the terrain from the given camera position, which is another way of saying that the terrain will appear bigger on screen.
- View | Smooth texturing toggles texture filtering (smoothing) on and off. Turn this mode on for the best visual quality, and turn it off to see individual satellite photo or clutter pixels in an unaffected way.
- View | Toolbar toggles the toolbar on or off.
- View | Status bar toggles the status bar on or off.
- View | Full screen toggles full screen mode on or off. You can also access this mode from the keyboard by hitting control-spacebar. Exit full screen mode by hitting control-spacebar again or by hitting the escape key.
Navigation
- Navigation | Set position brings up the Go to position dialog.
- Navigation | Move to center of area positions the camera in the center of area, some distance up into the air, looking straight down. You can also access this command from the keyboard by hitting the HOME key.
Help
- Help | Quick reference opens a pop-up window with a brief guide to the available keyboard commands.
- Help | About brings up the About Terracopter dialog box. From here, you can access the online Terracopter help if you are connected to the Internet.
The toolbar
From left to right, the buttons on the toolbar are:
- Open the Go to position dialog box.
- Adjust the camera direction, making the camera horizontal.
- Moves camera to the home position (same as the HOME key and the menu item Navigation | Move to center of area).
- Toggle camera acceleration on or off.
The Setup dialog
The Setup dialog box is accessed from the menu item Edit | Setup, and looks like this:

Figure 5
The Root directory is the location where Terracopter looks for projects. This setting is shared with Terraformer, and you can change it from either application. To do this, click the button to the right of the text box.
Checking the At start-up... etc check box enables the three text boxes, one for each dimension (x, y and z), where you can enter the desired start-up position for the camera. Clicking the Use current button fills in the text boxes with the current camera position. This button is only available if a project is loaded.
The meaning of the Reload last project at start-up check box should be pretty clear - if this box is checked, when Terracopter starts up, it will automatically load the project you last had open.
The Accelerated camera check box refers to the speed of the camera when moving around. If this option is not checked, the speed of the camera will remain constant when you hold the navigation buttons depressed on the keyboard. If it is checked, the speed will gradually increase. When you stop, the speed will be reset back to normal. This is a pretty useful feature for quickly moving around, once you get the hang of it.
The Background colour button lets you set the background colour of the main window. The background is the part of the window that is not covered by the terrain of the currently loaded project. Clicking it brings up the standard Windows colour chooser dialog. When you are done selecting a colour in this dialog, click OK.
The selected background colour is saved in the Windows Registry, and will apply the next time you run Terracopter. The setting is global, not per project.
The Go to position dialog
The Go to position dialog lets you position the camera at the specified point in space. The unit is meters.

Figure 6
The Absolute/Relative setting applies to the camera height only. Absolute, as the name implies, means that you specify the exact height at which you want to position the camera. Relative adds the value you specify to the current camera height.