Creating terrain heightmaps

  • coxo2436

    most people would like to have a simple cookbook, a video, a point and click interface in order to get what they want. Life should be simple. This is what marketing tells us. However the flightsim world does not work like this. You need to spend some time with reading and understanding how scenery is built in Aerofly FS2. This starts with the image of the world, the orthofotos which lay on a terrain mesh and ends with the cultivation of that image with houses, trees, lights, airports and other scenery. Believe me there will sooner or later be questions but hopefully clear questions and not general questions like how do I make scenery. Most of them have been answered already but it is not so easy to find them. People here are willing to help but more if they feel that someone has spent some time with the topic and has a basic understanding.


    For AeroScenery there is a good guide available here.

    Please also read the quite long thread in this subforum here about AeroScenery.


    Information about the Aerofly Cultivation/Scenery Editor is here.


    To create a simple airport for your scenery check FSCloudPort.


    Don't forget the wiki where you will also find some tutorial videos.


    And then if you have a question: first look where it should be placed, in which subforum (there are only three). Then open a new thread with a title that clearly explains the topic (this will help other members with the same problem to find it later).


    It is fun to bring life into Aerofly FS2 and creating personal sceneries but it will not happen over night and some time is needed in order to get familiar with it.

    Best regards,

    Thomas


    i7-6700K @ 4.0 GHz, Geforce GTX 1080, 32MB RAM, 500 GB SSD, 1 TB SSD, 1TB HD, 32" Monitor 4K, Oculus Rift

  • I was thinking of another cook book tutorial for AeroScenery as my "Cultivation the simple way" has been so well received.


    If there is any interest then I will have a go.


    Kindest regards to all, Michael.

    Not intended to discourage you but, keep in mind that AeroScenery is being upgraded at this time. There is an existing "how to" out there already for the existing beta version.


    Regards,

    Ray

  • Hi again Thomas


    I've given Norway a go and obtained a healthy-looking set of TTH files for a 20x20 km area covering Bergen Airport. Many thanks for your guidance!


    I haven't got any scenery yet to test them with, but while I'm waiting for that I have a few questions/observations .....


    (1) I got 4 TIFs covering that area - and I noticed that their co-ordinates overlap. You talk about merging them, but I didn't have any success doing that using "raster > miscellaneous > merge". The merging appeared to work and the geoconversion went ahead but the TTH files were all masked and about 2 kB each - so obviously no good. I must have been doing something wrong there.


    (2) So instead I just did "layer > add layer > add raster layer" for each separate TIF, saving each one in the format you suggested and putting them all in the "input_aerial_images" folder along with the 4 corresponding TFW files.


    (3) At the "save" stage in QGIS I noticed that the horizontal and vertical resolutions were different - and also different for each TIF. In the TFW file one of the resolutions is positive and one is negative. Which is supposed to be negative - the horizontal or the vertical? (I guessed and made the vertical negative.)


    Given the guesswork above and the fact that the TIFs were overlapping I wonder whether my TTH files are really OK. We shall see!


    Cheers


    Ian

  • Hi Ray,


    Thanks for your comments. Yes I too have seen the "how to" and found it confusing and of very little help when starting from scratch.


    I realise Nick is hard at work updating his AeroScenery which we are all looking forward to when it happens.


    I will hold off for the moment.


    Kindest Regards,


    Michael.

  • Please people i mean no offence to anyone I DO really appreciate the efforts of the developer of this program... i really do it is a fantastic thing that he has made it available to everyone to be able to "dress UP" AFF2S i would like to point out that i am old and find it very confusing to to find my way around forums and using the correct protocols "forums , threads,topics, sub topics, sub forums , etc ,etc.

    it took me 2 days to work out how to post a pic in the forms sorry sub forum ,(or was that topic um sub topic???)

    i dont even know how to do a search for a reply that i received

    regard to all

    coxo2436

  • I've given Norway a go and obtained a healthy-looking set of TTH files for a 20x20 km area covering Bergen Airport. Many thanks for your guidance!

    It would be interesting to check at what distance the highest compilation level of your mesh gets actually loaded and displayed in AFS2 while in-flight (i.e. comming from far away).


    Remember, you might have floating cultivation if it loads from a further distance than the mesh.


    Cheers

    Antoine

    Config : i7 6900K - 20MB currently set at 4.00GHz, Cooling Noctua NH-U14S, Motherboard ASUS Rampage V Extreme U3.1, RAM HyperX Savage Black Edition 16GB DDR4 3000 MHz, Graphic Card Gigabyte GeForce GTX 1080 8GB, Power supply Corsair RM Series 850W, Windows 10 64 bit.

  • Hi Ian,

    let me start with your negative number question.


    This is the proper assignment for a tfw (here a location in the US).

    The 4th entry from the top always must be negative (vertical resolution)

    11781-hc-2434-tfw-jpg


    Regarding the masking of tth files:

    They are generated even if masking is switched off in the tmc file.

    Please try to define the 4 coordinates of the TMC entry aligned to the AFS2 raster to suppress the generation of mask files.

    Antoine has a lot of knowledge how to choose these.


    See also vogel69 Grid Generator https://flight-sim.org/filebas…/127-afs2-grid-generator/



    Cheers,

    Thomas

  • And yes, that's the y resolution (vertical). Don't ask me where it comes from, it's an IPACS convention. Otherwise you can flip the image vertically.


    Cheers

    Antoine

    Config : i7 6900K - 20MB currently set at 4.00GHz, Cooling Noctua NH-U14S, Motherboard ASUS Rampage V Extreme U3.1, RAM HyperX Savage Black Edition 16GB DDR4 3000 MHz, Graphic Card Gigabyte GeForce GTX 1080 8GB, Power supply Corsair RM Series 850W, Windows 10 64 bit.

  • Thanks TomSimMuc and Trespassers - luckily I guessed right re the vertical resolution! I'm not too worried about the masked TTH tiles at the moment because I only intend to fly within my high res region, and I'll just extend it if I want to go further afield. The problem with my initial attempt was that all the TTH tiles (levels 12, 13 & 14) were masked - which can't be right for a 20 x 20 km area. On my second more successful attempt I got a mix of masked and unmasked files, which I was expecting.


    I'm still somewhat disconcerted by the fact that the 4 TIFs I've received overlap and don't form a perfect square, although I downloaded a perfect square. Either I must have received more data than I requested or less - preferably the former! If there are gaps around the edges of the square I requested it could be a problem if a want to download an adjacent square later. (I kept a record the co-ordinates in metres of the square, so I know what I've already got. It doesn't seem to be possible to download a square by specifying lon-lat co-ordinates.)


    Anyway I'll report back when I have the scenery as well


    Cheers


    Ian

  • OK - I've created some scenery to go with my high res terrain mesh in Norway - and the results are very mixed. I've certainly got high res areas - probably 1 metre resolution - judging from the piles of gravel modelled, the flatness of small lakes, the knobbliness of hills, etc. Unfortunately, however, there are also numerous faults in the mesh pretty randomly distributed - in the form of vertical cliffs, trenches and walls where there shouldn't be any. These are in the middle of the high res area - not at the boundary where you would expect to see these faults.


    I've tried removing all the masked files and that doesn't make any difference. (I wouldn't expect it to anyway, except at the outer boundary.) The only thing I can think of is that I should have merged the TIFs before geoconverting as TomSimMuc suggested. I wonder what I was doing wrong when I tried to merge them the first time? TomSimMuc : You said that you "loaded the relevant TIFF files into QGIS". I'm not quite sure what that means. I selected them all from the relevant directory when I merged them - but I didn't "load" them prior to that. Maybe I should have saved them in the correct format before merging them (using layer > add layer > add raster layer)? I will have to experiment. The other thing that puzzles me about merging them is that I will end up putting one pair of figures for resolution in the TFW file when the 4 unmerged TIFs have 4 slightly different resolutions. How critical are the resolution values? What part do they play in the geoconversion?


    UPDATE: SUCCESS! I had another go at merging the TIFs before saving and geoconverting and it worked this time. I swear I did the same as last time - but I guess I must have done something different. I ended up with a perfectly square composite image, which is reassuring. All the faults in the mesh seem to have disappeared, except at one point I did notice a few very deep potholes in a short line across a stretch of hillside. I guess these would be examples of the spikes (albeit inverted) that you mentioned Antoine? I'm not seeing any floating cultivation. It's difficult to judge at what distance the high res detail kicks in. I'm not noticing that it suddenly "snaps" into view - though I have noticed that some more distant hills have suddenly snapped in. I'm not sure whether that's related to the high res mesh or not. All in all I'm very pleased now. The scenery of this part of Norway really benefits from the higher res because the hills are very rocky and have lots of fine detail - as does the rocky shoreline. I'll try to take some screenshots when I get the time.


    Cheers


    Ian

  • Hello Ian,

    congratulations that you made it.

    Is there anything that I should change or add to my tutorial to make it easier for future followers?


    Regarding popping up mountains:

    Be aware, that AFS2 only contains elevation data between +-60 deg. So Bergen is north of this and therefor own elevation data must be created.

    However in that case you do not have any base layer elevation data for level 7 and 10.

    So be sure to also generate these levels for your elevation. Of cause these may be masked, if you can not deliver elevation data for such a huge area.


    Cheers,

    Thomas

  • Hello Thomas


    I'd forgotten about the lack of terrain mesh at 60 deg plus. That would explain why I can see distant mountains to the south of the airport, but not to the north! I'll fill in the lower level TTH files from 7 upwards as you suggest.


    Regarding the tutorial, there were just 2 things that puzzled me:


    (1) The merging of the separate TIFs that one receives from Høydedata. I did "raster > miscellaneous > merge" which is pretty much what you said. I think it was the fact that you talked about "loading" them that confused me, because I thought that was a step that you had to do before you merge them.


    (2) The fact that there are 2 different resolutions - horizontal and vertical - and it is the vertical one which is negative in the TFW file.


    I've attached a screenshot taken a little to the west of Bergen airport. There's no point in posting a comparison shot for the default terrain because, as you say, there is none. The scenery looks a bit like the "limestone pavement" scenery in northern England - but I think the underlying rock is much harder.


    Cheers


    Ian



  • hi Ian

    the good news is i have managed to do a nice cape flattery very simmilar to your demo pic

    the bad news is a cant get my head around the scenproc image detection

    the you tube video tutorial appears to be quite dates (2013 i think) and he assumes that everyone knows how to write code.

    he doesnt supply a .spc file tou use.

    i tried copying his example to make my own .spc file but i keep getting errors that i wouldnt have a clue how to fix

    ps i hope i am in the right thread,topic,sub thread,or subtopic

  • Hi Chris


    Well done re Cape Flattery!


    Since this thread is about terrain heightmaps I will send a direct message to you about ScenProc.


    Cheers


    Ian

  • where is the scproc thread topic I CANT FIND IT

    You can find several with a “scenproc” search.

  • Hello Thomas


    I'd forgotten about the lack of terrain mesh at 60 deg plus. That would explain why I can see distant mountains to the south of the airport, but not to the north! I'll fill in the lower level TTH files from 7 upwards as you suggest.

    Congrats Ian, it looks good.


    In such places where there is no (or poor) underlying default scenery you’ll notice even Level 9 only loads at quite short range in front of your aircraft in AFS2, thus a lower level like 7 is necessary for distant scenery.


    Level 7 tiles are huge, of course you let geoconverter create a mask for missing areas, but keep in mind that areas you don’t cover beyond N60 deg will remain flat...


    Cheers

    Antoine

    Config : i7 6900K - 20MB currently set at 4.00GHz, Cooling Noctua NH-U14S, Motherboard ASUS Rampage V Extreme U3.1, RAM HyperX Savage Black Edition 16GB DDR4 3000 MHz, Graphic Card Gigabyte GeForce GTX 1080 8GB, Power supply Corsair RM Series 850W, Windows 10 64 bit.

  • Hi Antoine - and thanks


    Yes - I have occasionally noticed that hills and mountains are suddenly appearing out of nowhere in the middle distance.


    I've found that it takes about 10 GB of 1metre data to cover a level 9 tile area. This is a manageable amount of data, so I can snap to level 9 and avoid masked tiles in levels 9-14. However I would need about 16x that amount to cover a level 7 area. There appears to be lower res data available on the Høydedata data site so I was thinking that I could maybe cover the country in level 7 tiles using lower res data. (I haven't tried it yet.) There's still going to be a problem if I go anywhere near Sweden though!


    Cheers


    Ian