L3DT users' community
Large 3D terrain generator

Stitching together the Korean Peninsula

Got a problem or need advice?

Stitching together the Korean Peninsula

Postby KingKenny04 » Wed May 23, 2018 6:03 am

Hi all!

I'm working on a little learning project to investigate whether a combat flight simulator could be made to work in Unreal Engine 4. As part of this, I've been looking at workflows that allow one to generate a map in UE4 based on a real world heightmap. Most of the posts and videos I've seen describing this process recommend using L3DT as part of the workflow. So far I've had good results with the few small test islands I've played with.

My eventual goal is to model the entire Korean Peninsula in UE4, and this is where I am running into trouble. All of the guides and tutorials recommend using http://opentopo.sdsc.edu/raster?opentopoID=OTSRTM.042013.4326.1 for gathering the raw .TIF files to start with. Here is the first issue:

Image

As you can see, there are quite a few gaps in the area I need to generate where there is no data. This becomes a problem when importing to L3DT as the program see the water and the areas with no data as separate, and thus renders the gaps in data in black (which I assume means no elevation) and renders the water in this grey color. The result looks like:

Image

I don't consider this a bug, as the program is most likely behaving exactly as intended. I think my situation is just unique.

What I have tried is selecting and downloading the area I need in chunks, so that I stay inside the areas with data and everything renders in L3DT just fine. My intent was to carefully calculate the lat/long offsets of each "section" of the peninsula and use them to calculate pixel offsets so that I could stitch the areas I need together through merge heightmap. The problem is when I try to input the offsets, I receive errors about invalid coordinates. My guess is this is because the maximum map size is 8192 and stitching these maps together would go over that.

So what are my options? Is there a way to scale and resize these maps so that I can stitch them together? Is there a way to cut out the ocean parts of the original single map so the entire ocean area is black as it should be? Is there another source of heightmaps that don't have gaps in data? Thank you!
KingKenny04
Newbie
 
Posts: 1
Joined: Wed May 23, 2018 5:43 am

Re: Stitching together the Korean Peninsula

Postby Aaron » Mon Jul 02, 2018 2:17 pm

Hi KingKenny04,

I apologise for my really slow reply. I'd hazard a guess that your TIFF files have a 'no data' value that is something large and negative (I think I've seen -9999 used before). L3DT does not, unfortunately, understand 'no data' values, so it interprets those values as being a true height value.

You can clip out these extremely negative height values using the 'Operations→Heightfield→Clip heightfield' menu option. In the 'clip heightfield' window, set the controls to clip heights below, say, -100 to -100 (units = metres). If you would like a different seafloor value, use that instead of -100.

The problem is when I try to input the offsets, I receive errors about invalid coordinates. My guess is this is because the maximum map size is 8192 and stitching these maps together would go over that.


The size limit (in L3DT Pro) is 131072 x 131072 heightfield pixels, so that shouldn't be a problem. Could you please send me the error log from this? (to aaron@bundysoft.com) You can get to the log file using the 'All programs->Bundysoft->L3DT [version]->L3DT logs' shortcut in the Windows start menu. That link will open a directory in which you will find a file called 'log.txt'. With the logfile, I will be able to work out what is going wrong. Please collect the log file after the fault occurs in L3DT, and before re-opening the program, as the log file is overwritten at the start of each session.

Best regards,
Aaron.
User avatar
Aaron
Site Admin
 
Posts: 3665
Joined: Sun Nov 20, 2005 2:41 pm
Location: Melbourne, Australia


Return to Help and support

Who is online

Users browsing this forum: No registered users and 1 guest

cron