Welcome, Guest. Please Login or Register
YaBB - Yet another Bulletin Board
  YaBB is sponsored by XIMinc!

FFDS Home | TIPS Section | Tutorials Section | Resources Section | Utilities Section

Military | FSDS | Jetliners | Real Planes Section | Gmax | Rotorcraft | Business | Civilian

  HomeHelpSearchLoginRegister  
 
 
Pages: 1 
Send Topic Print
Scenery Lighting in FSX (Read 5970 times)
17th Feb, 2010 at 11:44am

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Good day gentleman

I have been following the post by Jon Blum’s and Bill Leaming on night lighting for FSX and Bill has been very kind to send me his Gmax files for me to study and offer some good explanation as to how he set the materials set up in gmax.

But I am stuck on a critical setting “Blend diffuse by inverse of specular map alpha”

I tried manually tweaking the “_exterior.x” file in the main FSDS folder but I am not 100% sure if this is the X file I should be working on and where I should do this with in that file any thought would be most appreciated.

I will try to include a screen shot of my tweak page ( never add a shot this way before)

My textures are
Farfy_427.bmp---All black with a black Alpha saved as DXT3
A_test_night_10.bmp  ---very light yellow with a white alpha saved as DXT3
A_test_night_11.bmp --- black with a white splash with a white alpha saved as DXT3

Scott
Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 
IP Logged
 
Reply #1 - 17th Feb, 2010 at 11:59am

Rick_Piper   Offline
LDV Engineer
No thanks!

Posts: 382
****
 
Hi Scott

it's there mate

bottom right 4 tick boxes up  Wink

Regards
Rick

Edit i see what you mean no blend specular in there  Huh (come on DN more work for you mate!) Grin

Dave should spot this thread and answer at some point but i know he is a bit busy currently with real life stuff (looking at new Boeings that look just like the Old ones to me) Roll Eyes
 
IP Logged
 
Reply #2 - 17th Feb, 2010 at 12:03pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
What is the purpose of this bitmap?
Quote:
Farfy_427.bmp---All black with a black Alpha saved as DXT3


Only two bitmaps are required by this method. One for the Diffuse Color and the other for both Specular Color and the Self-Illumination...

Just for information, here is the "recipie" from the GMax FSX Material:

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #3 - 17th Feb, 2010 at 12:20pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
Here is the "recipie" for the actual bitmaps.
The Diffuse Color is a tiny 32x32 pixels. It is used only to define the color of the lightsplash generated by...
The Specular Color bitmap, which is 256x256 pixel (or larger if needed!):

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #4 - 17th Feb, 2010 at 1:31pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Rick thanks for having a look, but I am trying to find

“Blend diffuse by inverse of specular map alpha”
I have tried both “Blend env by inverse of diffuse alpha” and “Blend env by specular map alpha’ these don’t seem to be the ones I need.

EDIT LOL you guys are changing and adding post faster that I can rework and test my model ..I love it thanks.


Hello Bill
I use that texture 427 to make my object transparent and also to give FSDSxTweak a file to work from if I don’t apply any texture FSDSxTweak doesn’t work.

Let me try  again.

Scott
 
IP Logged
 
Reply #5 - 17th Feb, 2010 at 2:00pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Guys

The day time part is looking the best I have had yet but the night part is now no good hehe. You can see the edges because I just made a cube 200 X 200 X 1

I made a new texture all white with a white alpha.
I used this as the texture on the polygon so that FSDSxTweak has something to work from and also used this in the diffuser slot I will attach screen shots.

Scott

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 
IP Logged
 
Reply #6 - 17th Feb, 2010 at 2:36pm

Rick_Piper   Offline
LDV Engineer
No thanks!

Posts: 382
****
 
Hi Scott

I still don't think youu need the spec diffuse thing as FSDS needs any transparent material to be named Glass_or Prop_ or Trans_ etc

the alpha will automatically do what it's supposed to do once it knows it's transparent (ignore the tweak setting) but make sure the material is called as above

worth a try mate

Regards
Rick
 
IP Logged
 
Reply #7 - 17th Feb, 2010 at 4:34pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Rick
My very first attempts at this I did call the part “trans” but I have made so many version since then ….I will go back and re-look at that.

Thanks  Scott
 
IP Logged
 
Reply #8 - 17th Feb, 2010 at 5:48pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
Ah, the absolute joy of translating Max/GMax speak into FSDS speak!  Grin

Note that the Blinn Properties of the FSX Material is set to zero, so using "trans" (whatever that is) may be what's needed here. Also note that the Blinn Color and Specular is set to triple-zeros as well.

The purpose of using Blend diffuse with inverse of Specular Alpha is to force a better gradient blending of the spec's lightmap with the diffuse color.
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #9 - 17th Feb, 2010 at 6:13pm

DaveNunez   Offline
YaBB Moderator
Seattle, Washington

Gender: male
Posts: 504
*****
 
Special FSDS names are likely not to be the issue here - those names are used by FSDS to generate the .x files, by the time FSDSxTweak gets to it, the names mean nothing special any more.

Fr Bill, what happens if you remove the "Blend diffuse by inverse of specular map alpha" option in Gmax? Will you get the same issue as Scott is seeing?

I am noticing that I do not have that switch available, I am wondering if that is the issue.
 

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register&&Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
&&
IP Logged
 
Reply #10 - 17th Feb, 2010 at 6:47pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Guys

I have re-worked my model about 5 times with the part named “Trans”
And it doesn’t seem to matter.
I have three variations that give me a nice look during the day but no good at night and two variations that don’t work during the day but do work at night.

I am going to switch the alpha channels and build a few more models.

Dave is there a way I can manually tweak that setting?
“Blend diffuse by inverse of specular map alpha”

Thanks for your help guys
Scott
 
IP Logged
 
Reply #11 - 17th Feb, 2010 at 11:26pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
DaveNunez wrote on 17th Feb, 2010 at 6:13pm:
Fr Bill, what happens if you remove the "Blend diffuse by inverse of specular map alpha" option in Gmax? Will you get the same issue as Scott is seeing?

I am noticing that I do not have that switch available, I am wondering if that is the issue.


The purpose of using Blend diffuse with inverse of Specular Alpha is to force a better gradient blending of the spec's lightmap with the diffuse color.

One could simply put the lightmap texture in both Diffuse Color and Self-Illumination, but it won't blend as well...
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #12 - 18th Feb, 2010 at 12:08am

DaveNunez   Offline
YaBB Moderator
Seattle, Washington

Gender: male
Posts: 504
*****
 
Scott can you please send me your files for me to play with? I need your textures, your KFG file, and the _temp.X file that FSDS produces on compile (alternatively, your .FSC file will do).

Sounds like we may need a couple new features to the tweaker, so your problem would be a nice test case for these.
 

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register&&Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
&&
IP Logged
 
Reply #13 - 18th Feb, 2010 at 9:15am

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Dave

I will put a couple of zips together with those files the one that looks best in the day and the other that works at night.
I have to go to work right now but later today

Thank You ..Scott
 
IP Logged
 
Reply #14 - 18th Feb, 2010 at 3:05pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Dave zip is sent

Thanks again
Scott
 
IP Logged
 
Reply #15 - 18th Feb, 2010 at 4:50pm

DaveNunez   Offline
YaBB Moderator
Seattle, Washington

Gender: male
Posts: 504
*****
 
Got it, I will investigate.
 

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register&&Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
&&
IP Logged
 
Reply #16 - 19th Feb, 2010 at 7:59pm

DaveNunez   Offline
YaBB Moderator
Seattle, Washington

Gender: male
Posts: 504
*****
 
Looks like we are missing some switches on the tweaker!

Fr. Bill, what does your fresnel ramp look like? I can get it all to work, but during the day, the light splash appears as if it were a shiny specular highlight on the model.
 

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register&&Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
&&
IP Logged
 
Reply #17 - 20th Feb, 2010 at 7:31pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
DaveNunez wrote on 19th Feb, 2010 at 7:59pm:
Looks like we are missing some switches on the tweaker!

Fr. Bill, what does your fresnel ramp look like? I can get it all to work, but during the day, the light splash appears as if it were a shiny specular highlight on the model.



It is nearly pure black... 256pX4p, RGB:19,19,19 A:256,256,256, DXT1 ARGB  4 bpp | 1 bit alpha

I get no light whatever during the daytime.
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #18 - 20th Feb, 2010 at 8:43pm

DaveNunez   Offline
YaBB Moderator
Seattle, Washington

Gender: male
Posts: 504
*****
 
That did the trick. It needs the fresnel to be applied, plus the BlendDiffuseByInverseSpecularMapAlpha tag in the material. I am cooking up a new release of FSDSxTweak to accomodate this new switch and a couple of other small things. Release hopefully by the end of this coming week!
 

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register&&Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
&&
IP Logged
 
Reply #19 - 20th Feb, 2010 at 9:21pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Thank You Dave.
And you too Bill, I appreciate your help.

Now I am like a kid waiting for Santa Claus.

Scott
 
IP Logged
 
Reply #20 - 20th Feb, 2010 at 10:18pm

PutPut   Offline
Inspecteur des Polygonnes
I have a life; I still
use FSDS!
Long Beach, Ca.

Gender: male
Posts: 671
*****
 
Dear Santa,  Don't forget a certain chimney in Long Beach! Wink  Now, I'll go back to the SDK's and see what fresnel ramps are all about!  Never too old to learn!

Paul

 
IP Logged
 
Reply #21 - 20th Feb, 2010 at 11:20pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
You won't find any real explanation in the SDK, unfortunately.

Well, truthfully in this particular instance the fresnel ramp is doing something it really doesn't normally do... It's being used to "kill all specular shine and reflectivity" so the "light poly" is invisible during the daytime.

Fresnel ramps are used to affect a material or texture based on the angle of incidence between your view and the direction each polygon in the object faces. If you're looking at a ball then a fresnel ramp could be used to change how the part of the ball directly facing you looks versus how its edges that are facing away from you are shaded. So you could have the parts of the ball facing away from you tinted blue, and the rest red for instance. They can also control translucency in the same way. You can achieve some really amazing effects with them.

Likewise, the specular map is being used in a non-intended way.

Specular maps on aircraft models basically control the shininess of of things, but they allow control on a per pixel basis rather than a global setting in a material like FS9 had. So with a specular map you can have say a black nose hood be a lot less shiny and 'glinty' than say a polished aluminum part. They can also be used to change the colour of the hotspot where the sun actually hits an object, making it slightly yellow or blue or whatever. In a specular map the RGB colour channels control the colour and intensity of the hotspot highlights and the alpha channel controls how sharp or broad the hotspot is. As an example both an orange and an apple are specular but an orange has a broader and lower intensity hotspot whereas the polished apple is much more 'specular' with a brighter smaller hotspot. Specular maps are great because unlike bump maps they cause very little performance hit.

Both of these ideas came to us via Jon Blum. I really don't know where he came up with the idea, but it is brilliant!

The above explanations for frenel ramp and specular maps was provided by Mike Johnson (Lotus) in a thread from last year at AVSIM: Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #22 - 20th Feb, 2010 at 11:40pm

PutPut   Offline
Inspecteur des Polygonnes
I have a life; I still
use FSDS!
Long Beach, Ca.

Gender: male
Posts: 671
*****
 
Bill,  Thanks for that.  It is a very concise understandable explanation.  I have been successfully using specular maps but have never used a fresnel ramp.  Your explanation opens up new avenues to try.

Paul
 
IP Logged
 
Reply #23 - 20th Feb, 2010 at 11:53pm

Au-MaV   Offline
Inspecteur des Polygonnes
Whatcha lookin at
Adelaide South Australia

Gender: male
Posts: 1956
*****
 
Hi
Ill add to Bills info above
that Dxtbmp does not like to open fresnel ramp in dds mode.but are fine when they are converted to bmp's
I tend to use IrfanView to view them,then save them as bmp's so I can edit them.

Wozza

 
 
IP Logged
 
Reply #24 - 28th Feb, 2010 at 5:52pm

DaveNunez   Offline
YaBB Moderator
Seattle, Washington

Gender: male
Posts: 504
*****
 
Update is complete! Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register&&Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
&&
IP Logged
 
Reply #25 - 28th Feb, 2010 at 6:50pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Thank You Dave.
I can’t wait to light up the streets with a new light.
….I guess I should build a new power plant to run them LOL

Scott
 
IP Logged
 
Reply #26 - 28th Feb, 2010 at 8:53pm

Fr. Bill   Offline
Inspecteur des Polygonnes
I used to have a life:
now I have GMax...
Hammond, IN

Gender: male
Posts: 5426
*****
 
Have fun, Scott. I certainly am! Check out my latest post in the 33MO - Leaming Field thread in the WIP forum...  Wink
 

Fr. Bill
Gauge Programming - 3d Modeling Eaglesoft Development Group Intel Core 2 Quad Q6600-4 GB DDRII Crucial PC6400-500 GB SATA-ATI Radeon HD2400 Pro 256MB
IP Logged
 
Reply #27 - 2nd Mar, 2010 at 7:47pm

H_Farfy   Offline
Point Pusher
I Love FFDS!

Posts: 34
*
 
Hi Guys
Quote:
Check out my latest post in the 33MO

Oh Man that looks great Bill, I am going to try the light cone next.

I have my light working
Thank You to all that helped.

I have been playing with this to see what works best.

I am not sure if I am doing this as efficient as I could but this is what I have done.

For Street Light FSX 4
Farfy 430 is the texture that I put on the polygon on the ground it is white with a white alpha channel.

Farfy 431 is black with a white splash and a white alpha channel.

Next I played with the texture that was in the diffuse slot, it was white and I changed it to orange. But this did not give me a orange light next I took it out all together…it doesn’t seem to do anything for me so I left it out.



So to get an orange light splash I tried a few things in the end I made a new texture and a new light Street Light FSX 6 the only thing I change was Farfy 435. It is black with an orange splash and a white alpha.

The last one a played with is the Fresnel Ramp, I made one that Jon Blum talked about 18,18,18 with a white alpha. Light looked ok, next I made one that was pure black with a white alpha, I didn’t see any change so I left it out and the light seems to work just fine.


Do the textures in the Diffuse and Fresnel Ramp do something that I just don’t understand?


Scott
Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register

Multimedia File Viewing and Clickable Links are available for Registered Members only!!  You need to Login or Register
 
IP Logged
 
Pages: 1 
Send Topic Print