New Release D3D9Client Development

Marg

Active member
Joined
Mar 20, 2008
Messages
482
Reaction score
66
Points
28
I can only imagine the math that have to go into sunshine, earthshine, moonshine and interior reflections. Not to mention interior lighting.
No moonshine, earthshine, just sun - and that is not, I say I saw sunspots in mesh from the outside, so problem is that cockpit rendering is different. Interior lighting also is not top priority, just just basic shading, I would prefer darker environment...
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,429
Reaction score
680
Points
203
Another Metalness shader issue, local lights light up everything, including the exterior when it shouldn't. And this is just one of the six payload flood lights turned on during full on orbital night.
 

Attachments

  • D3D9Client_new_shader6.jpg
    D3D9Client_new_shader6.jpg
    1.8 MB · Views: 23

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
@jarmonik : Do you plan to leave the Test Sphere in? I'm asking because I plan to update the documentation a bit.
 

Felix24

Active member
Joined
May 13, 2010
Messages
245
Reaction score
95
Points
43
It's taking me a while to understand how the new shader works- I'm used to how the older PBR and earlier shaders calculated things.
 

N_Molson

Addon Developer
Addon Developer
Donator
Joined
Mar 5, 2010
Messages
9,272
Reaction score
3,244
Points
203
Location
Toulouse
It's taking me a while to understand how the new shader works- I'm used to how the older PBR and earlier shaders calculated things.

Its worth it. That new shader feel much more real, especially with metallic parts which are what most spacecraft are made of ?
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
It's taking me a while to understand how the new shader works- I'm used to how the older PBR and earlier shaders calculated things.

The sun light behavior is based on Cook-Torrance Model. The main equation that combines "Distribution", "Geometric Attenuation" and "Fresnel" C_spec = D()*G()*F() / (4*dLN*dCN).
Is simplified in a form:
float3 cS = (fD * cF * fG) * 0.25f; // / (4.0f*dLN*dCN) removed to avoid division by zero, compensation in GSF

The environment reflections works very much the same way as in the old shader.
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
@jarmonik : Do you plan to leave the Test Sphere in? I'm asking because I plan to update the documentation a bit.
Yes, I was planning to leave it and add a textured cylinder. Might be good idea to wait a bit with documentation updates since some of the things may change a bit.
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
Another Metalness shader issue, local lights light up everything, including the exterior when it shouldn't. And this is just one of the six payload flood lights turned on during full on orbital night.
Could you disable the reflections from the setup dialog and see if the problem still occur ? How does the lighting work with the old shader ?
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
I wanted to throw another important thing - cockpit lighting.
I am aware of poor rendering conditions in a virtual cockpits. There are ways to improve them but they don't come easy. The best known solution for that is awfully complicated and I am not ready to invest that much of time and efforts under current conditions. There might be some other mediocre solutions good enough and do able.

1) A quality cockpit environment would be required.
2) A developer who is willing to do work on the cockpit side would be required.

We have had a capability to support instrument panel background lighting 5+ years already and I have never seen an application to actually use it.
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,429
Reaction score
680
Points
203
Could you disable the reflections from the setup dialog and see if the problem still occur ? How does the lighting work with the old shader ?
This is with reflections disabled:
 

Attachments

  • D3D9Client_new_shader7.jpg
    D3D9Client_new_shader7.jpg
    649.2 KB · Views: 24

GLS

Well-known member
Orbiter Contributor
Addon Developer
Joined
Mar 22, 2008
Messages
5,878
Reaction score
2,870
Points
188
Website
github.com
We have had a capability to support instrument panel background lighting 5+ years already and I have never seen an application to actually use it.
I was not aware of that.... can you expand a bit? Is it what Martin did in the DG?
While in SSU, I played with (regular) lights in the vc, but the limits on the number of lights make it impractical (turn on a flight deck light and the PLB goes dark). Also, with with the lights off during the day, it was a bit too dark... it didn't seem to have the reflections to spread the natural light around. Other than that, the next obstacle was button lighting.
 

Felix24

Active member
Joined
May 13, 2010
Messages
245
Reaction score
95
Points
43
We have had a capability to support instrument panel background lighting 5+ years already and I have never seen an application to actually use it.
The SpaceX DM-2 crew Dragon capsule that brianj, Donamy and I worked on has instrument panel lighting. It requires the dll to switch between floodlit emissive textures and dark emissive textures. Or maybe you are referring to another method entirety?

The light was spread around the interior using Cycles raytracing in Blender then baked to the texture and exported.
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,429
Reaction score
680
Points
203
While on the subject of local lights, is there anyway of implementing a visible cone that shows the illumination zone of local lights?
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
The SpaceX DM-2 crew Dragon capsule that brianj, Donamy and I worked on has instrument panel lighting. It requires the dll to switch between floodlit emissive textures and dark emissive textures. Or maybe you are referring to another method entirety?
No, that is exactly what I was talking about. :)
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
This is with reflections disabled:
OK, Looks like I need to switch back to previous Earth shine model. Or try to figure how to fix that.
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,429
Reaction score
680
Points
203
OK, Looks like I need to switch back to previous Earth shine model. Or try to figure how to fix that.
Just to make sure there's no confusion: that's not Earth shine, that's the result of a single local light. Or are you saying that the Earth shine and local lights share the same lighting model?
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
In this experiment Earth shine comes from the environment map (reflection map) which can contain parts of the vessel itself lit by local lights. If the "FullScene" option is selected. So, through the env map local lights can contribute to global ambient light. This experiment would still require some work to get it to behave properly.
 
Top