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

Night Map Texture Help.

Messages
350
Country
us-michigan
Ok, made the night texture map of area, that's fine. Uploaded regular day map from disk into SBX. Highlighted map and right clicked to assign night texture map I made. Regular day map then turns to night texture map. Highlight map again and compile. Ok, now what? Do I have do the same to the night map as I did with the regular day map? Blend map, water map, etc and resample? In the end do I have two different BGL's of my map in FSX, day and night? Wish someone would make a detailed video on how to do this.
 
This is my work thus far. Blend, Water and Night maps are finished. I made a BGL of my Night Map. I have no idea what order to do things. I have watched this on Youtube, but doesn't explain how to apply the Night Map in FSX. Do I have to include it in the INF file when I resample the Blend and Water Maps? I'm lost. Sorry if this has been explained in the past to me.



https://drive.google.com/open?id=1cq0imuN_yOIy4C1GEbvjWBBMJ1blqt4J
 
Hi Chris:

Copy all the above source files in your linked ZIP file including the matching file name *.TXT, Water / Blend Mask, and Light Map (Night) image files ...to be used for compilation, into:

[SBuilderX install path]\Tools\Work sub-folder


Make ZIP backups of "Photo01.INF" or "Photo01.BGL" files output by SBuilderX for prior BGL compilations, then delete the 'originals'.


Additionally, place a copy of SDK Resample into that same folder.


Start SBuilderX, then:

1.) SBuilderX Menu > File > New Project > type a new name different from any prior project recently used


2.) SBuilderX Menu > File > Add Map > From Disk > Browse / Select / Open: L18X97732X97769Y207068Y207093_O.BMP


3.) Zoom out until entire Background Image can be seen in the SBuilderX work-space


4.) Drag a frame around the entire image to 'Select' it within the SBuilderX work-space


5.) Right-click the border of the 'Selected' image > context menu > click "Properties" < 'SBuilderX - Map Properties' dialog opens >

a.) In 'SBuilderX - Map Properties' dialog, click {Seasons} tab, enter path to all images to be used; click [OK]


NOTE: For Summer, choose "L18X97732X97769Y207068Y207093_O.BMP" as it will be the original "DAY" 24-Bit texture

CAVEAT: Do not choose "L18X97732X97769Y207068Y207093.BMP" as it is a 32-Bit texture, and not a 24-Bit texture


BTW: According to Luis Feliz-Tirado's tutorial "Make Photo-real Ground Textures in FSX":

"SBuilderX will automatically integrate the blend and/or water mask in the custom ground"


Thus, the Water Mask and Blend Mask will automatically be found / used during BGL compilation, even if not listed in SBuilderX' {Seasons} dialog entries or the INF file.


CAVEAT: AFAIK, this will only work if the Water Mask and Blend masks are included as Alpha Channels within the DAY image source file, when that DAY (Summer Season) image is a TIFF (*.TIF) or Targa (*.TGA) texture image file format.


In this project, your map image source file for the DAY (Summer Season) image is a 24-Bit Windows Bitmap (*.BMP) texture image file format, and your masks:

Water Mask: L18X97732X97769Y207068Y207093_W.BMP

Blend Mask: L18X97732X97769Y207068Y207093_B.BMP

...will NOT be automatically be found / used during BGL compilation, because:

* they are NOT included as Alpha Channels within the DAY image source file

* they are NOT otherwise listed in SBuilderX' {Seasons} dialog entries (not possible yet in SBuilderX)

* they have NOT yet been defined in the INF file.


So, one must manually edit the multi-source INF file, and then manually submit it to SDK Resample.

That manual procedure will be subsequently addressed farther along within this post. ;)


6.) Again, drag a frame around the entire Background image to 'Select' it in the SBuilderX work-space


7.) SBuilderX Menu > File > BGL Compile < 'SBuilderX BGL Compilation' dialog opens >

a.) In 'SBuilderX BGL Compilation' dialog, check "Photo Scenery"; click [Compile] button.


SDK Resample should then compile a custom photo-real aerial imagery land class BGL into:

[SBuilderX install path]\Tools\Work sub-folder


FYI: Because in this project, your DAY image source file for the DAY (Summer Season) image is a 24-Bit Windows Bitmap (*.BMP) texture image file format, one must manually edit the multi-source INF file that is to be manually submitted to SDK Resample.


After the above "Photo01.BGL" compilation is completed:

1.) Make ZIP backups of the "Photo01.INF" and "Photo01.BGL" files output by SBuilderX for that compilation

a.) Delete the original "Photo01.BGL" file output by SBuilderX for that compilation


2.) Edit the original "Photo01.INF" file output by SBuilderX in Windows NotePad as shown:

[Source]
Type = MultiSource
NumberOfSources = 4

[Source1]
Type = BMP
Layer = Imagery
SourceDir = "."
SourceFile = "L18X97732X97769Y207068Y207093_O.BMP"
Variation = Day
Channel_BlendMask = 2.0
Channel_LandWaterMask = 3.0
ulyMap = 35.3375338
ulxMap = -112.8927612
xDim = 2.68220600328845E-06
yDim = 2.18823617788513E-06

[Source2]
Type = BMP
Layer = None
SourceDir = "."
SourceFile = "L18X97732X97769Y207068Y207093_B.BMP"
SamplingMethod = Gaussian
ulyMap = 35.3375338
ulxMap = -112.8927612
xDim = 2.68220600328845E-06
yDim = 2.18823617788513E-06

[Source3]
Type = BMP
Layer = None
SourceDir = "."
SourceFile = "L18X97732X97769Y207068Y207093_W.BMP"
SamplingMethod = Gaussian
ulyMap = 35.3375338
ulxMap = -112.8927612
xDim = 2.68220600328845E-06
yDim = 2.18823617788513E-06

[Source4]
Type = BMP
Layer = Imagery
SourceDir = "."
SourceFile = "L18X97732X97769Y207068Y207093_N.BMP"
Variation = Night
SamplingMethod = Gaussian
ulyMap = 35.3375338
ulxMap = -112.8927612
xDim = 2.68220600328845E-06
yDim = 2.18823617788513E-06

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

3.) Save those changes to that same original "Photo01.INF" file

a.) When editing of your "Photo01.INF" file in Windows NotePad is finished:

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

(2) In NotePad Menu > File > Save As... > "Save In" field, browse to:

[SBuilderX install path]\Tools\Work sub-folder; double-click to select it


(3) Back in NotePad Menu > File > Save As... browse dialog, click [OK] button

(a) When prompted to over-write "Photo01.INF", click "YES" to save your edits to that file.


4.) Drag-and-Drop that edited "Photo01.INF" file onto SDK Resample


SDK Resample should then compile a custom photo-real aerial imagery land class BGL into:

[SBuilderX install path]\Tools\Work sub-folder


Add your new BGL to the \Scenery sub-folder of a 'active' Area layer in FS Scenery Library GUI.


Please attach a screenshot from FSX in top-down view for any further troubleshooting here. :pushpin:



You may wish to review at least these (2) of our prior discussion threads:

http://www.fsdeveloper.com/forum/threads/setting-up-sbuilderx-on-fsx-steam.439636/page-4#post-770164

http://www.fsdeveloper.com/forum/threads/night-texture-help.441091/


PS: Our other prior discussion threads:

https://www.google.com/search?ei=_zkPWrqOJYnPjwTl_Iy4Bg&q=site:http://www.fsdeveloper.com/forum/+GaryGB+Aspireman&oq=site:http://www.fsdeveloper.com/forum/+GaryGB+Aspireman&gs_l=psy-ab.12...15708.15708.0.21998.1.1.0.0.0.0.84.84.1.1.0....0...1.1.64.psy-ab..0.0.0....0.VucspsJjtg8


Hope this helps ! :)

GaryGB
 
Last edited:
You're welcome. :-)

PS: Your set of files should compile to a BGL that displays properly in FSX, since I have already tested them with the edited INF as described above. ;-)

GaryGB
 
When I add my "O" as original, and then add my night map it won't let me compile. I highlight and it claims nothing is highlighted. I have compiled night maps using the unedited day map, but you said to not use it because it's 32 bit. If I change it to 24 will it work alright?
 
One thing. Do I have to resample 1 or 2 BGL's? Like, originally I just made a day map with blend and water masks. Once I compile and night map do I just have to use that Photo_1 BGL and only that BGL to then edit my INF file like you advised? Sorry, still confused. Once I get it I'll face palm.
 
Hi Chris:

This should work if the steps listed above are followed exactly as written.;)

I suggest that the specified 24-Bit Day source file be used at this time, as there may otherwise be further modification of the INF file required beyond that in my "worked example" provided above if the 32-Bit file is used instead. :alert:


FYI: SBuilderX may not allow a background image to "Select" for BGL compilation, if: :pushpin:

* you do not first create an entirely new project under a new name (and thereby allow a new default 'MAP' Name of "Photo01" to be used for the Background image after it is 'Added From Disk')

...and/or if:

* after making a ZIP backup, you do not delete the original BGL initially output by SBuilder containing just the Day and Night images.

WHY:

Resample 'may' not over-write an existing BGL with the same INF destination file name prefix, so if you have loaded an 'old' project in SBuilderX, it will know that Photo01 has already been used as a 'MAP' Name on the {General} tab, and might not allow the Background image to be 'Selected' in the SBuilderX work-space.


BTW: You will only require (1) BGL, as all Day / Night / Seasonal variation texture images and mask info will be compiled into that single BGL along with placement instructions etc. (in FSX / P3D there is no longer texture tiles written out by Resample into a separate \Texture folder like was done in FS versions prior to FSX). :)

[EDITED]

PS: I have edited my post above in an effort to provide additional 'clarity'.

http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-785473

[END_EDIT]

GaryGB
 
Last edited:
I have just noticed this post and I am interested in how you created your night texture map.

But firstly regarding dropping the .INF file onto RESAMPLE and nothing happened.
I have experienced that too and the 'window' closes too quickly to be able to read any error messages. I then used the command app (CMD) to recompile manually "enter RESAMPLE filename.INF". The CMD window stays open and you can see what the problem is eg "file not found or whatever.
Just wondering if there are other methods of using resample which allows the user to see any error messages.

Now back to night images.

I am currently trying to do the same (to create a night image) and at first tried doing this by just adjusting the brightness and contrast. I found that darkening the image didn't darken the pure white (or near pure white) areas and so I reduced the contrast with limited results.
I then tried using the flood fill tool with BLACK as the selected color and an opacity of 85 which seemed to produce a desirable effect.
The Youtube sample Gary gave I have seen before and the author discusses how to do it using Photoshop which I don't have (I have Paint Shop Pro v8 and GIMP).

What is the best method to use?

Lastly I was reminded in Gary's reply to name the image files with a suffix of -
_N for the night image
_B for the blend mask
_W for the water mask
_O which appears to be the original satellite image (day view)

Is this required by RESAMPLE or just so the author can recogise what is what. I have named mine with suffixes of _BLENDMASK, _WATERMASK etc for identification and they appear to compile ok.
 
Last edited:
Hello:

I recently found a statement by Richard Ludowise (aka "rhumbaflappy") that the source file suffixes are ignored by SDK Resample, and are only used by SBuilderX when working with certain very limited source file scenarios to output a "basic" multi-source INF. ;)

Anything more complex than using files listed in the fields on the SBuilderX - Map Properties {Seasons} tab ex: involving additional files for Blend and Land-Water Masks or multiple aerial imagery sources etc. ...will require manual editing of the multi-source INF file. :pushpin:

GaryGB
 
Last edited:
Thanks Gary

Now that you mention it I think I can remember reading somewhere about those suffixes when 'compiling' via SBX.

By the way I just came across another suffix which the author of that Youtube video tutorials mentions in his night map tutorial (for lighting) as _LM which he calls 'light map'.
I am assuming that if you want 'lights' to appear after dark that you create an image for the night view and another for the lights (which is created from another layer which is all black except for the lighting you create) and add sections in the INF file for Variation Night and Variation Lightmap. Am I correct?


Regarding the use of Resample via drag and drop.
All I could find is that Resample is command line driven tool, which suggests that while it will work dragging dropping an INF file onto it (as many tutorials advise) if you want to use input parameters and see the output it is best run from a command line. Agree? I have yet to read any tutorial which addresses the possibility of an error, and how to find out what it is) when executing Resample via drag and drop.
Recently I had an error in my INF file which caused Resample to just flick off the screen. I checked the INF file and could find no problem so resorted to manually running it where it displayed what the problem was.
 
Last edited:
http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-787008

By the way I just came across another suffix which the author of that Youtube video tutorials mentions in his night map tutorial (for lighting) as _LM which he calls 'light map'.

Indeed, that is the 'official' SDK terminology for a "LightMap" (aka "_LM") texture material in 3D models ...as well as in land class.

The "_N" was used by a few developers out of habit from the context of earlier releases of SBuilder to serve as a mnemonic for the "Night" texture, to distinguish it from other source file 'types' in an INF file, which AFAIK, is actually not 'auto-detected' by SBuilder, and must be manually listed in the SBuilder - Map Properties {Seasons} tab dialog in order for it to be incorporated in the structure of a SDK Resample-compiled custom aerial imagery land class BGL.


http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-787008

I am assuming that if you want 'lights' to appear after dark that you create an image for the night view and another for the lights (which is created from another layer which is all black except for the lighting you create) and add sections in the INF file for Variation Night and Variation Lightmap. Am I correct?

IMHO, that would be un-necessary extra work; most developers would use the "Brightness" Tool to lighten the already darkened "Night" texture (which is a single copy of their "Day" texture) to create light splashes which variably reveal the Day image already present ...under ramp / street / other areas where illumination would exist in proximity to light sources that will be depicted in their scenery.

That resulting "Night" texture will be used as the "LightMap" (aka "_LM") imagery source file.

http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-787008

Regarding the use of Resample via drag and drop.
All I could find is that Resample is command line driven tool, which suggests that while it will work dragging dropping an INF file onto it (as many tutorials advise) if you want to use input parameters and see the output it is best run from a command line. Agree? I have yet to read any tutorial which addresses the possibility of an error, and how to find out what it is) when executing Resample via drag and drop.

Recently I had an error in my INF file which caused Resample to just flick off the screen. I checked the INF file and could find no problem so resorted to manually running it where it displayed what the problem was.

SDK Resample.exe command line switch parameters are almost never used, so Drag-and-Drop is typically used after we become more well-practiced in working with a properly constructed INF and when we have verified that all source data files referenced by a INF file ...are present in the path locations specified within that INF file.

However, it is a good idea to run Resample from a CMD Mode (aka "DOS") 'Batch' file, so that any error messages can be seen.

Until Arno adds the ability to use his Compile Helper 2.0 utility with FS SDK Resample, we have to create our own batch files to keep the Resample task session command window open after we (attempt to) run it.

This may be preferable to manually starting FSX SDK Resample via a 'command mode' windowed task session from:

Windows Start Button > Run > 'Open' > CMD > [OK button]



Work-around
:

An example batch file to be placed into your 'work' sub-folder containing FSX SDK Resample with all source BMP / TIF and INF files:


1.) Copy and paste the following into Windows NotePad:

Code:
resample.exe "[your INF file name goes here].INF"
PAUSE

2.) Edit the above text to enter the actual name of your own INF file name

3.) Click File > Save As > 'Save as type' > "All Files (*.*)", enter your desired file name being sure to use a "*.BAT" 3-character file extension ex: "[your INF file name goes here].BAT", and save your file into the same folder cited above (...containing FSX SDK Resample as well as your source files).

4.) In Windows Explorer, running this "DOS" batch file via a 'double-click' should enable you to read any Resample SDK error messages you are getting within the SDK Resample 'command mode' task session window.

GaryGB
 
Last edited:
Thanks Gary

For all the explanations.

Regarding the night and light map variations (images). I raed what you say and think I understand. Are you saying that a lot of developers used just one image and not two separate images?
I had considered making a single image for the night views and lighting but thought that FSX might blend the day and night images to give a twilight effect and then the lighting effect might be compromised.

Ah the humble 'batch' file (.BAT). I sort of grew up on those having started with Windows 3.1. Remember the Autoex.Bat file (file containing Disk Operating System commands that are executable when the computer is booted and which I often edited in an attempt to get things working better)? Many readers of this thread will have no idea what I mean.

Regards
 
http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-787068

Regarding the night and light map variations (images). I read what you say and think I understand. Are you saying that a lot of developers used just one image and not two separate images?

Yes.

However, when working with layers in a more sophisticated graphics application that allows multiple layers, there may be ways to do what you describe with more than 1 layer; but ultimately those layers must be flattened / merged / combined into just (1) layer output to an image file designated as the "LightMap" or "Night" variation source in the INF.


BTW: Only the (1) Night" variation image source referenced in the INF will be used for all seasons, so that image needs to be "dark" enough so that the actual season on the ground is not easily discerned from the user aircraft.

http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-787068

I had considered making a single image for the night views and lighting but thought that FSX might blend the day and night images to give a twilight effect and then the lighting effect might be compromised.

The Night image is loaded instead of any Day or any "Season" variation of Day imagery when it is Night within the local position in the 3D FS world.

The FS rendering engine performs a "Blended" incremental transition of Day and Night imagery every 10 minutes or so during dusk and dawn hours; otherwise the images display as 'fully bright' at Noon, and 'fully dark' at Midnight.. :idea:

http://www.fsdeveloper.com/forum/threads/night-map-texture-help.441472/#post-787068

Ah, the humble 'batch' file (.BAT). I sort of grew up on those having started with Windows 3.1. Remember the Autoexec.Bat file (file containing Disk Operating System commands that are executable when the computer is booted and which I often edited in an attempt to get things working better)? Many readers of this thread will have no idea what I mean.

Indeed; and let us not forget Config.sys and countless INI files. :coffee:

I sometimes wonder whether it was scanning Bootlog.txt or log files from SysInternals FileMon / ProcMon ...that further developed my speed reading skills to their (former ?) levels.

BTW: I started on DOS 2.0 through 7.0, and used "DoubleDos" task switcher, DESQview, Windows 1.0, 2.0, 3.1, 3.11, 95, 98, Millennium, NT / NT Server, Windows 2000, XP, 7, 8, ...and am still attempting to not use Windows 10. ;)


I am embarrassed to state that, for sheer convenience of transportability, this post was composed on a I-Pad. :rotfl:

GaryGB
 
Last edited:
However, when working with layers in a more sophisticated graphics application that allows multiple layers, there may be ways to do what you describe with more than 1 layer; but ultimately those layers must be flattened / merged / combined into just (1) layer output to an image file designated as the "LightMap" ior "Night" variation source in the INF.
Ah 'flattened'. In that night map video tutorial (or somewhere else I read) I noted that the image was 'flattened' and at first wondered what he meant until I looked it up to find it makes one image out of multi layers. Well I think that is what it means. I now have to see how to flatten a selected layer with an image. I will try selecting both 'layers' and then select 'flatten. Nothing like trial and error when you have backup copies.

Yes I assumed that seasons would not even be required in a 'night view'.
I am now starting to add 'lighting' to my night image which is fairly daunting trying to make it look realistic. I have started with my photo scenery of a very large sand and stone quarry which should only have security type lights in some areas.

It seems that the resulting (compiled) BGL file can become quite large in size as I found when I added a night view (minus any lighting) to the .ini and compiled.
Indeed; and let us not forget Config.sys and countless INI files.
I can't ever remember modifying the config.sys. That was 20 years ago (I 'migrated' from 3.1 to Windows 98 to Windows ME (which wasn't really much of an update but I got it cheap when in Ireland at the time), then W XP until they stopped supporting it.
I didn't mind DOS as my previous 'PC' was a z80 based PC (8 bit processor).
I have a notebook with preinstalled W10 and I much prefer W7 (desktop) although if I was forced to use W10 all the time instead of only a few times a year I might learn to like it.
 
Last edited:
Back
Top