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

Resample Question

Messages
687
Country
us-texas
I am attempting to compile an image after adding a winter texture to the mix. I appended the inf file to reflect the correct months for the winter texture, saved and then ran the SBX compile function. I've already done one other scenery using this technique and it compiled fine, but this one does not. After I make the inf changes and compile, I can see from the DOS screen that the months have been changed back to what they were which is incorrect for the region I'm working on. How do I get resample to accept the inf changes?
 
Hi Ed:

I'd encourage you to either post your INF text here, or attach the INF in a ZIP via this thread; this is likely to be a more obscure area of the SDK that very few in the FS Community understand, much less even 'remember'. :)

And since Dick is among the few that knows this subject in detail, we might all learn something more from an open discussion of this type of topic. ;)

Regards,

GaryGB
 
Okie Dokie. . .here it is:The problem is with the months designated to correspond with the snow cover ground texture (Marshall_Island_wi). They are supposed to be December, January, February, March. All other months render the basic ground texture (Marshall_Island.bmp). When I set the months, save the inf file and run the compiler (using the compiler in SBX, not DOS), the months have been reset to what you see in this inf file.

[Source]
Type = MultiSource
NumberOfSources = 4

[Source1]
Type = BMP
Layer = Imagery
SourceDir = "."
SourceFile = "Marshall_Island.BMP"
Variation = June,July,August,April,May,September
Channel_BlendMask = 3.0
Channel_LandWaterMask = 4.0
NullValue = 255,255,255
SamplingMethod = Gaussian
ulyMap = 44.1299852
ulxMap = -68.5231018
xDim = 5.36441406250125E-06
yDim = 3.85154079861107E-06

[Source2]
Type = BMP
Layer = Imagery
SourceDir = "."
SourceFile = "Marshall_Island_wi.bmp"
Variation = October,November,December,January,February,March
Channel_BlendMask = 3.0
Channel_LandWaterMask = 4.0
NullValue = 255,255,255
SamplingMethod = Gaussian
ulyMap = 44.1299852
ulxMap = -68.5231018
xDim = 5.36441406250125E-06
yDim = 3.85154079861107E-06

[Source3]
Type = TIFF
Layer = None
SourceDir = "."
SourceFile = "Marshall_Island_B.TIF"
SamplingMethod = Gaussian
ulyMap = 44.1299852
ulxMap = -68.5231018
xDim = 5.36441406250125E-06
yDim = 3.85154079861107E-06

[Source4]
Type = TIFF
Layer = None
SourceDir = "."
SourceFile = "Marshall_Island_W.TIF"
SamplingMethod = Gaussian
ulyMap = 44.1299852
ulxMap = -68.5231018
xDim = 5.36441406250125E-06
yDim = 3.85154079861107E-06

[Destination]
DestDir = "."
DestBaseFileName = "Photo01"
DestFileType = BGL
LOD = Auto
UseSourceDimensions = 1
CompressionQuality = 85
 
Ed's described work-flow and subsequent results ...brings to mind this thread:

http://www.fsdeveloper.com/forum/threads/photoscenery-with-2-season-and-night-light.9484/



Perhaps Dick might get a free moment to offer comment on whether the steps suggested by Luis Sa' in the above linked thread:

[EDITED]

http://www.fsdeveloper.com/forum/threads/photoscenery-with-2-season-and-night-light.9484/#post-64044

[END_EDIT]

...would still be needed for output of FSX BGL format custom photo-real aerial imagery via the SBuilderX GUI instead of using FS SDK Resample in a separate CMD mode task session with a manually edited INF file ? :scratchch

GaryGB
 
Last edited:
First off, I wouldn't recommend compiling from SBuilderX. You can just drag'n'drop the INF file onto resample, and get it to compile.

Here's a successful INF I used:

Code:
[Source]
Type = MultiSource
NumberOfSources = 4

[Source1]
   Type = BMP
   Layer = Imagery
   SourceDir = "."
   SourceFile = "Summer.BMP"
   Variation = April,May,June,July,August,September,October,November
   Channel_BlendMask = 3.0
   Channel_LandWaterMask = 4.0
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05
 
[Source2]
   Type = BMP
   Layer = Imagery
   SourceDir = "."
   SourceFile = "Winter.BMP"
   Variation = January,February,March,December
   Channel_BlendMask = 3.0
   Channel_LandWaterMask = 4.0
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05 

[Source3]
Type = TIFF
Layer = None
SourceDir = "."
SourceFile = "Blend.tif"
SamplingMethod = Gaussian
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05

[Source4]
Type = TIFF
Layer = None
SourceDir = "."
SourceFile = "Water.tif"
SamplingMethod = Gaussian
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05

[Destination]
DestDir = "."
DestBaseFileName = "Marshall_Islands"
DestFileType = BGL
LOD = Auto
UseSourceDimensions = 1
CompressionQuality = 85

Use this as a template for your images, location and sizing. Tifs are 8-bit greyscale. BMPs are 24-bit. Copy the images, resample and the INF file to a desktop folder, then drag'n'drop.

Dick
 
Thanks for that "worked example", Dick. :)

One more question to clarify something not explained by the SDK docs: if Ed were to use the parameter value "Variation = June,July,August,April,May,September" as shown in the example INF code posted in his latter reply above, would the non-sequential months listed cause FS SDK Resample to generate an error ?

Thanks in advance for any additional insight you might share with us on this process.

GaryGB
 
Last edited:
Hi Gary.

Sequence doesn't seem to matter:

Code:
[Source]
Type = MultiSource
NumberOfSources = 5

[Source1]
   Type = BMP
   Layer = Imagery
   SourceDir = "."
   SourceFile = "Summer.BMP"
   Variation = April,July,February,August,September,May,October,November,June
   Channel_BlendMask = 4.0
   Channel_LandWaterMask = 5.0
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05
 
[Source2]
   Type = BMP
   Layer = Imagery
   SourceDir = "."
   SourceFile = "Winter.BMP"
   Variation = January,December,March
   Channel_BlendMask = 4.0
   Channel_LandWaterMask = 5.0
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05 

[Source3]
   Type = BMP
   Layer = Imagery
   SourceDir = "."
   SourceFile = "Night.BMP"
   Variation = Night
   Channel_BlendMask = 4.0
   Channel_LandWaterMask = 5.0
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05

[Source4]
Type = TIFF
Layer = None
SourceDir = "."
SourceFile = "Blend.tif"
SamplingMethod = Gaussian
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05

[Source5]
Type = TIFF
Layer = None
SourceDir = "."
SourceFile = "Water.tif"
SamplingMethod = Gaussian
   ulyMap =  6.31529853833014
   ulxMap =  171.650390625
   xDim =  8.58306884765625E-05
   yDim =  8.53501400439964E-05

[Destination]
DestDir = "."
DestBaseFileName = "Marshall_Islands"
DestFileType = BGL
LOD = Auto
UseSourceDimensions = 1
CompressionQuality = 85

Notice how I included Night as well.

Dick
 
Last edited:
So, perhaps just a reminder to use "initial caps" on Month names (and separating them with a comma but no spaces ?): :pushpin:

http://www.fsdeveloper.com/forum/threads/season-hard-winter-in-photoreal-scenery.3736/



PS: Thanks as well, for restoring your learning resources to the MS-OneDrive web site in your signature; lots of excellent info and worked examples for other challenging FS SDK tasks as well: :teacher:

https://onedrive.live.com/?cid=F3950C5BBD2BCFA1&id=F3950C5BBD2BCFA1!377


Many thanks again for helping us all to better understand and work with the FS SDK, Dick ! :)


GaryGB
 
Last edited:
So I guess the obvious question for me is this: What's the difference? I've looked at what Dick has posted and looked at mine and I see no difference in the basics. The only difference might be in the position of the individual months on the "variation" line which he has stated makes no difference. So why does dragn'drop succeed where using the SBX compiler does not? Why does the compiler disregard the info in the "inf" file and reset the "variations"?

I appreciate the help from Dick and not downplaying what he has shown, but if both inf files are the same, why does one process work and the other not, especially since, speaking from having done hundreds of photoreal sceneries thus far, the only time a problem arises is when I add seasonal variations (specific months) to the inf file, which I don't ordinarily do.
 
http://www.fsdeveloper.com/forum/threads/resample-question.436493/#post-736277

So why does drag'n'drop (in a CMD mode task session) succeed where using the SBX compiler does not? Why does the compiler disregard the info in the "inf" file and reset the "variations" (when compiled via the SBuilderX GUI)?

Hi Ed:

I suggest that at the time of actual compilation the INF files are NOT the same ...because the manually-edited INF you put into the SBuilderX "\Work" sub-folder along with the aerial imagery *.BMP source file and Geo-referencing *.TXT was over-written by SBuilder using its currently-configured settings in the SBuilder.ini at the time of compilation to a BGL. :scratchch


http://www.fsdeveloper.com/forum/threads/resample-question.436493/

I am attempting to compile an image after adding a winter texture to the mix. I appended the inf file to reflect the correct months for the winter texture, saved and then ran the SBX compile function. I've already done one other scenery using this technique and it compiled fine, but this one does not. After I make the inf changes and (then) compile, I can see from the DOS screen that the months have been changed back to what they were which is incorrect for the region I'm working on. How do I get resample to accept the inf changes?

Please note the edit to my post above:

http://www.fsdeveloper.com/forum/threads/resample-question.436493/#post-736123


Luis Sa' uses a number of configuration settings in the SBuilder.ini file to determine various features and functions during operation, including how SBuilderX will structure the parameter values when writing out a INF file during compilation. :idea:


When one's selected aerial imagery tiles are compiled, they are merged into (1) BMP with a particular file name accompanied by a matched file name TXT file which contains the Geo-referencing, and the INF file is also then written into that same folder:

[SBuilderX install path]\Tools\Work

...using parameter values etc. specified in the SBuilder.ini file.

Be aware of the fact that SBuilder will silently over-write without any warning, a pre-existing INF file having the same name as the one for a current BMP and TXT file it is instructed to compile via the SBuilderX GUI. :alert:


In fact, SBuilder will also silently over-write without any warning, a pre-existing BMP and TXT file having the same name as the one for a current BMP and TXT file it is instructed to compile via the SBuilderX GUI. :pushpin:


So, IIUC, Dick recommends working directly with FS SDK Resample in a separate CMD mode task session to ensure that ones own INF will be used and not over-written by the INF written out by SBuilderX during compilation via the SBuilderX GUI. :teacher:



BTW: Am I correct in assuming, when you state that you "appended the inf file to reflect the correct months for the winter texture", you meant you 'amended' or 'edited' it ?

AFAIK, SBuilder has no provision to "Append" an INF file via the SBuilderX Menu > File > Append feature set, so I presume that you intended to indicate that you placed your own manually-edited INF into the above cited sub-folder:

[SBuilderX install path]\Tools\Work

...and did not realize that when SBuilderX subsequently compiles via the GUI, it will (silently) over-write the source BMP, Geo-referencing TXT, and INF files before then running very same FS SDK Resample that we would otherwise run in a separate CMD-mode task session. ;)



PS: To edit configuration parameters / values etc. in the SBuilder.Ini file:

SBuilder Menu > Edit > Preferences > click [INI File] button < file opens in Windows NotePad >


1.) When configuration of your SBuilderX project is completed via editing "SBuilder.ini" in Windows NotePad:

.....a.) In Windows NotePad Menu > File > Save As... > "Save as type" field, set to "All Files (*.*)" (do not click OK yet)

.....b.) In NotePad Menu > File > Save As... > "Save In" field, browse to [SBuilderX install path] folder; double-click to select it


2.) Back in NotePad Menu > File > Save As... browse dialog, click "OK"

.....a.) When prompted to over-write Sbuilder.ini, click "YES" to save your edits to that file.


Hope this helps answer your question. :)
 
Last edited:
Got Gary. . . .the shorthand version would then be. . ."If you want complete control of your photoreal project, build a custom inf file and compile outside of SBX using the dragn'drop method.

Thank you all for your assistance, very much appreciated.
 
Got Gary. . . .the shorthand version would then be. . ."If you want complete control of your photoreal project, build a custom inf file and compile outside of SBX using the drag'n'drop method.

Thank you all for your assistance, very much appreciated.

Hi Ed:

I'm guessing that might have been intended as: "Got it, Gary", or: "Got your PM, Gary" (...the one I had sent you yesterday) ? :)


Or, maybe my "longhand" posts have now become an essential mainstay of forum visits at FSDeveloper. :p

I can just see it now... a featured pop-up message box at each login that says: "...Got Gary ?" :rotfl:

https://en.wikipedia.org/wiki/Got_Milk?

< Just kidding of course !!! :duck:>


Glad I was able to offer something helpful in the way of explanations and suggestions. :twocents:


I'll be looking forward to some cross-wind landings with the windsock fully-engorged at Crow Island soon ! :cool:

http://www.sim-outhouse.com/sohforums/showthread.php?98895-Crow-Island-Airport


GaryGB
 
Last edited:
...Thanks as well, for restoring your learning resources to the MS-OneDrive web site in your signature; lots of excellent info and worked examples for other challenging FS SDK tasks as well... Many thanks again for helping us all to better understand and work with the FS SDK, Dick !
Quite agree, Gary! Thank you, Dick, thank you! :)
 
Back
Top