• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

W.I.P. Tool for creating Elevation using Rectangles

Are you interested in a tool for processing DEMs into Elevation Rectangles?


  • Total voters
    36
Hello again. I managed to create a georeferenced tiff from the lidar LAS file with WGS84 CS. I followed the instructions by the dev, but running into issues when I try to open the XML up in the scenery editor. Process in the app says it created 9 rectangles, but when I open the XML in the sim, I get the following error message. I also opened the XML with notepad and do see all the points written to it. I feel I'm doing something wrong ... perhaps a tiny setting somewhere. Have you or anyone else run into this before?

Thank you!


image.png
Strange, never had this issue. Did you pick the right XML file, the one for the scenery? Not the Meta-Xml in the folder above?
 
Hey everyone, sorry for being absent on replies for so long. I had to deal with the declining health of my dad the past months who fortunately and miraculously made a full recovery. Unfortunately it meant I haven't really been active on anything FS related for that time but seeing everyone's replies and suggestions in the notifications and my email got me back into looking at my FS projects.

So right now I have started working a version 0.2 of the tool which should address some issues and add extra features to the tool as well as streamline the entire process. So for that I need your input as to what are some of the features your are missing or would like to have included in the tool (no promises of course, I have to be able to actually implement said features).

@peacefarm Can you maybe share your tiff and xml files with me if possible (in private message)? I can try and take a look at your issues that way.

@salud Thank you very much for the kind comments and providing some information to others while I didn't reply, I really appreciate it!

For the no data values, my original goal was to see if I can create a more exact representation of the provided DEM raster file. SO if there are areas without data, the rectangles would just generate around said values. Another approach I might look into is to do some kind of floodfill or dilation algorithm to fill in the no data values based on surrounding pixels. Similar methods are accessible in spatial tools like QGIS.

Additionally, I'm looking into providing better interpolation algorithms compared to the current ones, allowing users to select their preferred method and choosing performance over quality etc.

Lastly, I also want users to be able to edit existing rectangles in their projects, so they don't have to edit the XML files manually. Right now I suggest creating a single project specifically for elevation so the tool doesn't accidently create an erroneous FS project XML.

Those are some of the features that are currently in development, but feel free to make suggestions as I really appreciate all feedback!
 
How about the option to create a new named XML. I currently use this for a new XML template:
XML:
<?xml version="1.0" encoding="utf-8"?>
<FSData version="9.0">

</FSData>
Using this as the 'save' XML works perfectly. But you could just create the file, rather than insert code to an already created file. (Glad your Dad is better).
 
Hello again! @FoxtrotScenery thank you for the reply. I've sent you a PM with the files.

All is well here minus the large deep cuts along the perimeter of the TIFF. Any ideas to correct this would be greatly appreciated!

1704947726936.png
 
Hello again! @FoxtrotScenery thank you for the reply. I've sent you a PM with the files.

All is well here minus the large deep cuts along the perimeter of the TIFF. Any ideas to correct this would be greatly appreciated!

View attachment 91078
I had this issue once, when I extracted the GeoTIFF from another one that was actually smaller, as I had set the boundaries incorrectly to go slightly beyond the data in the GeoTIFF, resulting in large negative elevations where there was no data.
 
I had this issue once, when I extracted the GeoTIFF from another one that was actually smaller, as I had set the boundaries incorrectly to go slightly beyond the data in the GeoTIFF, resulting in large negative elevations where there was no data.

Thanks for the reply. I'm happy to report that aside from the edge glitch, .5 meter Lidar data is a go! I'll be happy to share my workflow as soon as I fully get it down (and understand it!).

I've had to process the LAS data points through Arcgis Pro to create a raster and then QGIS to export a functioning raster. I'm sure this is a botched way of doing it, but for now it kind of works. This type of stuff is certainly not my forte! :)

Anyways, would you mind expanding a bit on the "setting the boundaries" part? I have a feeling we're so close here!

This is what it looks like in QGIS (I use Bing maps for reference):

1704956198321.png
 
The image above has caught my attention. I am looking at the black line which I believe represents a river? Do you think your tool may be able to assist in water detection?
 
Hi
The image above has caught my attention. I am looking at the black line which I believe represents a river? Do you think your tool may be able to assist in water detection?
Hi, yes that is a river, however I don't know if the tool is capable of isolating bodies of water. It's solid black because it is the lowest elevation point in the data. Hopefully someone with GIS experience can expand.
 
Hey,

first of all, thank you for spending your time and creating this tool, it is really needed.


Recently I was trying to use the tool but ran into an issue I couldn't fix. Every time I try to create an elevation, I end up with this error you see below.

Screenshot 2024-01-12 224127.png


Maybe you, or anyone around here can help me with this. ;)

Thank you!
Vincent
 
Hey,

first of all, thank you for spending your time and creating this tool, it is really needed.


Recently I was trying to use the tool but ran into an issue I couldn't fix. Every time I try to create an elevation, I end up with this error you see below.

View attachment 91088

Maybe you, or anyone around here can help me with this. ;)

Thank you!
Vincent

Hello Vincent,

Maybe you have the same issue I did. I ran into this issue as well even with data that was supposed to be based on WGS84. What seems to work for me is to import the TIFF into QGIS via LAYER--->ADD LAYER--->ADD RASTER LAYER. Then, right click on the layer (near bottom left) and export. The following settings seem to work for me:

GOOD LUCK!
Screenshot_7.png
 
Hello Vincent,

Maybe you have the same issue I did. I ran into this issue as well even with data that was supposed to be based on WGS84. What seems to work for me is to import the TIFF into QGIS via LAYER--->ADD LAYER--->ADD RASTER LAYER. Then, right click on the layer (near bottom left) and export. The following settings seem to work for me:

GOOD LUCK!
View attachment 91090
Hey,

thanks for the reply. Unfortunately the error persists and the tool still can't generate rectangle objects. I also get an exclamation mark in QGIS when selecting WGS84 as the CRS that isn't present in your image.

This is what my export looks like

Screenshot 2024-01-13 111535.png


Thanks again for the help!
Vincent
 
Hey,

thanks for the reply. Unfortunately the error persists and the tool still can't generate rectangle objects. I also get an exclamation mark in QGIS when selecting WGS84 as the CRS that isn't present in your image.

This is what my export looks like



Thanks again for the help!
Vincent
This is because you have not re-projected your source DEM file.
 
This is because you have not re-projected your source DEM file.
Thanks! That was the problem. I do however still struggle with the tool. Even with the now corrected DEM file it doesn't generate the rectangle objects.
 
I had a problem. The egm2008-2_5.pgm file had it's data erased somehow. The file existed, but had 0 bytes. I recopied the file from the zip to the Resources folder, ran the program, and it worked.
 
Thanks for the reply. I'm happy to report that aside from the edge glitch, .5 meter Lidar data is a go! I'll be happy to share my workflow as soon as I fully get it down (and understand it!).

I've had to process the LAS data points through Arcgis Pro to create a raster and then QGIS to export a functioning raster. I'm sure this is a botched way of doing it, but for now it kind of works. This type of stuff is certainly not my forte! :)

Anyways, would you mind expanding a bit on the "setting the boundaries" part? I have a feeling we're so close here!
In my book you are pioneering the field of Lidar2Raster conversion, so I will not call it a botched way for sure. :)

Sorry for my short hiatus, but to give you some background on the "setting the boundaries" part, here is an image:
qgis-layer.jpg

So my mistake in the beginning was that I exported the above layer, but setting the extent to "Current Layer Extent" rather than Map Canvas Extent". You can do both, but in the white area with no data, I ended up with large negative values. Not sure this is the same issue you have, probably it isn't, but I thought I'd share nonetheless.
 
Awesome tool! I just tried using it.

Imported the .TIF files I needed to use into QGIS (unfortunately the airport I am building falls in the cross section of 4 DTM tiles, as provided by the UK agency DEFRA. Didn't apply any transformation upon import, but made sure to make the Output CRS source in the Raster > Reproject to WGS-84. Exported all 4 tiles individually and put them through the tool.

The program did take a considerable amount of time to export to the XML, mainly because the tiles I used as my source are so damn big! The resolution of these tiles is 1m, so I ended up with a .xml of 11gb! Seemed a bit large, but I can understand given how big the area is I'm making the mesh for.

I will post some comparison photos on here when I get the chance!
 
In my book you are pioneering the field of Lidar2Raster conversion, so I will not call it a botched way for sure. :)

Sorry for my short hiatus, but to give you some background on the "setting the boundaries" part, here is an image:
View attachment 91105
So my mistake in the beginning was that I exported the above layer, but setting the extent to "Current Layer Extent" rather than Map Canvas Extent". You can do both, but in the white area with no data, I ended up with large negative values. Not sure this is the same issue you have, probably it isn't, but I thought I'd share nonetheless.

Sorry for the slow reply, but finally back on the saddle. Thank you very much for explaining this! I'll see if this fixes it on my next project. For now, I used a few "strips" of polygons to fill the craters to the core of the earth up. :)

I've sent you a DM to further discuss this and not hijack the thread.
 
The image above has caught my attention. I am looking at the black line which I believe represents a river? Do you think your tool may be able to assist in water detection?
Though interesting, I think that's not on the radar for now or the foreseeable future. I'd like to add more powerful tools to this tool, but for this I cannot find the required literature to implement such a feature unfortunately.

Recently I was trying to use the tool but ran into an issue I couldn't fix. Every time I try to create an elevation, I end up with this error you see below.
Feel free to send me a DM so I can see if I can help you further. Any issues are best solved if I have access to some of the files to see if I can reproduce the problem locally.

I had a problem. The egm2008-2_5.pgm file had it's data erased somehow. The file existed, but had 0 bytes. I recopied the file from the zip to the Resources folder, ran the program, and it worked.
Now that's an interesting issue I didn't ever expect to come across:rotfl:Has this happened multiple times, or have you any idea which steps were taken when the issue occured?

The program did take a considerable amount of time to export to the XML, mainly because the tiles I used as my source are so damn big! The resolution of these tiles is 1m, so I ended up with a .xml of 11gb! Seemed a bit large, but I can understand given how big the area is I'm making the mesh for.

I will post some comparison photos on here when I get the chance!
Thanks for trying out the tool, looking forward to seeing some of the results. How did compiling with the FSPackagetool go with that amount of data out of curiosity?

Since the tool currently keeps the full precision floating point result, it's going to take a lot of space since there is no way to compress the data like with an actual raster file. Would truncating the result be acceptable, say to 4-6 decimal numbers, or do people prefer to keep the full floating point precision?

Other than that, I've now updated a GitHub repo to track issues with the tool. If you have any issues that you don't want to discuss here or over DM, feel free to use the repositories. I am going to (try to) keep track of all issues mentioned here in the git repo as well, so I will not miss any issues that need to be fixed.

For now I am keeping the tool's source code closed, since this is a project to really practice my programming skills with GIS and .NET. Down the line I might open it up to other contributors anyway!
 
Hello thank's for helping every body with tool.
I certanly miss something here, I convert my Dem with Qgis in WGS 84 and remove null value, I get those rectangle but they act more like flattening the area, shoulden't model the terrain like in the Dem.
1705549839067.jpeg
 
Back
Top