Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Moon brightness

Featured Replies

Hello guys,

is there any tweak to reduce the brightness of the moon? In V5 the moon illuminates the aircraft a lot so the night is not very dark.

Are anyone using HDR?

Can confirm, the brightness depends on the phase of the moon.

Johan Pienaar

 

  • Author

Yes of course, but irl i never mentioned such a bright night during half moon

  • 4 weeks later...
  • Author

Look at this (EA on HF1) this is with half moon today. It is definitely too bright

kzo3mswy.png

NVM. User error.

Edited by B777ER

Eric 

 

 

The moon is illuminating the ground at night way too much in the latest HF

  • 3 months later...

i have edited shaders_hlsl manually to completely rid off any kind of moon contribution and i`am pretty satisfied with the result. here you can see all the differences i have made (use winmerge to sort it out) https://yadi.sk/d/S5zRCvbTrorHew

Edited by aiRoNe_fx

3 hours ago, aiRoNe_fx said:

i have edited shaders_hlsl manually to completely rid off any kind of moon contribution and i`am pretty satisfied with the result. here you can see all the differences i have made (use winmerge to sort it out) https://yadi.sk/d/S5zRCvbTrorHew

awsome, but it doesnt seem to work with truesky on.  I guess its a different set of shaders.

 

EDIT: It might be because I forgot to clear shaders.  You are the hero I was looking for today.

Edited by Pilot53

 

Lian Li 011 Air Mini | AMD 9800X3D | Asus ROG STRIX B650E-F | Arctic Cooling Liquid Freezer II 280mm RGB | 2x32GB G.Skill DDR5-6000 | ASUS TUF RTX 5090 | Seasonic Prime Platinum 1000W | Pimax Crystal Light

 

True Sky has its own sky, clouds, sun and moon which cannot be changed by modifying the P3D shaders.

Edited by GSalden

5950x3d 5.4-5.7 GHz - Asus ROG 870 Crosshair Apex - GSkill Neo 2x 24 Gb 6000 mhz / cas 26 -  MSI RTX 5090 Gaming Trio OC - 1x SSD M2 6000 2TB - 1x SSD M2 2800/1800 1Tb -  Corsair 5400  case - Corsair 360 liquid cooling set  - 3x 75’ TCL tv.

13600  6 cores @ 5.1 GHz / 8 cores @ 4.0 GHz (hypterthreading on) - Asus ROG Strix Gaming D - GSkill Trident 4x Gb 3200 MHz cas 15 - Asus TUF RTX 4080 16 Gb  - 1x SSD M2 2800/1800 2TB - 2x  Sata 600 SSD 500 Mb - Corsair D4000 Airflow case - NXT Krajen Z63 AIO liquide cooling - 

FOV : 200 degrees

My flightsim vids :  https://www.youtube.com/user/fswidesim/videos?shelf_id=0&sort=dd&view=0

 

I figured it out, by looking at the files modified by @aiRoNe_fx I was able to lower the influence of the moon on overall lighting in the sim, with truesky enabled.  This way you still get some light from the moon from different phases, but a realistic amount.  Clear your shaders or it won't work.

The first file you need to mod is FuncLibrary.fxh, this one controls the VC lighting and building textures, runways, etc.

Find this code:

#if defined(SHD_VERTICAL_NORMAL)
    const float fDotSun = max(cb_mSun.mDirection.y, 0);
    const float fDotMoon = max(cb_mMoon.mDirection.y, 0);
#else
    const float fDotSun = saturate(dot(vNormalWS, normalize(cb_mSun.mDirection)));
    const float fDotMoon = saturate(dot(vNormalWS, normalize(cb_mMoon.mDirection)));
#endif

    float3 diffuseLighting = (shadowContrib * (cb_mSun.mDiffuse.xyz * fDotSun)) + 
                             (shadowContrib * (cb_mMoon.mDiffuse.xyz * fDotMoon));

    return diffuseLighting + cb_mCombinedAmbient.rgb;

Replace it with this:

#if defined(SHD_VERTICAL_NORMAL)
    const float fDotSun = max(cb_mSun.mDirection.y, 0);
    const float fDotMoon = max((cb_mMoon.mDirection.y * 0.1), 0);
#else
    const float fDotSun = saturate(dot(vNormalWS, normalize(cb_mSun.mDirection)));
    const float fDotMoon = saturate(dot(vNormalWS, normalize(cb_mMoon.mDirection * 0.1)));
#endif

    float3 diffuseLighting = (shadowContrib * (cb_mSun.mDiffuse.xyz * fDotSun)) + 
                             (shadowContrib * (cb_mMoon.mDiffuse.xyz * 0.1 * fDotMoon));

    return diffuseLighting + cb_mCombinedAmbient.rgb;

 

The second file is PBRBase.fx, this one seems to control the lighting on the outside of the aircraft.

Find this code:

float3 moonContrib = DirectionalLightingPBR(cb_mMoon, pbrValues);

Replace it with this code:

float3 moonContrib = DirectionalLightingPBR(cb_mMoon, pbrValues) * 0.1;

The last file is Terrain.fx, this controls the terrain brightness

Find this code:

float3 sunContrib = DirectionalLightingPBR(cb_mSun, pbrValues);
    float3 moonContrib = DirectionalLightingPBR(cb_mMoon, pbrValues);
    
    color.rgb = (sunContrib + moonContrib)* shadowContrib;

Replace it with this:

float3 sunContrib = DirectionalLightingPBR(cb_mSun, pbrValues);
    float3 moonContrib = DirectionalLightingPBR(cb_mMoon, pbrValues) * 0.1;
    
    color.rgb = (sunContrib + moonContrib)* shadowContrib;

 

------------------------------------------------------------------------------------------------------------

As you can see its quite simple, we are just adding a multiplier, play with it to suit your tastes. I think this covers all of the scenery and objects, let me know if I missed anything.  Remember to clear your shader cache or the tweaks will not show up.    

 

 

Lian Li 011 Air Mini | AMD 9800X3D | Asus ROG STRIX B650E-F | Arctic Cooling Liquid Freezer II 280mm RGB | 2x32GB G.Skill DDR5-6000 | ASUS TUF RTX 5090 | Seasonic Prime Platinum 1000W | Pimax Crystal Light

 

16 hours ago, GSalden said:

True Sky has its own sky, clouds, sun and moon which cannot be changed by modifying the P3D shaders.

faulted 😄

33 minutes ago, aiRoNe_fx said:

faulted 😄

You cannot change the way sun, moon and clouds look with EA on. 

You can change the amount of overall brightness on the ground/objects, like saturation and shadows.

Hopefully v5.1 will have  EA improved ....

Edited by GSalden

5950x3d 5.4-5.7 GHz - Asus ROG 870 Crosshair Apex - GSkill Neo 2x 24 Gb 6000 mhz / cas 26 -  MSI RTX 5090 Gaming Trio OC - 1x SSD M2 6000 2TB - 1x SSD M2 2800/1800 1Tb -  Corsair 5400  case - Corsair 360 liquid cooling set  - 3x 75’ TCL tv.

13600  6 cores @ 5.1 GHz / 8 cores @ 4.0 GHz (hypterthreading on) - Asus ROG Strix Gaming D - GSkill Trident 4x Gb 3200 MHz cas 15 - Asus TUF RTX 4080 16 Gb  - 1x SSD M2 2800/1800 2TB - 2x  Sata 600 SSD 500 Mb - Corsair D4000 Airflow case - NXT Krajen Z63 AIO liquide cooling - 

FOV : 200 degrees

My flightsim vids :  https://www.youtube.com/user/fswidesim/videos?shelf_id=0&sort=dd&view=0

 

4 hours ago, GSalden said:

You cannot change the way sun, moon and clouds look with EA on. 

You can change the amount of overall brightness on the ground/objects, like saturation and shadows.

Hopefully v5.1 will have  EA improved ....

You mean 5.2 Gerard.... :-) 😉

Regards,

Marcus P.

xaP1VAU.png

3 minutes ago, mpo910 said:

You mean 5.2 Gerard.... 🙂😉

Yep, you’re right Marcus 🤤

5950x3d 5.4-5.7 GHz - Asus ROG 870 Crosshair Apex - GSkill Neo 2x 24 Gb 6000 mhz / cas 26 -  MSI RTX 5090 Gaming Trio OC - 1x SSD M2 6000 2TB - 1x SSD M2 2800/1800 1Tb -  Corsair 5400  case - Corsair 360 liquid cooling set  - 3x 75’ TCL tv.

13600  6 cores @ 5.1 GHz / 8 cores @ 4.0 GHz (hypterthreading on) - Asus ROG Strix Gaming D - GSkill Trident 4x Gb 3200 MHz cas 15 - Asus TUF RTX 4080 16 Gb  - 1x SSD M2 2800/1800 2TB - 2x  Sata 600 SSD 500 Mb - Corsair D4000 Airflow case - NXT Krajen Z63 AIO liquide cooling - 

FOV : 200 degrees

My flightsim vids :  https://www.youtube.com/user/fswidesim/videos?shelf_id=0&sort=dd&view=0

 

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.