PDA

View Full Version : Using DEM data



Al40k
December 20th, 2006, 07:17 AM
Is there a way to use DEM data to create the terrain of a route in Trainz 2004?

Alex

geophil
December 20th, 2006, 07:30 AM
Yes, certainly. Search the forums for HOG, MapMaker or TransDEM. TransDEM is payware, the others are free.

geophil

Al40k
December 20th, 2006, 08:18 AM
Thanks for the quick reply. A search for HOG doesn't bring any results but MapMaker does!

Alex

geophil
December 20th, 2006, 08:37 AM
There is a problem with the search function. Try "Hand of God" instead, with quotes.

geophil

Al40k
December 20th, 2006, 09:19 AM
Thank you!

kozowh
December 20th, 2006, 04:35 PM
On several maps on the DLS, only the terrain appears on a bare grid. The author indicates that HOG textures are required. I went to trainz.luvr.net as suggested but only found the hog.exe program for creating terrain.

Any idea how to find the HOG textures?

-Walt

geophil
December 20th, 2006, 04:38 PM
The texture set is part of the HOG download, included in the package.

geophil

Dermmy
December 20th, 2006, 04:38 PM
All the links you need to download all necessary programs and find all required data to use HOG are contained in Wewain's excellent tutorial located at http://freepages.misc.rootsweb.com/~wewain/trainz/Surveyor/Baseboard/Topology/TerrainGeneration/Computer-generatedTerrain.htm

Andy

kozowh
December 20th, 2006, 08:21 PM
geophil & Dermmy --

Thanks for the replies. However, I'm not sure how to procedure. I haven[t digested the HOG tutorial completely as yet; it seems that in order to get the *.gnd file you have to have created the map yourself using HOG. What about maps that you've downloaded with DLS? Do they have a *.gnd somewhere that I haven't found yet?

Or, am I completely missing the whole concept of this process?

Thanks, in advance. -Walt

Dermmy
December 21st, 2006, 01:32 AM
@ kozowh: See the ninth post in this thread http://forums.auran.com/trainz/showthread.php?t=1550

MYTrain
December 21st, 2006, 08:41 AM
Does anyone know where to download MicroDEM. It seems that the Navy site is not good anymore and all the Googles only give you the Navy site.

kozowh
December 21st, 2006, 10:29 AM
Dermmy--

Thanks for the guidance. Seems to be working although in some maps the textures don't show up in the minimap. Also, is there a color convention for the features? It seems the shorelines are blue, surface streets are red, highways are orange, tracks are blue-gray (I'm a little colorblind). Is that about right?

Thanks again. -Walt

geophil
December 21st, 2006, 10:33 AM
@MYTrain:

http://www.usna.edu/Users/oceano/pguth/website/microdem.htm
works for me.

geophil

probe
December 21st, 2006, 10:54 AM
Can I suggest you consider purchasing TransDEM. It is a superb programme with excellent tutorials and easy to use. Money well spent and you also get free upgrades

JB

MYTrain
December 21st, 2006, 04:39 PM
geophil,

Works for me too, but only at work. Home will not connect. Most strange.

Best regards,

MYTrain

StorkNest
December 22nd, 2006, 12:02 AM
Dermmy--

Thanks for the guidance. Seems to be working although in some maps the textures don't show up in the minimap. Also, is there a color convention for the features? It seems the shorelines are blue, surface streets are red, highways are orange, tracks are blue-gray (I'm a little colorblind). Is that about right?

Thanks again. -Walt

Try the link Dermmy posted in his second post here, posts about color code there.

Dermmy
December 22nd, 2006, 12:18 AM
Thanks StorkNest. I tried to put a DEM/HOG post in 'FAQs Tips and Tweaks' - possibly the reason that page is entirely bereft of contributions is that it is entirely inaccessible to mere mortals such as ourselves....

Andy :)

RPearson
December 22nd, 2006, 08:55 PM
Dermmy--

Thanks for the guidance. Seems to be working although in some maps the textures don't show up in the minimap. Also, is there a color convention for the features? It seems the shorelines are blue, surface streets are red, highways are orange, tracks are blue-gray (I'm a little colorblind). Is that about right?

Thanks again. -WaltThe colors displayed are usually the default colors that MicroDem uses for the various features. Most people don't make any changes to these. The TIGER format itself doesn't specify any colors for the line data. If you have MD installed you can see what the defaults are and which features it will display. A number of post in the old forums had complete listings of these.

To see what they are in MD, select options -> Vector maps -> TIGER. To see what the color actually is from the TIGER Overlay options click on a feature color and then the color button and then define custom color button. The rgb value for the current color is displayed. On the overlay options dialog you can change the color, line width and even deselect any TIGER features you don't want MD to displayed. HOG assumes railroads are cyan (rgb 0,255,255) so most leave the defaults alone.

The more common lines and the rgb color code are:

political boundaries 0,0,0
railroads 0,255,255
major road 255,0,0
road level 2 190,0,0
road level 3 160,0,0
water level 1 0,0,255
water level 2 0,0,128

Bob Pearson

StorkNest
August 24th, 2008, 08:52 PM
Using this thread, I opened some DEMs in MicroDEM but there are these 2 rulers, one for distance and one for elevation, I cannot seem to get rid of them. Is there a way to remove them?

mawilson
August 25th, 2008, 08:07 AM
Right click on the map. Select Legends. Uncheck everything.

StorkNest
August 25th, 2008, 01:47 PM
Thanks that worked perfectly.

Now I'm looking for the following information, been searching through other topics but some information appears sketchy.
1 - How to merge the USGS quads available from either http://data.geocomm.com/ or http://www.mapmart.com/ together. I have a few I believe 30M quads from the first and 10M from the second. Tried looking through the MicroDEM help file but the methods listed show using features either grayed out or not available, one method went from step 5 straight to step 8!:eek: Areas I'm looking to merge are not huge.
Areas A and B contains 3 quads each.
Area C has 4.
Area D has 6, maybe 7.
2 - What format to download seamless data in from http://seamless.usgs.gov/ and what folder to put it in. Latest MicroDEM has in the \mapdata folder a \DEMs folder (seperate from \usgsdata) and under \mapdata\usgsdata there are folders for \DEM-NED, \NED-NINTH, \NED-THIRD, \SRTM-1 and \SRTM-3. I want to try this mthod to see any differences in results.

StorkNest
August 25th, 2008, 11:05 PM
After more fiddling, it appears I have to do any merges when I first open MicroDEM before opening anything in it. The IN <-> OUT button only works then, once I open something, it grays out and is unusable until next time I start the program.
Managed to merge Areas A and B fine. Area C merged but it looks like there are rectangular gaps between two of the quads I'll have to figure how to fill that.
Area D with 6 quads isn't merging well, 2 quads are giving trouble and will not add on to the merge. I tried redownloading them from MapMart instead of Geocomm, same thing. The finished merge with quads lettered is supposed to be a sideways P like this:
ABCD
__EF
B and C are the problems, when I run the merge either selecting multiple DEMs at once or singly, I get this message.

1660289.DEM.SDTS.TAR.gz meters z range: -1.1 to 97.8 m UTM zone=18 NAS-C Level 2 Horizontal spacing: 10
1705847.DEM.SDTS.TAR.gz meters z range: 0 to 80.1 m UTM zone=18 NAR-C Level 2 Horizontal spacing: 10
Incorrect datum; not included in merge
1705869.DEM.SDTS.TAR.gz meters z range: 0 to 106.4 m UTM zone=18 NAS-C Level 2 Horizontal spacing: 10
1706056.DEM.SDTS.TAR.gz meters z range: 23.6 to 174.8 m UTM zone=18 NAS-C Level 2 Horizontal spacing: 10
1706105.DEM.SDTS.TAR.gz meters z range: 5.8 to 169.6 m UTM zone=18 NAR-C Level 2 Horizontal spacing: 10
Incorrect datum; not included in merge
3683230.DEM.SDTS.TAR.gz meters z range: 0 to 384 m UTM zone=18 NAS-C Level 2 Horizontal spacing: 10
Merge: 4 with: 4252 cols, 2796 rows

Ones in red are the problems. How do I fix Incorrect Datum?
Thanks in advance.

geophil
August 26th, 2008, 01:58 AM
You will probably have to convert those DEM files with the wrong datum first. NAD27 instead of NAD83 I would suspect. MicroDEM should have a function to accomplish this.

But - why don't you simply define your individual DEM in Seamless Server and download it in one rush?

StorkNest
August 26th, 2008, 11:05 AM
Seamless I'm still trying to understand:
1 - Whether I should get SRTM or NED or something else.
2 - What folder it goes into.
See my item 2 three posts above this one.
Thanks for the info, those two are NAD83 while the others are NAD27.

ADDITION: Seems I figured out the seamless data, got downloads to work (I think).
Now I cannot get the TIGER lines to show in MicroDEM. I am having the same problem as the poster of this topic:
http://forums.auran.com/trainz/showthread.php?t=24142&highlight=TIGER
I did the correct method that Balkoth listed in the fourth post but after it looks like it processed the TIGER data, nothing shows on the image. I have the correct county data from Geocomm, I downloaded the zip file and saved it to C:\mapdata\tiger without changing the name. Did I miss some step such as renaming the folder or placing it in the C:\mapdata\tiger a certain way?

FURTHER ADDITION: Nevermind, I didn't have the right sub-folder setup in C:\mapdata\tiger, I just used the main TIGER folder. Fixed.

StorkNest
August 27th, 2008, 09:52 PM
I think I have this figured out. Got the 4 DEMs done and they show in TRS2004.

My only issue is 2 have more boards than I want due to how they were made (no way around having those extra boards). Is it normal to find yourself deleting baseboards from finished DEMs before releasing them? The GND files are pretty big as is.

JCitron
August 27th, 2008, 11:11 PM
Dermmy--

Thanks for the guidance. Seems to be working although in some maps the textures don't show up in the minimap. Also, is there a color convention for the features? It seems the shorelines are blue, surface streets are red, highways are orange, tracks are blue-gray (I'm a little colorblind). Is that about right?

Thanks again. -Walt

That's about right. Power lines are really dark red just to let you know. One of the things that I find helpful is to view the area if you can, from an aerial photo to get an idea what else goes in the area besides the tracks, roads, and water.

John

StorkNest
September 3rd, 2008, 10:39 PM
I have successfully made some DEMs, still have a couple of questions.

1 - Has anyone ever modified the Tiger file data image when changing it from BMP to TGA? Sometimes I get things like rail lines showing as black, red or a darker shade of teal. So I was wondering if it is fine for HOG if you modify the Tiger image.

2 - Have you ever cut an image into seperate parts? Say you have a large area and you want to split it into 2 or more so HOG will make more than one GND file, then you save them as seperate DEMs to be merged. Or you get a section of seamless data with rail lines you don't want so you modify the image by cutting them out. Is that fine?

Thanks.

geophil
September 4th, 2008, 03:17 AM
1 - Has anyone ever modified the Tiger file data image when changing it from BMP to TGA? Sometimes I get things like rail lines showing as black, red or a darker shade of teal. So I was wondering if it is fine for HOG if you modify the Tiger image.

The way HOG works, it maps an input colour value to a ground texture. One of the files delivered in the HOG package defines the colour-to-texture mapping. This mapping will only succeed if your TGA image contains the colour values HOG expects - to the very last bit.


2 - Have you ever cut an image into seperate parts? Say you have a large area and you want to split it into 2 or more so HOG will make more than one GND file, then you save them as seperate DEMs to be merged. Or you get a section of seamless data with rail lines you don't want so you modify the image by cutting them out. Is that fine?

HOG does not know anything about geographic coordinates, it simply relies on images, one for the DEM, one for the map. These two images must exactly match each other for each module to be built.

You can create multiple modules but you are completely in charge of providing the proper grid. You have to cut your DEM and your map image files at the correct positions, multiples of 72 pixels (one baseboard), plus margin overlap.

I have never tried this myself, preferring the automatic way, but I can't see any reason why you should not be able to create modules for seamless merge by hand.

Vern
September 4th, 2008, 07:00 AM
I did try in the early days using HOG to create a succession of sub-sections which were joined into the whole. However despite careful contour tracing and shading, they never did quite match at the join, requiring considerable work on the edges to match up the heights.

Transdem on the other hand (shameless plug for you, Roland) avoids that and does so much more into the bargain. I can thoroughly recommend the slight financial outlay as a very sound investment if you are interested in geographically accurate routes.

Tokkyu40
September 4th, 2008, 07:20 AM
If you follow the color code exactly you can add or remove rail lines on the Tiger image. I use 2 pixel lines to match the original and draw the new track wherever I need it.
I've used that to recreate tracks that have been gone long before the USGS started collecting Tiger data.

:cool: Claude

cgwright
September 4th, 2008, 07:24 AM
Might I join Probe and Vern in recommending TransDEM? It will do everything you want, at a very reasonable price.

I followed the tutorial blindly, with no previous knowledge, and had everything done in half an hour.

Regards
Chris