
File : README.WIN32.txt

This is a native WIN32 port of Atlas/Map.

BUILDING

To build with Microsoft Visual C/C++ load and allow conversion of the
Atlas.dsw file to the version being used. Note, although these are MSVC6
not all components, notably SimGear can be built with this OLD version,
but all later versions MSVC7.1 (2002), MSVC8 (2005), MSVC9 (2008), and
perhaps subsequent have no problems.

There may exist an old Atlas.sln, and other old vcproj files, but these
may be out of date, and need some fixes. The recommended build files are :-
Atlas.dsw - atlas-win.dsp, Atlas.dsp, GetMap.dsp. Map.dsp, MapPS.dsp

The prerequisite libraries, and path are all established relative to this
'build/msvc' path in the Altas root folder. If you have built these prerequisite
items in other places, then the include directories, and additional library
directories will need to be adjusted.

Below is the current include and additional library directories, and
libraries included. The GetMap project additionally requires the 'curl'
library, bu this project can be EXCLUDED if you just want to run Atlas/Map with
FlightGear. Also the MapPS project has not been tested during this build.

For native WIN32 this folder also includes the source of a static atlas-win.lib,
to provide some functions, and other utilities, missing in the native
RUNTIME libraries.

This project is compiled using the 'Multi-threaded DLL' (/MD) runtime, and
/MDd for Debug, and all the prerequisites MUST be compiled with the SAME runtime,
else you will get copious warnings, or even errors on the LINKS ...

Release Atlas/Map Include Directories
.
..\..\..
..\..\..\zlib-1.2.3
..\..\..\SimGear
..\..\..\lpng
..\..\..\OpenSceneGraph\include
..\..\..\freeglut\include
..\..\..\jpeg-6b

And for GetMap
.
..\..\..\curl\include

Atlas/Map Release Linker List:
ws2_32.lib
sg.lib pui.lib ul.lib fnt.lib net.lib puAux.lib
SimGear.lib
libpng.lib
zlib.lib
libjpeg.lib

with Library paths
..\..\..\lpng
..\..\..\zlib-1.2.3
..\..\..\PLIB
..\..\..\SimGear\Release
..\..\..\freeglut\ReleaseStatic
..\..\..\jpeg-6b\lib

And for GetMap
ws2_32.lib
Wldap32.lib
Winmm.lib
Lib_curl.lib

with library paths
..\..\..\curl\build\Release

RUNNING

 - GetMap

 GetMap is not really part of the Atlas/Map combination, and only shows how
 maps (in jpeg format) can be fetched from Web Map Servers (WMS). There
 is a testgm.bat batch file, using the NASA WMS to retrieve maps of the
 San Francisco area.

 This is really only of interest to compare with the maps generated from the
 FlightGear world data set.

- Map

There is a testmap.bat file, with paths set relative to this folder, and
assuming you have added the FG base data to ..\..\..\data. It you have
used other path arrangments then testmap.bat USER VARIABLES will need to be
adjusted. The test will only output ONE specific PNG file.

But map can be run in like an auto-mode, where it will generate maps for
ALL the necessary areas that exist in the FG scenery data you point it at.
Be aware, if you have done the massive download, and unpack of _ALL_ the
FG world data, then Map will take a day or more to generate all the maps!

But running map first to generate the map is not really required, since, Atlas,
if given runtime access the map.exe, will proceed to automaitically generate
all teh required maps. Again, care should be taken to what data path you pass to
Atlas, because again, if it is the 'whole world' then Atlas will spend all
day running map.exe, generating the maps, one by one ...

- Altas

There is a testatlas.bat file, with paths set ralative to this folder, and
assumes you have also added at least the FG base data to ..\..\..\data
If you have used other paths, then testatlas.bat USER VARIABLES need to
be adjusted accordingly. The test is centered on San Francisco, KSFO.

You must supply a directory, either empty or where you want the generated
maps to be placed. Some put this in their FG data folder, under scenery,
but it can be anywhere.

As mentioned above, map.exe does not need to be run first to generate maps
for Atlas to use, but you must supply a folder for this test. 
(a) Atlas works without maps anyway, but the display is a little less 
    interesting, but airports, navaids, etc are shown;
(b) if given the path the the map.exe, or map.exe is copied to a path in
    your PATH environment variable, then Atlas will generate it own maps,
    but you MUST create the folder to hold these maps, with a sub-directory
    called 'lowres', if you want low resolution maps to also be generated.
 But take care - if you pass Atals a whoe world of FG data, then Atlas will
 merrily spend all day generating maps.

When Atlas is running, and usually after it has finished generating any
maps, using map.exe, it is time to run FlightGear. The only extra
command that needs to be added to flightgear is :-

 --atlas=socket,out,5,localhost,5500,udp

This command will cause FG to output 'Atlas' data on port 5500 5 times a
second. This is more than sufficient, to 'feed' Atlas with the aircraft
information. This data is about 160 bytes long, of the form -

$GPRMC,200843,A,3736.813,N,12221.435,W,000.0,297.9,1701109,0.000,E*58
$GPGGA,200843,3736.813,N,12221.435,W,1,,,04,F,,,,*0A
$PATLA,111.70,280.0,111.70,280.0,0*54

Those of you with GPS instruments will recognise this dat form. The data
is read, and decoded to form 'track' data. WHen this data is received
by Atlas, press an 'f' key to select the first track, and you should see
Atlas, or moving map perform ...

Note, while FG is starting up, it will output 20 or more 'blanks', like
$GPRMC,200838,A,0000.000,N,00000.000,E,000.0,000.0,1701109,0.000,E*48
$GPGGA,200838,0000.000,N,00000.000,E,1,,,00,F,,,,*1B
$PATLA,111.70,280.0,111.70,280.0,0*54
Note the latitude and longitude is ZERO, Atlas has learned to try to
'ignore' these packets.

Happy moving map ;=))

Geoff.
January, 2009

EOF - README.WIN32.txt
