ogxp_tools dependencies

The ogxp_tools require the following packages to be installed prior to running. I also recommend installation in this order if doing a fresh installation of these packages.

Python 2.7   Python

ogxp_tools were developed under Python 2.7.5 through 2.7.9. They have not been tested on Python 3.0 or greater.

Within Python 2.7 versions, >= 2.7.9 is recommended as important Tkinter fixes are implemented and pip is included in the package.

https://www.python.org/downloads/

NumPy and SciPy

NumPy: Numerical Python   NumPy

SciPy: Scientific Library for Python   SciPy

ogxp_tools were developed to run under NumPy >= 1.8! Performance under NumPy < 1.8 versions for some ogxp_tools operations will be hugely slower. When I say slower I mean OM.

Be sure to install SciPy as well.

http://www.scipy.org/scipylib/download.html

Complete GDAL, GEOS, PROJ, SQLite frameworks   gdal

ogxp_tools requires GDAL >= 1.10 PLUS the complete GEOS, PROJ, and SQLite frameworks. The tools will fail without these additional frameworks.

For Mac OS I recommend the excellent convenience installer from William Kyngesburye at:

http://www.kyngchaos.com/software/frameworks#gdal_complete

This includes GDAL 1.11 together with GEOS, PROJ, and SQLite frameworks making it unnecessary to install these individually.

For Windows some options include:

http://www.lfd.uci.edu/~gohlke/pythonlibs/#gdal

pip install GDAL-1.11.2-cp27-none-win32.whl

OSGeo4W project

http://trac.osgeo.org/osgeo4w/

ImageMagick   Image Magick

ImageMagick is used for the majority of ogxp_tools image processing tasks.

http://www.imagemagick.org/script/binary-releases.php

Python Shapefile Library (pyshp)

ogxp_tools make extensive use of the excellent pyshp library.

https://github.com/GeospatialPython/pyshp

http://geospatialpython.com/

Installation is simple for both Mac OS and Windows with pip:

pip install shapefile

gdal_fillnodata.py

ogxp_tools requires gdal_fillnodata.py with the -srcnodata argument option. Unfortunately, many GDAL installations do not install the version of gdal_fillnodata.py with this option.

The version of gdal_fillnodata.py that works with ogxp_tools is included as part of the ogxp_tools download.

To ensure that ogxp_tools has access to the correct version, move the supplied gdal_fillnodata.py into the appropriate location in your GDAL installation. Backup your existing gdal_fillnodata.py or simply overwrite.

gdal_edit.py

Similarly, some gdal_edit.py versions do not have the -a_nodata argument for assigning a null data value to a dataset. A version with this option is included with ogxp_tools.

DSFTool with elevation range input

The DSFTool required by ogxp_tools (and supplied with the ogxp_tools.zip download) is a modified version of DSFTool that has added support for minimum and maximum elevation range clamping. As X-Plane stores coordinate information as Integer with a scaling factor, clamping the elevation range close to the DEM minimum and maximum allows for sub-meter Z precision. This is important for smooth rolling runways where a spline surface has been applied.

The DSFTool available from http://developer.x-plane.com/tools/xptools/ can only output vertex Z as whole integer meters. ogxp_basemesh.py will NOT work with the DSFTool from http://developer.x-plane.com/tools/xptools/.

NOTE:

You can use this modified DSFTool outside of ogxp_tools.

For sub-meter Z precision add minimum and maximum elevation integer arguments (see help screen below). If elevation delta between minimum and maximum elevation is less than 1000m subtract 500 from minimum argument and add 500 to maximum argument (prevents occasional vertex sink error in DSFTool).

Simply leave off the min and max elevation arguments to output whole meter Z values (the default behavior in the DSFTool from http://developer.x-plane.com/tools/xptools/).

Usage: dsftool --dsf2text [dsffile] [textfile]
   dsftool --text2dsf [textfile] [dsffile]

For submeter Z precision add miniumum and maximum elevation range of DSF:

   dsftool --text2dsf [textfile] [dsffile] [integer min_elev] [integer max_elev]
   dsftool --env2overlay [envfile] [dsffile]
   dsftool --version

Please note: dsftool still supports single-hyphen (-dsf2text) syntax for backward compatibility.

MeshTool 3 without shapefile simplification

MeshTool 3.0 Beta 1 from http://developer.x-plane.com/tools/meshtool/ creates v10 terrain land classes. This is great for having your custom sceneries blend seamlessly with the default v10 Global Scenery.

One big change from MeshTool 2, however, is the introduction of shapefile node simplification. The impact of this on custom coastlines (or other shapefiles added as mesh contours) is very pronounced.

Let’s take a look at the difference in outputs between MeshTool 2.0 and MeshTool 3.0 Beta 1. The input shapefiles are identical.

Comparing MeshTool 2.0 and MeshTool 3.0 Beta 1

As you can see, the coastline in the DSF produced by MeshTool 3.0 Beta 1 is very generalized (in pink). Much of the coastline detail present in the source shapefile has been lost. The DSF created by MeshTool 2.1 (in blue), meanwhile, retains the detail present in the source shapefile.

Since I am very much interested in having BOTH v10 land classes AND retaining the full detail present in my custom coastlines and other shapefile contours, the version of MeshTool 3.0 supplied with ogxp_tools is a recompile with the shapefile simplification switched OFF.

In other words, the shapefile behavior is as per MeshTool 2.1 but with v10 land classes.

NOTE:

If you wish to use the MeshTool 3.0 Beta 1 from http://developer.x-plane.com/tools/meshtool/, no problem. Just replace the MeshTool_3 file in your ogxp_tools directory with the MeshTool 3.0 Beta 1 executable (renaming to MeshTool_3 or MeshTool_3.exe as appropriate for your OS).

QGIS   QGIS

QGIS is NOT required for ogxp_tools. But I highly recommend it as a powerful and intuitive multi-platform GIS with excellent functionality for both raster and vector data. And it is Open Source.

And for Mac OS there really isn’t any other choice unless you run a Windows GIS package in a VM.

I use QGIS for setting up a ogxp scenery project and visualizing all the inputs. I can load orthoimagery, high res DEMs, load and edit coastlines, building footprints, runways, etc. and save everything in a QGIS project.

Binaries for Mac OS, Windows and Linux are available at:
http://www.qgis.org