Sign in to follow this  
Guest

New SRTM to BGL v1.04

Recommended Posts

Just uploaded v1.04 of SRTM to BGL to the libraryhttp://library.avsim.net/esearch.php?CatID...02sd&DLID=31670Various minor bug fixes and enhancements including :-1) Option to set negative data to either "null" (-32767) or 02) Fixed CellXDimensionDeg/CellyDimensionDeg for 1 arc second data3) Fixed CellXDimensionDeg/CellyDimensionDeg for 3 arc second data4) Increased maximum interpolation passes to 1005) Changed default LOD to 10 for 1 arc second dataThanks to Rhumbaflappy, Rafaelds & others for your suggestions.Rafaelds, sorry still haven't implemented your "background" data suggestion just yet, will do next version.Matthew.

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Hi Matthew,first of all many thanks for your program, that allowed me to produce great looking mesh terrain.I have two questions for you:1) Just downloaded the new release, I cannot find the syntax for the new parameter, can you explain it?2) I downloaded srtm data from seamless.usgs.gov, in BIL format, which is similar to HGT, but the interpolation program seems to not like it, and just does nothing. The format is little endian, whith null data represented by -32767. can you work on it?CiaoFrancesco Romeo

Share this post


Link to post
Share on other sites

Hi MatthewSorry to bother you again, but... did you change the interpolation algorythm? With 1.03, 20 passes closed all my holes. But now it barely changes things.The negativevalue option does not seem to work as expected (at least as I expected :) ). It should not mess with void values, which should be always left as a flag for missing data, -32767 in our case and regardless of user options, but only raise "real" negative values that happen near the sea in SRTM (there's a hole 80m deep for me). And this 'raising' is the one that should be disable-able in command line, for places like the Netherlands and Death Valley.Thanks for your attentionRafael

Share this post


Link to post
Share on other sites

There are three options for negative elevations, option 2 (set to null) is the default option :-1) Set to zero (but excluding nulls (-32767)) SRTM_3ARCSEC_TO_BGL InterpolateNegatives=Zero2) Set to null (-32767) SRTM_3ARCSEC_TO_BGL InterpolateNegatives=Null3) Or leave unchanged SRTM_3ARCSEC_TO_BGL InterpolateNegatives=If you try option 1, how does that work for you? Should be ok.Matthew

Share this post


Link to post
Share on other sites

Bad news, guys.Just did some testing and it seems the "NullCellValue" function in Resample 1.1 is non-working. IE.: Resample won't consider these cells as null even if specified. Fs2002's Resample (version 1.2) has this fixed, but it has the 'disadvantage' of producing compressed BGLs directy from resample, not allowing the user to produce different areas to cover a non-square region, merging smaller TMFs.Another new finding: the flag for void areas in SRTM is -32768, not -32767.I did a quick test with a SRTM chunk with lots of voids and GTOPO30 filling the areas, using resample only (without interpolation). It looks bizarre: GTOPO30 has way too bad data to merge with SRTM.Now, SRTMinterpolate: the new version has definitely some problems. With 1.03, 20 passes would fill all holes easily. Now, 100 passes will do only some effect in some places and, strangely, some voids are ignored or almost this. The function to raise elevations is raising even the voids together, also. This function should be that last thing done in the interpolator and the algorythm could be as simple as this:DO GET VALUE_IN IF VALUE_IN<0 AND VALUE_IN>-32678 THEN VALUE_OUT=0 ELSE VALUE_OUT=VALUE_IN PUT VALUE_OUTLOOP WHILE NOT ENDOFFILENotice that voids and values at or above sea level are output untouched. If water starts to appear inland, there's a failure in interpolation, which could be using void values in the calculations.Matthew, if you still like the idea of using other data to fill the voids, you will have to use FS2002 Resample. The only needed changes are that resample will directly produce a BGL from the base file name specified in the INF, no need for compress, merge and erase temporaries.

Share this post


Link to post
Share on other sites

Thanks! Are you interested in testing my builds directly, so that we can work through these issues together?Then after testing is ok, I'll upload to AVSIM.If so let me know. My email is in the README.TXTAnyone else who wants to do some beta testing of the next build... let me know via emailCheers,Matthew.

Share this post


Link to post
Share on other sites

>I did a quick test with a SRTM chunk with lots of voids and GTOPO30>filling the areas, using resample only (without interpolation). >It looks bizarre: GTOPO30 has way too bad data to merge with SRTM.Unfortunately, some SRTM data is "way too bad data" not to merge with other data. :( One alternative is to use interpolation to fill the small holes and fall back to the default mesh for the larger ones (see below). http://forums.avsim.com/user_files/15770.jpg>the "NullCellValue" function in Resample 1.1 is non-working.>IE.: Resample won't consider these cells as null even if specified.The advantage of this "bug" is the fact that mesh for LOD quadrants with missing data is still created (with the holes). [table width=525][tr][td width=275" valign="top]>Fs2002's Resample (version 1.2)>has this fixedNow, an area as small as 4 adjacent "missing" values will leave the containing LOD quadrant empty. If Matthew had started with the new version he may have produced little or no mesh and gone no further with his project!It may be possible to take advantage of this, but I believe it would be a challenge to do so by writing code, and I suspect that you are correct in saying that simply relying on Resample to merge the data effectively is unsatisfactory. [/td][td align=right" valign="top]http://forums.avsim.com/user_files/15768.jpg[/td][/tr][/table]Have you tried using interpolation to fill the smaller holes and then creating the bgl with the newer Resample, without merging the GTOPO30 data. This should create "transparent" areas in the bgl only where there were large areas of missing data; these would be filled by the default mesh. Bounded by cliffs in some areas.A related approach I may try, using Microdem, is to create a rectangle of missing data and then merge the edited DEM with GTOPO30 data. There will still be some cliffs along the boundaries between sources, but these will now be straight lines, which can easily be smoothed by interpolation since I now have all the data in one file. (I have been smoothing the borders between merged 10m and 30m dems for some time now, but haven't done so with this data yet.)I am filling the smaller holes by interpolation, which seem reasonable. A lot of the SRTM data is not too bad so I'm not sure that filling these smaller spaces with GTOPO30 data would be worth the additional effort. Steve

Share this post


Link to post
Share on other sites

I had just discovered that resample 1.2 does not produce LOD quadrants that contain missing data. Here's a pic of the place I am representing, first using raw SRTM data:http://forums.avsim.com/user_files/15830.jpgBut if you look closely, Resample fails in locating some void areas and still represents them:http://forums.avsim.com/user_files/15831.jpgAnd here's a pic of the are using the 'raise elevations' option of Matthew's program (which right now just raises all negatives, including voids). It's interesting because it shows all data, with or without voids.http://forums.avsim.com/user_files/15832.jpgThe most interesting thing in the 'new' resample, IMO, is the fact that it does not produce water in the places that have no data. This makes it possible for one to just choose the SRTM chunks which are of interest and create the BGL without worring if the adjacent areas are messed.

Share this post


Link to post
Share on other sites

Just found that the problem with the interpolator is only with the raise elevations option.With Negatives=Null it works exactly like the previous version.

Share this post


Link to post
Share on other sites

Hello MatthewSince your work is great (MMM - Matthews Mesh Maker), i have an idea to get better results for the intertpolation. As i don't know, how you really create this kind of interpolated .hgt -files, but the result is something 'terrasing', not yet ideal for large holes. As an approach to get something smoother interpolation in hole areas of the mesh - like Microdem - in your greatfull batch-compatible programm, i give you an idea, how height's can be calculated for each missing point.i attached a small virus-free Excel (2000) file, where you, and all others may see the idea to get a good interpolation, whithout terasses effects.The principal idea behind is:calculating for each missing height the average height respectively to its distance to the neighbour elevation data, in x and y axis -direction.May this concept get some better results, the question is how to include such a formula into your program?Kind regardsFrancis

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this