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

SceneProc texture editor time-to-process

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
Hi folks, I'm getting into my stride with SceneProc now and seeing some great results - enough so that I've taken the plunge into working directly with GEOTiff files to see what I can grab from areas that have little GIS data.

I'm working with a 12MB GEOTiff, have successfully detected large areas of vegetation after a couple of test runs on smaller areas of the same imagery. However, having started the process of exporting from raster to SHP, it's been running for nearly 5 hours now and is still splitting the grid. Is that normal, or have I done something here that's stretching the process out too much?

Code:
IMPORTGDAL|Geo_4.tif|AUTODETECT
# 
SPLITGRID|AGN|*|* 
# 
DETECTFEATURES|FTYPE=RASTER|New_Defined_Area_Polygons_130719.tfc|veg|trees 
#
MergeGrid
# 
EXPORTSHP|FTYPE=POLYGON|veg_trees|D:\DeanFSXScenery\New_AGN_Tests
 

MatthiasKNU

Resource contributor
Messages
955
Country
germany
I would recommend just to use "SPLITGRID|AGN|*"
But anyway, detecting features can take a few hours...
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
Messages
32,858
Country
netherlands
Hi,

Loading the images shouldn't take that long. Are you sure the input image is correctly geo referenced?
 

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
Hi,

Loading the images shouldn't take that long. Are you sure the input image is correctly geo referenced?

It did come up with a warning saying "Check projection: unusual coordinates found". I am wondering if this is somehow tripping the editor up. Not sure of the best way to fix that really.
 

MatthiasKNU

Resource contributor
Messages
955
Country
germany
I would load the tif into your GIS software, and if the coordinate system is not WGS1984 I would reproject it into the WGS84. That's the most common coordinate system.
 

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
I would load the tif into your GIS software, and if the coordinate system is not WGS1984 I would reproject it into the WGS84. That's the most common coordinate system.

It's already in the correct format ( WGS84 ), so I don't think that's the issue.
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
Messages
32,858
Country
netherlands
Are you sure, in that case that warning would not appear?

Do you have gdal tools installed? In that case the gdalinfo output would be useful to see.
 

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
Are you sure, in that case that warning would not appear?

Do you have gdal tools installed? In that case the gdalinfo output would be useful to see.

I don't have those tools unfortunately. I think that I'll try re-sourcing the image and see how I go, something might be corrupted in there. I used SBuilderX to create it.
 

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
If you haven't done it yet, download QGIS, and load the tif into it. In QGIS you can reproject it to WGS84, even if it is already WGS84.

I'm using QGIS too, as I've been using it for other shp-based projects :) I did try re-projecting again, it has 3 WGS84 options, all three still result in the warning from Sceneproc ( or they crash QGIS ). Yet another odd stumbling block for me, will keep tinkering as always.
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
Messages
32,858
Country
netherlands
Can you right click on the file in QGIS and show the properties? That should show the coordinate system and extends as well.
 

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
Can you right click on the file in QGIS and show the properties? That should show the coordinate system and extends as well.

Code:
Name
Geo_4
Path
D:\DeanFSXScenery\shape\Geo_4.TIF
CRS
EPSG:4326 - WGS 84 - Geographic
Extent
0.0000000000000000,-1792.0000000000000000 : 2816.0000000000000000,0.0000000000000000
Unit
degrees
Width
2816
Height
1792
Data type
Byte - Eight bit unsigned integer
GDAL Driver Description
GTiff
GDAL Driver Metadata
GeoTIFF
Dataset Description
D:\DeanFSXScenery\shape\Geo_4.TIF
Compression

Band 1
STATISTICS_APPROXIMATE=YES
STATISTICS_MAXIMUM=255
STATISTICS_MEAN=91.550327034884
STATISTICS_MINIMUM=0
STATISTICS_STDDEV=48.638254974315
STATISTICS_VALID_PERCENT=100
Band 2
STATISTICS_APPROXIMATE=YES
STATISTICS_MAXIMUM=255
STATISTICS_MEAN=97.119929307611
STATISTICS_MINIMUM=3
STATISTICS_STDDEV=38.342049556067
STATISTICS_VALID_PERCENT=100
Band 3
STATISTICS_APPROXIMATE=YES
STATISTICS_MAXIMUM=255
STATISTICS_MEAN=81.508423625793
STATISTICS_MINIMUM=0
STATISTICS_STDDEV=38.497488640247
STATISTICS_VALID_PERCENT=100
Band 4

More information
AREA_OR_POINT=Area
Dimensions
X: 2816 Y: 1792 Bands: 4
Origin
0,0
Pixel Size
1,-1
 

MatthiasKNU

Resource contributor
Messages
955
Country
germany
What area does the tif cover? When I enter the extent into ArcGIS, I see a huge area which covers the complete northern hemisphere...
This will take forever to create in ScenProc.
Something went wrong with the referencing.

Maybe you can upload the tif and then I have a look?

EDIT:
Yes, there is the problem:
Extent
0.0000000000000000,-1792.0000000000000000 : 2816.0000000000000000,0.0000000000000000
Unit
degrees
Width
2816
Height
1792

The unit can't be degrees, because that would mean the tif would cover a total of 2816° Longitude (8 times around the world) and 1792! Latitude (5 times around the world).
I assume the unit should be Meters.
 
Last edited:

arno

Administrator
Staff member
FSDevConf team
Resource contributor
Messages
32,858
Country
netherlands
Yes, the geo referencing of that image is wrong. If scenproc then tries to split in the agn grid it will take for ages, as there are billions of cells to make.
 

rhumbaflappy

Administrator
Staff member
Resource contributor
Messages
5,932
Country
us-wisconsin
GeoTiffs from SBuilderX have always been wrong. There's usually a warning that pops up when they are created.
 

rhumbaflappy

Administrator
Staff member
Resource contributor
Messages
5,932
Country
us-wisconsin
I think you can use the BMP file from SBuilderX with sceneproc if you create a .wld file (or .bfw file). It's a text file you can create.

Code:
5.3646557464376082034891463577041e-6
0
0
-3.9471154516916637600279037321242e-6
-88.7036133
42.6582018

1) is the span of the x dimension (East - West) / ( x_dimension_of_pixels - 1)
2) leave as 0 ( it's rotation)
3) also leave as 0
4) span of the y dimension (South - North) / (y_dimension_of_pixels - 1)
5) West longitude
6) North latitude

I hope all this is right. With the .wld file and the same-named .bmp file in the same folder, you can import to QGIS to then export a valid geotiff, or I believe use as is in sceneproc.

You can also use the INF file dimensions. They probably will differ from mine slightly, as Louis did not use the center of the pixel in his calculations. Just remember to negate the y dimension for your .wld file. This might even be better, as the BGL is made from this data.

Code:
[Source]
   Type = BMP
   Layer = Imagery
   SourceDir = "."
   SourceFile = "L17X66480X66567Y96664Y96719.BMP"
   Variation = All
   NullValue = 255,255,255
   SamplingMethod = Gaussian
   ulyMap =  42.6582018
   ulxMap = -88.7036133
   xDim =  5.36441761363635E-06
   yDim =  3.94684012276769E-06
 
Last edited:

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
Hi guys, sorry for the slow reply. Wow, I had no idea that coordinates from SBX would be so wildly inaccurate! That explains a lot then :)

Many thanks for all your help, I will try the new offered coordinates and report back on what happens.
 

Deano1973

Resource contributor
Messages
384
Country
unitedkingdom
Sadly, nothing's working - the file is still reported as containing unusual coordinates, regardless of source or even me manually inputting the data before export from QGIS. I will re-download the image file and try again in case the original was somehow corrupted in some way.
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
Messages
32,858
Country
netherlands
If you have the INF file, you can also import that in scenproc. That will georeference the images as well.
 
Top