And I always thought he was from Utah.Phong was a scientist from Vietnam who invented this shader, by the way
And I always thought he was from Utah.
It's difficult to give a number for this cause it can change a lot depending on what you have on screen.nAo, can you give a real-world number on the inefficiency you've seen coming from quad-based rasterization on polygon edges?
Phong is a very common Vietnamese name, it literally mean "wind".
I was talking about that. If we just had a if...endif block accumulating results for each light, why would there be register issues? There aren't even any texture accesses inside the branches.If you skip the whole computation than it's not an issue, but since you were talking about a FR I thought you wanted to handle more than a light in one pass, in this case you could skip a light, but you could still need to handle the remaning lights.
Ahh, but you're forgetting that with forward rendering you don't get that kind of load since you're not lighting pixels in screenspace. The door and the wall around it are simply a couple of occluders. All the hidden pixels are eliminated by early Z (which has the same granularity as a stencil mask), and the remaining pixels will pretty much all take the same branch.Umh, how can DB be so cheap? let say you have a light in a room and you can see some lit pixels (a very thing and long strip of pixels) only through an almost closed door, with DB an a decent granularit (say 64 pixels) you'd probably run your shader over tens of thousands pixels, with a stencil mask you might end up shading an order of magnitude less pixels.
Okay, so one of the points I was making was that with 4x AA you probably won't save much of this lost shading time, relative to FR, in a DR that used the compressed sample flag idea. On polygon edges the samples wouldn't be equal, so you'd have to do 4x supersampling there anyway, bringing your efficiency down to 25%. When lighting, rejection from the stencil mask also has 2x2 granularity. Moreover, the G-buffer pass already has the same inefficiencies of a FR.It's difficult to give a number for this cause it can change a lot depending on what you have on screen.
For example when artists forget to add a lod for that 30.000 vertices mesh that now is so distant that barely fills any pixel on screen, in that case efficiency is pretty bad..close to 25%, for that draw call. As a general rule of thumb I'd say that betwee 15% and 25% of your ALUs power go wasted but it really can change a lot according that you're displaying.
Well if you can afford a bit extra space in your attributes, a Polygon ID would give exact answer. I think 8 loworder bits from Z crosschecked against sample depth on some treshold would be enough.nAo said:Keep in mind that even checking all the geometry buffer attributes wouldn't give us the correct answer.
Do any developers here have a rough guess of the kind of improvement deferred rendering can provide?
No, there's not. A game is a complex system, you can't just write down a simple formula to describe its performanceLets take a game like Resistance Fall of Man. How much would it improve by using deferred rendering? For example, is there a rough calculation of how many more polygons or shaders it could push?
Lets take a game like Resistance Fall of Man. How much would it improve by using deferred rendering? For example, is there a rough calculation of how many more polygons or shaders it could push?
AlStrong,
That is exactly what I was thinking. I think it would be interesting if they could change rendering method from level to level.
However, in addition to lighting I've read that deferred rendering also helps increase the number of shaders and polygons you can push. I don't know if using a forward renderer in an outdoor sunny scene would be a good thing.
jon, are you referring to Mint's post on page 10 (and the subsequent discussion)?
"They" can, but that's so pointless.
Outdoor sunny scene has one light source - sun (you can drop all other lights because the sun intensity wins them all). Tell me now, how would you like to benefit from deferred here?