• Some users have recently had their accounts hijacked. It seems that the now defunct EVGA forums might have compromised your password there and seems many are using the same PW here. We would suggest you UPDATE YOUR PASSWORD and TURN ON 2FA for your account here to further secure it. None of the compromised accounts had 2FA turned on.
    Once you have enabled 2FA, your account will be updated soon to show a badge, letting other members know that you use 2FA to protect your account. This should be beneficial for everyone that uses FSFT.

Nvidia Shader Replacement In Doom3

^eMpTy^

2[H]4U
Joined
Jul 21, 2004
Messages
3,233
So I was reading on some other forum and several people were in a bit of a fuss about shader replacement going on with nvidia cards and they referred to John Carmack's quote in the official benchmarks about how nvidia's drivers are tuned for thier blah blah blah...

Anyways...I know ATi and thier fansites like to talk about how nvidia does shader replacement...but I just don't get it...when did shader replacement ever hurt anything? Are there reviews or IQ comparisons that talk about this?

EDIT: HL2 just started preloading after I pressed the button like 20 times...sweet...1.0% and counting...
 
Too much beyond3d for you. :p They have convinced themselves that Carmack's comments refer to shader replacement when he never said that.

The nvidia performance tools like NVShaderPerf show that the same shader can run with a different GPU utilization but same number of clock cycles using different drivers. That is tuning, allocating the GPU's resources differently. That's funny because without shader replacements (and working around the AF stage0 "bugs") the last 2 ATI drivers also increased performance due to tuning. :rolleyes:

They refuse to ask Carmack to elaborate because they fear he will say the NV40 does not do shader replacements.
 
Maybe because John won't tell more? It has been asked more than once with the same generic response. Sooner or later someone will find out if it is true or not, just like everything else.

The point is this: why build a new card if it can not run standard DX / OGL without the need to replace everything? If both companies would just build cards to run great on open protocols we wouldn't have this crap.
 
^eMpTy^ said:
So I was reading on some other forum and several people were in a bit of a fuss about shader replacement going on with nvidia cards and they referred to John Carmack's quote in the official benchmarks about how nvidia's drivers are tuned for thier blah blah blah...

Anyways...I know ATi and thier fansites like to talk about how nvidia does shader replacement...but I just don't get it...when did shader replacement ever hurt anything? Are there reviews or IQ comparisons that talk about this?

EDIT: HL2 just started preloading after I pressed the button like 20 times...sweet...1.0% and counting...

The main reason people have intolerance for shader replacement stems from the developer side. Developers/Programmers make these games the way they want them, they are artists, and are presenting the game to you exactly how they want you to see it. When a third party changes their code, replaces a shader, makes it different, as a developer you feel stifled and ask the question, why is someone else changing my code?.

The argument is also if the shader replacement presents the same output as the developer intended then what's the difference?

Obviously this is a debate that will rage on and can only be dealt with on the developer side.
 
R1ckCa1n said:
The point is this: why build a new card if it can not run standard DX / OGL without the need to replace everything? If both companies would just build cards to run great on open protocols we wouldn't have this crap.

bingo, the API standards are there for a reason
 
Brent_Justice said:
bingo, the API standards are there for a reason

While I agree that ideally you'd just adhere to the standard and everything would run fine...I don't really think it's a big deal as long as image quality isn't compromised.

I've been poking around over at b3d and they harp on this shader replacement nonsense non-stop, so I was wondering if there was anything to it. Nvidia needed help with the nv30, that's why they got into the whole shader replacement game, and I think it was justified, they made major performance gains and everyone with thier cards got better performance out of the deal.

After some more digging I found that the only people who have raised any kind of fuss over this are ATi and 3dmark...and I've found zero evidence that it negatively affects image quality.

Funny that the same people over at b3d who can't stop talking about how shader replacement is the devil are the same people who have no problem with Carmack's comments about ATi's AF optimizations, and were championing Humus's "tweak" like it was the most amazing thing ever. Now if that's not hypocrisy, I don't know what is.
 
Shader replacment is fine in games so long as the output is not degraded.

Shader replacment is not fine in benchmarks. The idea of a benchmark is to create a test in which a specific amount of "work" is to be done in a given time frame. Shader replacement allows you to change the amount of "work" that card does and defeats the purpose of an A vrs B eqaul test. Granted you can not make everything equal... so sooner or later you have to just deal with it.

Another sticky point is games used as benchmarks.

...and I've found zero evidence that it negatively affects image quality

Then you have not done your home work. The very first generations of Shader Replacements by NV in 3dmark were easy to see.

Now if that's not hypocrisy, I don't know what is.

Thats a two way street. There are plenty of nV Fans that are ok with NV shaders replacement in Doom3 but dont think Humus tweak was vaild. Thats another example of hypocrisy.
 
Brent_Justice said:
bingo, the API standards are there for a reason

This is the same BS as the notorious kerberos login method for AD... no open standards, or lack of effort in documenting new commercial standards leads to poor performance and incompatibilities.

Microsoft and others listen up - USE OPEN STANDARDS!

This is why OpenGL, and POSIX were developed, for example.
 
Jbirney said:
Then you have not done your home work. The very first generations of Shader Replacements by NV in 3dmark were easy to see.

Got a link to an article that says as much? I couldn't find anything of the sort...

Thats a two way street. There are plenty of nV Fans that are ok with NV shaders replacement in Doom3 but dont think Humus tweak was vaild. Thats another example of hypocrisy.

It's all the same thing, ATI says thier AF optimizations don't change image quality, nVidia says their shader replacements don't change image quality...and the various camps ignore one while emphasizing the evil nature of the other...it all boils down to bullshit...
 
^eMpTy^ said:
Anyways...I know ATi and thier fansites like to talk about how nvidia does shader replacement...but I just don't get it...when did shader replacement ever hurt anything? Are there reviews or IQ comparisons that talk about this?

Vertex and Pixel shaders take in some input and output some data based on the input, a shader replacement is no problem when it yields the same output. The problem is when you make shader changes and the output is changed as well, if noticable or not, it isnt doing what was intended.
 
to see if they are doing any shader replacement all ya have to do is rename the exe :)
 
rancor said:
to see if they are doing any shader replacement all ya have to do is rename the exe :)

What will that do if they are detecting the specific code instance itself? Either way there's nothing wrong with the act itself, but making it a practice to do it sparingly on specific targeted games isn't exactly the best thing.
 
each line of code is written differently, there really is no way to mimic visual out put without knowing what the code is first. It has to detect the program first then it will know what to use and where. (this was way autosharder replacement with the nv 50 drivers didn't work so well, there was a noticable change in IQ)

Also if it was doing shader replacement it wil have different results in different games. That is something we haven't seen. Because if you compare between different cards the image is pretty much identical as long as aa and af is not in use
 
rancor said:
we aren't talking about the fx line.

to me it sounded like Jbirney was talking about the FX line in his original post

check it out

The very first generations of Shader Replacements by NV in 3dmark were easy to see.

that is what he said

which indicates to me since the first generation of shader replacement in 3dmark03 was done on the FX line that he is talking about the FX line
 
Brent_Justice said:
to me it sounded like Jbirney was talking about the FX line in his original post

check it out



that is what he said

which indicates to me since the first generation of shader replacement in 3dmark03 was done on the FX line that he is talking about the FX line


my bad yeah it was definitly there. but that would also not hold true now, from what I've seen the banding issues, where the fx line swtiched perscision of light shaders are gone with the newer drivers.

Halo was another place where there were missing or modified shaders, I don't see that anymore.
 
Jbirney said:
Thats a two way street. There are plenty of nV Fans that are ok with NV shaders replacement in Doom3 but dont think Humus tweak was vaild. Thats another example of hypocrisy.

Did the Humus tweak replace the shader or simply run the same shader through math?
 
R1ckCa1n said:
Did the Humus tweak replace the shader or simply run the same shader through math?

changed the shader, thats what shader replacement is.

It took out the gloss map texture look up and used a pixel shader to calculate the gloss levels.
 
Any chance the guys from [H] can ask Carmack to elaborate on the statement that is in question? I'd like to know if Nvidia is doing this once and for all.

-Nathan
 
IF output is the same (or 99.9% the same) it shouldnt matter. Hardware has built in functions(routines,etc) which drivers can change the way they are handled. Often times Nv or ATI can tweak it b/c they know their hardware better than game developers.

I think some developers get their feelings hurt b/c Nvidia has better programmers than them and its an ego issue when Nvidia takes their baby (engine) and can give you 99% the same appearance with 50% more performance.

Granted if IQ is sacrificed (to a noticeable amount ie: to the naked eye with out zoom or image overlays to show the difference, etc.) then there is a problem. But most of the time the only way to detect an optimization is to overlay the images from a software rendered screenshot and highlight the differences. And if you have to do that... you obviously need to find better things to do with your time.
 
rancor said:
Also if it was doing shader replacement it wil have different results in different games. That is something we haven't seen. Because if you compare between different cards the image is pretty much identical as long as aa and af is not in use

Not true. ATI was also gulity of shader replacement in 3dmark2k3. The admited to this and said they would pull it out. It only effectct GT4 and provided the same IQ. No one ever was able to show any difference. So not all shader replacements give IQ differences.

We really cann not deal with JC statement about NV drivers. Why? You know its JC. Every time he answers a qustion, there are more things left to answer. So there are many ways to interput what he said....

chrisf6969,
your on a very slippery slope. Who is gonna to say if IQ differences are ok? And what is noticable to you may not be to the next. For example Brent here can probably pick things out that you and I may not. Then there are people much better than Brent, and people much worse than you and I. I feel its up to the developer to ensure the IQ is ok, after all only they know what the "correct" image is supposed to look like.....
 
Jbirney said:
Not true. ATI was also gulity of shader replacement in 3dmark2k3. The admited to this and said they would pull it out. It only effectct GT4 and provided the same IQ. No one ever was able to show any difference. So not all shader replacements give IQ differences.

We really cann not deal with JC statement about NV drivers. Why? You know its JC. Every time he answers a qustion, there are more things left to answer. So there are many ways to interput what he said....

chrisf6969,
your on a very slippery slope. Who is gonna to say if IQ differences are ok? And what is noticable to you may not be to the next. For example Brent here can probably pick things out that you and I may not. Then there are people much better than Brent, and people much worse than you and I. I feel its up to the developer to ensure the IQ is ok, after all only they know what the "correct" image is supposed to look like.....

How was this shader replacement found then? There has to be some way of finding it if I remember correctly it was found by renaming the exe.....

Thats why if there is shader replacement going on and it looks like the original shader there needs to be application detection because a shader can't be made by the driver with exact outputs as the orginial shader. The new shader has to be hand written.
 
You guys are missing the point.

API's are made for a reason......... Imagine the day when developers can code to an API instead of making up for certain IHV's shortcomings. Developement time would be shortened, meaning MORE GAMES. IHV's could spend more time on hardware than writting software for their hardware.
 
R1ckCa1n said:
You guys are missing the point.

API's are made for a reason......... Imagine the day when developers can code to an API instead of making up for certain IHV's shortcomings. Developement time would be shortened, meaning MORE GAMES. IHV's could spend more time on hardware than writting software for their hardware.

the key is efficient shader compilers in the video card drivers
 
The only known shader replacement for Doom3 at this point is the ATI/Humus shader replacement.

Based on the tweaking that has been done with interaction.vfp it looks like there aren't any for NV40.
 
tranCendenZ said:
The only known shader replacement for Doom3 at this point is the ATI/Humus shader replacement.

No John C has more or less stated that there is some by NV drivers.
 
tranCendenZ said:
Based on the tweaking that has been done with interaction.vfp it looks like there aren't any for NV40.


What do you mean? I am sorry if i am being a little dense. 3d programming is beyond my understanding.
 
Jbirney said:
No John C has more or less stated that there is some by NV drivers.

Actually he hasn't for NV40. If there are any in there, they are probably for NV30.
 
tranCendenZ said:
Actually he hasn't for NV40. If there are any in there, they are probably for NV30.

JC's own words:

On the other hand, the Nvidia drivers have been tuned for Doom's primary light/surface interaction fragment program, and innocuous code changes can "fall off the fast path" and cause significant performance impacts, especially on NV30 class cards.

Notice how he says especially on NV30 class cards.. Pretty clear indicator that they are happening on ALL NV cards. Again this is not a bad point in itself. But makes you woner if ATI can get better Doom 3 perfromance with their own "tunning of Doom's primary light/surface interaction fragment program" :)
 
tranCendenZ said:
The only known shader replacement for Doom3 at this point is the ATI/Humus shader replacement.

Again, did the Humus tweak replace the shader or simply do it a different way? It was my understanding it did not replace it but simply did the same shader a more efficent way, via math.
 
Jbirney said:
Notice how he says especially on NV30 class cards.. Pretty clear indicator that they are happening on ALL NV cards.

No it isn't.

Again this is not a bad point in itself. But makes you woner if ATI can get better Doom 3 perfromance with their own "tunning of Doom's primary light/surface interaction fragment program" :)

Ever heard of the "Humus tweak?"
 
R1ckCa1n said:
Again, did the Humus tweak replace the shader or simply do it a different way? It was my understanding it did not replace it but simply did the same shader a more efficent way, via math.

heh, shader replacement means the original shader code was replaced with new shader code. The humus tweak replaces the original shader code with new shader code. It has a similar output but is not the same thing.
 
R1ckCa1n said:
Again, did the Humus tweak replace the shader or simply do it a different way? It was my understanding it did not replace it but simply did the same shader a more efficent way, via math.

Yes he replcaed the shader's look up call with the math call. If you even change one line in a shader, its a "new" shader, and thus you just did your own "shader replacement".
 
So what's the verdict? Both ATI and Nvidia have shader replacement but ATI's seems to be the only one that causes the occasional problem. I fail to see the problem.
 
tranCendenZ said:
No it isn't.

Only certian IHV fans have a trouble understand what was said in that quote from JC. But again its JC and all of his post can be interupted differently.
 
The Batman said:
So what's the verdict? Both ATI and Nvidia have shader replacement but ATI's seems to be the only one that causes the occasional problem. I fail to see the problem.

How in the world did you come to that conclusion. Humus (who works at ATI) made a tweak in the doom shader code and shared that with people. Thats not the same thing as shader replacement by the drivers.
 
Jbirney said:
How in the world did you come to that conclusion. Humus (who works at ATI) made a tweak in the doom shader code and shared that with people. Thats not the same thing as shader replacement by the drivers.

It really doesn't matter Humus tweak or mod or what ever doesn't really improve performance there wasn't any huge performance benfits like he stated. Just thats when doing af with the ati contol panel it caused artifacts which inturn didn't show the full potential of the ati cards. Now the benchmarks [H] did they used af within the game, so there was none of these artifacts. and there was no performance loss. So the benchs that you see by [H] are purely valid even if the tweak was there. And this shows you that ATi's drivers are interfereing with a shader pure and simple.
 
tranCendenZ said:
heh, shader replacement means the original shader code was replaced with new shader code. The humus tweak replaces the original shader code with new shader code. It has a similar output but is not the same thing.
No one would have complained if the Humus hack was an identical replacement. It was a simple power approximation of the values encoded in the table. It doesn't give the same values that Carmack encoded in the original table ("The specular function in Doom isn't a power function, it is a series of clamped biases and squares that looks something like a power function"). Not that I have to tell you that. ;)

I still find it funny that no one on B3D wants to take up Carmack on this: "The lookup table was faster than doing the exact sequence of math ops that the table encodes, but I can certainly believe that a single power function is faster than the table lookup." :p
 
Back
Top