Hi fellow wiki editors!

To help newly registered users get more familiar with the wiki (and maybe older users too) there is now a {{Welcome to the wiki}} template. Have a look at it and feel free to add it to new users discussion pages (and perhaps your own).

I have tried to keep the template short, but meaningful. /Johan G

Difference between revisions of "TerraGear GUI"

From FlightGear wiki
Jump to: navigation, search
m (Requested features: Update)
m (Renamed tabs, known issue)
Line 4: Line 4:
 
| developedby          = Gijs de Rooy (original by Alex Park)
 
| developedby          = Gijs de Rooy (original by Alex Park)
 
| initialrelease        = March 24, 2009 (original)<br>March 27, 2010
 
| initialrelease        = March 24, 2009 (original)<br>March 27, 2010
| latestrelease = 0.8.0 (January 20, 2012)
+
| latestrelease = 0.8.x (January 20, 2012)
 
| writtenin            = C++ (Qt)
 
| writtenin            = C++ (Qt)
 
| os                    = Windows, Linux, Mac OS X
 
| os                    = Windows, Linux, Mac OS X
Line 40: Line 40:
 
Elevation files are optional, but ofcourse required to generate scenery with elevation offsets (even flat countries like the Netherlands need elevation data, since a country isn't 100% at sealevel. Unpack the downloaded elevation file(s) in <tt>{project's directory}/data/SRTM-30</tt>.
 
Elevation files are optional, but ofcourse required to generate scenery with elevation offsets (even flat countries like the Netherlands need elevation data, since a country isn't 100% at sealevel. Unpack the downloaded elevation file(s) in <tt>{project's directory}/data/SRTM-30</tt>.
  
=== HGT chop ===
+
=== Elevation ===
 
This will convert the .hgt.zip files you have downloaded earlier on and converts them into a form that TerraGear can read. Simply select the directory in which you placed the elevation downloads. Make sure you do set the correct resolution! For the USA this can be 1 arcsec, while the rest of the world is provided in 3 arcsec resolution.
 
This will convert the .hgt.zip files you have downloaded earlier on and converts them into a form that TerraGear can read. Simply select the directory in which you placed the elevation downloads. Make sure you do set the correct resolution! For the USA this can be 1 arcsec, while the rest of the world is provided in 3 arcsec resolution.
  
=== Genapts ===
+
=== Airports ===
 
What is scenery without airports in a flight simulator? If your tile does not contain any airports, you can skip this part and continue with [[#ogr-decode|ogr-decode]].
 
What is scenery without airports in a flight simulator? If your tile does not contain any airports, you can skip this part and continue with [[#ogr-decode|ogr-decode]].
  
Line 54: Line 54:
 
If you check the checkbox to "Process all airports", the tool will run through the entire apt.dat file, which can take a long (!) time when using the default apt.dat from FlightGear.
 
If you check the checkbox to "Process all airports", the tool will run through the entire apt.dat file, which can take a long (!) time when using the default apt.dat from FlightGear.
  
=== OGR Decode ===
+
=== Materials ===
 
Now we need to decode the shapefiles into TerraGear format, which we do with OGR Decode. After clicking the "Retrieve shapefiles" button, the list will be populated with the shapefiles from your project's data directory. The GUI will try to assign fitting materials. IF a shapefile has no material, you'll need to assign it by hand. Each single shapefile must have a material.
 
Now we need to decode the shapefiles into TerraGear format, which we do with OGR Decode. After clicking the "Retrieve shapefiles" button, the list will be populated with the shapefiles from your project's data directory. The GUI will try to assign fitting materials. IF a shapefile has no material, you'll need to assign it by hand. Each single shapefile must have a material.
  
Line 61: Line 61:
 
Line width is only used on line-data (like roads, rivers and railroads). If you leave the line width fields empty, a default width of 10 meters is used.
 
Line width is only used on line-data (like roads, rivers and railroads). If you leave the line width fields empty, a default width of 10 meters is used.
  
=== FGFS Construct ===
+
=== Construct ===
 
'''Note: with recent TerraGear builds, it is required to add the used material-names to the default_priorities.txt file.'''
 
'''Note: with recent TerraGear builds, it is required to add the used material-names to the default_priorities.txt file.'''
  
Line 81: Line 81:
 
* Automatic downloading and unzipping of data.
 
* Automatic downloading and unzipping of data.
 
* Visual map for boundary selection.
 
* Visual map for boundary selection.
 +
* Unlimited process time (currently 30 seconds per tile).
  
== External links ==
+
== External link ==
 
* [http://www.flightgear.org/forums/viewtopic.php?f=5&t=7485 Forum topic]
 
* [http://www.flightgear.org/forums/viewtopic.php?f=5&t=7485 Forum topic]
  
 
[[Category:Scenery enhancement]]
 
[[Category:Scenery enhancement]]
 
[[Category:Software]]
 
[[Category:Software]]

Revision as of 10:51, 2 March 2012

TerraGear GUI
TerraGearGUI.png
Developed by Gijs de Rooy (original by Alex Park)
Initial release March 24, 2009 (original)
March 27, 2010
Latest release 0.8.x (January 20, 2012)
Written in C++ (Qt)
OS Windows, Linux, Mac OS X
Website


The GUI tool for TerraGear allows people to create scenery for FlightGear without using commandlines.

Obtaining the GUI

You can either build the GUI from source, or download a pre-compiled build:

Please note that you need to download/compile TerraGear as well.

For GNU/Linux users

  1. Grab the sources and store it where you want:
    git clone git://gitorious.org/terragear-addons/terrageargui.git
  2. Then go in the source:
    cd terrageargui
  3. Create a build dir:
    mkdir build && cd build
  4. Now build it:
    qmake .. && make
  5. You can now start it with:
    ./TerraGUI

You're done!

Using the GUI

The GUI exist of several tabs. For normal scenery creation, all the tabs should be gone through in the order they are arranged.

Start

  1. Set the TerraGear directory, in which you'll find ogr-decode, fgfs-construct etc. TerraGear must be downloaded/build seperatly from the GUI!
  2. Set the project's directory. In this directory, all project related stuff will be stored throughout the process. You best choose an empty directory specific to your project.
  3. Set your FlightGear's root ($FG_ROOT). This is used to retrieve the list of available terrain materials.

Downloading data

Specify boundaries in the boxes on the left and select a source to download shapefiles for that area. Note that OpenStreetMap only includes line date (roads, rivers), so you'll need some polygon data for the actual terrain. Both Custom Scenery and CORINE (only Europe) provide that.

Alternatively you can download shapefiles from the mapserver by hand. Unpack the downloaded file(s) to your {project's directory}/data/.

Elevation files are optional, but ofcourse required to generate scenery with elevation offsets (even flat countries like the Netherlands need elevation data, since a country isn't 100% at sealevel. Unpack the downloaded elevation file(s) in {project's directory}/data/SRTM-30.

Elevation

This will convert the .hgt.zip files you have downloaded earlier on and converts them into a form that TerraGear can read. Simply select the directory in which you placed the elevation downloads. Make sure you do set the correct resolution! For the USA this can be 1 arcsec, while the rest of the world is provided in 3 arcsec resolution.

Airports

What is scenery without airports in a flight simulator? If your tile does not contain any airports, you can skip this part and continue with ogr-decode.

You can do two things now:

  • Already-made airports: Locate FlightGears apt.dat.gz file, which is usually in $FG ROOT/Airports/ in the just created directory.
  • Home-made airports: if you created an airport in TaxiDraw, just use the .dat file that you exported.

Use the button to browse to the .dat file of your choice. If you only want to create the scenery for a specific airport you can enter the ICAO name into the relevant field. By default, only airports within the specified boundaries will be processed.

If you check the checkbox to "Process all airports", the tool will run through the entire apt.dat file, which can take a long (!) time when using the default apt.dat from FlightGear.

Materials

Now we need to decode the shapefiles into TerraGear format, which we do with OGR Decode. After clicking the "Retrieve shapefiles" button, the list will be populated with the shapefiles from your project's data directory. The GUI will try to assign fitting materials. IF a shapefile has no material, you'll need to assign it by hand. Each single shapefile must have a material.

You can delete shapefiles from the list by double-clicking on them. A single click on a material will allow you to edit it; to create custom materials that are not (yet) in materials.xml (do note that FlightGear will apply the default material to those landclasses, untill you create the material in materials.xml!).

Line width is only used on line-data (like roads, rivers and railroads). If you leave the line width fields empty, a default width of 10 meters is used.

Construct

Note: with recent TerraGear builds, it is required to add the used material-names to the default_priorities.txt file.

The fgfs-construct tool brings all your gathered data together, throws it in a washing machine and spits it out the otherside in a format ready for use with FlightGear. Click the "Update list" button to populate the field with all decoded shapefiles. In the list you select all types that you'd like to include in your scenery.

After clicking the "Generate scenery" button, it may take a long time for TerraGear to finish. Depending on the size of the area you are creating the scenery for and the level of detail in your shapefiles. Simple and small sceneries will take a couple of minutes, where larger, more detailed areas can take over an hour! So trying new things on small areas first will save you a lot of time.

Running the scenery

The folders and files in your project's output/ directory are ready to use as scenery. You can set the scenery path of FlightGear to this directory to check if the scenery is generated correctly.

Note: If you generated airports, you must copy the [ICAO].btg.gz file(s) from {project's directory}/work/AirportObj/ to the corresponding directories in {project's directory}/output/Terrain.

GUI development

The current source code can be retrieved from Gitorious.

Feel free to add feature requests and/or bug reports to this page. Anyone interested in helping is invited to contact Gijs at the forum.

Requested features

  • Automatic downloading and unzipping of data.
  • Visual map for boundary selection.
  • Unlimited process time (currently 30 seconds per tile).

External link