• 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.

FSX editing mesh

Hi Roby:

Interesting project at a beautiful location ! :cool:

http://toolserver.org/~geohack/geoh...11_04_S_169_40_12_W_type:airport_region:US-AS

Perhaps after confirming correctness of geo-rectification for both aerial imagery and terrain mesh, and once both data sources are converted to GeoTiff files, if desired, a copy of either file could be fine-tuned for positioning by adjusting the Geo-referencing info in one's GeoTiff.

Probably Arno or Dick would also have a command line routine that does the needed corrections in ex: GDALWARP once you know what coordinate corrections are needed in decimal degrees N, S, E, W that your GeoTiff may need to be "moved".

http://www.fsdeveloper.com/wiki/index.php?title=GeoTIFF_file_creation_with_FwTools


BTW: If you plan to do any subsequent mesh edits for your area of interest via vector flattens, even if one's source data is lower resolution, you may wish to still force FSX SDK Resample (via INF file parameters) to output the terrain mesh at a higher resolution (ex: 9.554687500 Meter aka "10" Meter) / LOD 12 / QMID 14; this would allow more precise resolving / rendering of terrain mesh vertices for elevation posting data points, thereby preventing "aliasing" of intended flatten vertices to lower resolution coordinates. ;)

Hope this helps ! :)

GaryGB
 
Last edited:
Hi,

If you would have the soure images of the photo scenery it would be easy to load them in a gis tool and check which one correlates with other data. But since it is made with fsearthtiles I don't think it will be easy to check which one is correct.
 
Hi,

Yes it is a nice location. Wish I were there in spite of the poor facilities they have.
I do have the photo bmp and the coords of it but as the bmp size is not the same as the mesh size (so to speak) I do not see how I can have them coincide accurately.
 
I would turn that photo into a geotiff in that case. Then you could load the elevation and imagery together in a gis program and see if they correlate well.
 
HI again,

Well, everything points to the photoreal having the correct coords.
That would mean that either something went wrong in the conversion of the SDTS format to Geotiff or that the SDTS coords are incorrect.
Viewing the two mesh files (not the default one) with the tmfviewer, I can see the difference between the two (the one with the corect coordinates is in the background)



Now I would like to find out how to move the new mesh to the correct spot when I know exactly (I can see that in the tmf) how much the difference in lat and long is.

And thanks, Gary, for the link to this interesting site.
 
Roby,

In TmfViewer, move the cursor to a point on one mesh, read the lat/long from the status bar. Move the cursor to the same point on the other mesh and again read the lat/long.

Use the difference to change the coordinates in the .inf.
 
Thanks, George,
In the inf of the mesh? There is no Lat/long info in the meshmaking inf.
If I want to add Lat and long I will have to know the original ones first, don't I?
How can I find those in the geotif?

PS I think that what you suggest is possible for adjusting the phototexture to the mesh but not the other way around.
And if I do it that way, you would be the first one to tell me my scenery is off:D.
 
Last edited:
You already guessed, I suppose.
No, I cannot find any info on how to edit the coordinates of the geotiff.
All I find refers to changing the coordinate format.
 
Hi,

With gdal_translate you can set new coordinates on the geotiff. I'll try to find you an example tonight. That should allow you to shift it.
 
Could this be the correct way?

gdal_edit.py -a_ullr -14.... -169..... -15.... -169... 1005CATD.tif

I dare not try it out without knowing more about it.

(I still have to pinpoint the new coords)
 
Hi Roby:

In the FSDeveloper Wiki I linked to in my post above, there is a nice treatise on this topic using FWTools (a "must-have" along with GDAL, IMHO):

http://www.fsdeveloper.com/wiki/ind...ols#Adding_positional_information_to_an_image

www.fsdeveloper.com/wiki/index.php?title=GeoTIFF_file_creation_with_FwTools#Copying_tags


FYI: "ListGeo.exe" is located in the [FWTools install path]\BIN folder.


FWTools web site: http://fwtools.maptools.org/


PS: Be sure to use complete paths to ones GeoTiffs, as "ListGeo.exe" must stay in its native folder location because other FWTools *.dll files are required for proper function.

Hope this helps ! :)

GaryGB
 
Last edited:
Good morning,

And thanks for everything.
Indeed, with Gdal_translate you can change the coordinates. Now it is only a matter of adjusting the mesh accurately enough to have it coincide completely with the phototexture (something which is not a sinecure:().

Roby
 
Hi Roby.

At some point you may need to decide the data is just bad. If it is mislocated, then it may well be erroneous in content as well. Somebody that originally compiled the data didn't check their work against a known source.

When checked in GlobalMapper, the same mislocation of the file you attached is present. I wouldn't trust the data for being accurate at all. You will probably find it is not only mislocated, but not spatially accurate either.

Dick
 
The elevation data seems off indeed. I compared it with the OpenStreetMap vector data and that also shows that the elevation data is off.

I tend to agree with Dick. If you have to fiddle a lot to get data working, you better trash it in general.
 
Hi,

Thanks for checking. However, it is a nicely detailed mesh compared to the correct one:

southbeachwithnewmesh.jpg


So I am fiddling with the coordinates to "distort" the mesh a bit (you know, like adding .0000005 decimals to the NW long and nothing to the SE etc.
Once I have that correct, I can use the same correction for the other parts of the mesh (of the other island).
 
Hi,

I foound that the ddf/tif conversion was wrong.
The ddf info shows:
C:\Program Files\FWTools2.4.7>gdalinfo 1005CATD.DDF
Driver: SDTS/SDTS Raster
Files: 1005CATD.DDF
Size is 1357, 1390
Coordinate System is:
PROJCS["UTM Zone -2, Northern Hemisphere",
GEOGCS["NAD83",
DATUM["North_American_Datum_1983",
SPHEROID["GRS 1980",6378137,298.257222101,
AUTHORITY["EPSG","7019"]],
TOWGS84[0,0,0,0,0,0,0],
AUTHORITY["EPSG","6269"]],
PRIMEM["Greenwich",0,
AUTHORITY["EPSG","8901"]],
UNIT["degree",0.0174532925199433,
AUTHORITY["EPSG","9108"]],
AUTHORITY["EPSG","4269"]],
PROJECTION["Transverse_Mercator"],
PARAMETER["latitude_of_origin",0],
PARAMETER["central_meridian",-195],
PARAMETER["scale_factor",0.9996],
PARAMETER["false_easting",500000],
PARAMETER["false_northing",0],
UNIT["Meter",1]]
Origin = (634845.000000000000000,8437165.000000000000000)
Pixel Size = (10.000000000000000,-10.000000000000000)
Metadata:
TITLE=MANUA ISLANDS OE W, AS-24000
DATASET_ID=LAT:: -14 15 30.0000 S LONG:: -169 37 30.0000 W SCALE:: 24000
DATA_STRUCTURE=DEM
MAP_DATE=1998
DATASET_CREATION_DATE=2001824
Corner Coordinates:
Upper Left ( 634845.000, 8437165.000) (169d59'14.14"E, 75d58'0.05"N)
Lower Left ( 634845.000, 8423265.000) (169d56'39.61"E, 75d50'33.27"N)
Upper Right ( 648415.000, 8437165.000) (170d29'10.72"E, 75d57'21.28"N)
Lower Right ( 648415.000, 8423265.000) (170d26'20.90"E, 75d49'54.86"N)
Center ( 641630.000, 8430215.000) (170d12'51.33"E, 75d53'57.83"N)
Band 1 Block=1357x1 Type=Float32, ColorInterp=Undefined
NoData Value=-32766
Unit Type: m

C:\Program Files\FWTools2.4.7>gdalinfo 1005CATD.DDF

I changed the a-srs entry to read NAD83 and now the scenery is at the correct location. That is already something.
However, the elevations are still off (like this outcrop that should be 167m but shows as 232m. Furthermore I notice that both ends of the mesh seem to not follow the 'round earth' and I therefore expect there is something more that has to be added. I haven't figured out what yet. Any ideas?

Tks,

Roby
 
Hi Roby,

I tried NAD83 as well yesterday, but I did not see an shift in location.

What do you mean does not follow the earth? Terrain scenery does so by definition. The only thing could be the sea in the data is not correctly zero.
 
Hi Arno,

That is funny because I do.
Attached is my bgl.
Gdalinfo for the converted tif gives me this and there is no way I manage to adapt it a bit more with gdal_translate without it shifting back to its wrong position:confused::

C:\Program Files\FWTools2.4.7>gdalinfo 1005CATD.tif
Driver: GTiff/GeoTIFF
Files: 1005CATD.tif
Size is 1382, 1380
Coordinate System is:
GEOGCS["WGS 84",
DATUM["WGS_1984",
SPHEROID["WGS 84",6378137,298.257223563,
AUTHORITY["EPSG","7030"]],
AUTHORITY["EPSG","6326"]],
PRIMEM["Greenwich",0],
UNIT["degree",0.0174532925199433],
AUTHORITY["EPSG","4326"]]
Origin = (-169.750692467693910,-14.132679758633371)
Pixel Size = (0.000091518817350,-0.000091518817350)
Metadata:
AREA_OR_POINT=Area
Image Structure Metadata:
INTERLEAVE=BAND
Corner Coordinates:
Upper Left (-169.7506925, -14.1326798) (169d45'2.49"W, 14d 7'57.65"S)
Lower Left (-169.7506925, -14.2589757) (169d45'2.49"W, 14d15'32.31"S)
Upper Right (-169.6242135, -14.1326798) (169d37'27.17"W, 14d 7'57.65"S)
Lower Right (-169.6242135, -14.2589757) (169d37'27.17"W, 14d15'32.31"S)
Center (-169.6874530, -14.1958277) (169d41'14.83"W, 14d11'44.98"S)
Band 1 Block=1382x1 Type=Float32, ColorInterp=Gray

C:\Program Files\FWTools2.4.7>


Thanks for caring,

Roby
 

Attachments

I have several questions again, unfortunately.
1. I cannot replicate what I did to get the mesh on the right place and forgot how I did it exactly. Everytime I now try to convert the ddf into tif I get the wrong coordinates again. The only proof I have is the bgl I attached earlier. Is there a way to decompile the bgl to have the tif once more?
2. The new tifs all say INTERLEAVE=BAND although I specified " -co INTERLEAVE=PIXEL". (Resample is supposed to not be able to read that, I read, but it does resample although the geotiff specifies BAND as well and has the correct coordinates). How do I change BAND into PIXEL?
Sorry for all these questions but I am new at this (last week at this time I had not inkling at all).
 
Back
Top