Page 1 of 13
FSWC's back in progress!

Posted:
Sat Dec 08, 2007 10:43 am
by Ashton Lawson
Hey guys,
For those of you following my progress on FSWC, I'm sad to say that it isn't going to be ready for a long time, and I mean quite long.
Basically, my PC's mobo seems to hate me more than anything, and it's been sent to Bangkok to be checked, and I won't get it back for two weeks, which means no developement, therefore no program.
However, the slightly better news is that, since I now know what's needed for the program to work, and I have the basic structure down, I'm going to reprogram it in C# (not a musical note), and recreate it completely so that it works with all FSX-supported operating systems, XP SP2 and Vista, 32-bit and 64-bit, and also support all versions of FSX, including all or no service packs, so that anyone can use the program.
I've also decided on adding extra features, which should allow me, or you, as the case may be, to edit these settings:
General Reflection Amount
Low-Angle Reflections (SP1 and lower)
High-Angle Reflections (SP1 and lower)
Specular Reflections
Wave Intensity
and hopefully a few more, which I have yet to experiment with.
Anyway, if all goes well there will be a single installer, that installs everything you need, system specific stuff and all, so it should be as easy as installing FSX itself (just without the long long waiting time and updates).
So, you won't be hearing from me in a while, not until my PC is back up and running.
See ya guys,
Str!ker
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 10:19 am
by NickN
I just saw this
I was wondering what happened to you.
I assumed you may be busy with school. Bummer about your system
Anyway, I have been busy and have not looked that this for some time. I thought perhaps you may still be reworking the code for the SP2 file but I see now you are down.
The original edited code used in SP1
};
#define fresnMin x.x
#define fresnMax x.x
half fresnel2( half3 vEyeDir, half3 vSurfaceNorm )
{
half frdot = min( 1 - dot(vEyeDir, vSurfaceNorm), 1 );
return lerp( fresnMin, fresnMax, frdot * frdot );
should still work although your other tweaks for specular will have to be refined. I never did fool around with it because I thought you were still working on it.
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 11:23 am
by NickN
Ok Str!ker I just looked this over and the original code does work to make water more reflective, however, unlike SP1 the frame hit is exactly the same. In SP1 the code allowed raising the water reflection slider to 2xMid with no hit and 2xHigh with a minor hit. With SP2 the frame hit is no different between the default and the code that allows higher reflections.
So there you have it. And to tell you the truth, the water was too reflective and even adjusting the min and max the results were not what I consider accurate for water. It was either a mirror or a pixelated mirror.
There is no performance gain by applying this to the SP2 shader file. All it will do in increase reflection but only if you raise the slider to 2xMed or 2xHigh in order to get cloud and land in the water.
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 12:40 pm
by NickN
I have completely confirmed all this now
It will give you high reflections but without the shimmer we got in SP1 so there is no need to fool with specular
But unfortunately it will not provide the high reflections without the same excact hit to performance in DX9 the default shader file produces and you must raise the slider to get the higher reflections.
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 1:52 pm
by NickN
If anyone wishes to try this, please note: I see no reason to do this edit other than increasing reflection because there is NO PERFORMACE benefit to making this change like there was in SP1
NOTE: THIS IS FOR SP2 or SP2 with Accleration ONLY. DO NOT USE THE FOLLOWING CODE FOR SP1
Back up your original Microsoft Games/Microsoft Flight Simulator X/ShadersHLSL/Terrain\Water20.fxh <-------- copy this to somewhere safe
Open the original file in notepad and COMPLETELY overwrite it with the following code:
[code]
//---------------------------------------------------------------------------
// Flight Simulator X - Shader Effect Files
// Copyright (c) 2006, Microsoft Corporation
//---------------------------------------------------------------------------
#include
#include
#include
#include
#define vLightDir vSunVectorWorld
// Potential textures
texture Water_BaseTexture
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 8:37 pm
by Barnes
Nick,
Thanks for reworking the shader file!
Looks great.
Dave
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 9:25 pm
by NickN
I did not rework anything. Originally I was sent a file by str!ker to test and I was out of the country so I asked someone to test it for me. It would not work in SP2 which is what I suspected because ithe one he edited was from SP1. When I got back I did not have time to look further into it and I assumed str!ker was still working on it. When I checked to see if he had posted anything on the subject I found this post so I did a quick edit into the SP2 shader file and checked it myself.
it works but not like it does in SP1. The amount of control is not there and the water appears too reflective. Mountain lakes have that type of reflection but not large bodies of water.
On top of that, the benefit we had with this in SP1 was 2 fold because the slider could be raised without a performance hit. In SP2 that is not the case.
Further, in looking at it I see that specular seems to have been broken down differently and there are other shader files which control that now.
In any case, its something to timker with but other than shallow reef and mountain lake water, it does not look right to me.
The ENV files need to be reworked which will also allow greater reflective quality, and, allow better dynamic color and brightness change to water as cloud cover increases.
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 9:53 pm
by alrot
You will say ,Alex is exagerating once again so I will just say.. Thanks Nick
trust me ,I did have to compress to much to reduce to 100k ,if you would see what I see


Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 10:35 pm
by NickN
You guys running slower cards, this may help make it look better. I can not say for sure. And, since you do not have full support like the 8000 series increasing the water slider may not apply the same hit as it would on a better video adapter.
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 10:52 pm
by alrot
Nick I can asure you this water moves and reflect much better, the last time I remember seing this water like this was before Sp1 , I took some shots too ..
It may be a slowest card , but 15 frps with a medium high sliders , man I feel very confortable ,or maybe I'm the lukiest man on earth 8-)
Re: FSWC's on halt

Posted:
Thu Dec 20, 2007 11:04 pm
by NickN
Nick I can asure you this water moves and reflect much better, the last time I remember seing this water like this was before Sp1 , I took some shots too ..
It may be a slowest card , but 15 frps with a medium high sliders , man I feel very confortable ,or maybe I'm the lukiest man on earth 8-)
Glad it is working for you my friend
enjoy

Re: FSWC's on halt

Posted:
Sun Dec 23, 2007 1:51 pm
by NickN
UPDATE 2nd GENERATION TWEAK
Apparently Pwheeler over at AVSIM has taken this a step further and added code to address specular sun reflections, and, remove the moon glow from water which was annoying. It also reduces the reflective surface at higher altitudes but still allows them at lower, as water should display. Its not perfect but you can try the new code here:
NOTE: MAKE SURE TO FOLLOW THE DIRECTIONS ABOVE WHEN CHANGING THE CODE IN THE FILE
This updates the specular but removes the moon water glow:
[code]
//---------------------------------------------------------------------------
// Flight Simulator X - Shader Effect Files
// Copyright (c) 2006, Microsoft Corporation
//---------------------------------------------------------------------------
#include
#include
#include
#include
#define vLightDir vSunVectorWorld
// Potential textures
texture Water_BaseTexture
Re: FSWC's on halt

Posted:
Sun Dec 23, 2007 2:16 pm
by alrot
UPDATE
Apparently Pwheeler over at AVSIM has taken this a step further and added code to address specular sun reflections, and, remove the moon glow from water which was annoying. It also reduces the reflective surface at higher altitudes but still allows them at lower, as water should display. Its not perfect but you can try the new code here:
aww Nick :-/ , what's pwheeler? well , Is this would change the nice moves and shining day of the watter like in the shot above? will be affected, ..but I didn't check(saw) how was the reflex of the sun and the moon... :-/ Im confuse
Re: FSWC's on halt

Posted:
Sun Dec 23, 2007 2:41 pm
by NickN
UPDATE
Apparently Pwheeler over at AVSIM has taken this a step further and added code to address specular sun reflections, and, remove the moon glow from water which was annoying. It also reduces the reflective surface at higher altitudes but still allows them at lower, as water should display. Its not perfect but you can try the new code here:
aww Nick :-/ , what's pwheeler? well , Is this would change the nice moves and shining day of the watter like in the shot above? will be affected,
Re: FSWC's on halt

Posted:
Sun Dec 23, 2007 2:52 pm
by NickN
Also, what it removes is the "glow' the moon makes on the entire water surface. I did not check it for the reflection on the moon itself
If you want the code which keeps all the moon glow but updates the rest, you can use this which I just edited special for you:
[code]
//---------------------------------------------------------------------------
// Flight Simulator X - Shader Effect Files
// Copyright (c) 2006, Microsoft Corporation
//---------------------------------------------------------------------------
#include
#include
#include
#include
#define vLightDir vSunVectorWorld
// Potential textures
texture Water_BaseTexture