Will Valve include full shadowing?

DEATH eVADER

Space Core
Joined
Nov 10, 2003
Messages
8,142
Reaction score
19
With the talk and discussion on HDR recently, I thought I would come up with shadow capabilities of the source engine at the moment.

The most apparent is that the shadows seemed to be on the tender side, i.e. everything casts only one shadow rather than multiple shadows (Doom3, Quake4, and when it comes out Stalker).

I've also noticed (unlike the bracketed games) that brushed entities, such as doors, do not block light coming through. Ican understand a bit of light through the bottom of the door, but the door doesn't block any light whatsoever.

I would like full shadows to be added as an option

What is your view on the use of shading and shadow?
 
that would require redoing the whole engine and the shadows you are talking about are dynamic shadows. it would look nice in source though
 
giant384 said:
that would require redoing the whole engine and the shadows you are talking about are dynamic shadows. it would look nice in source though

Don't speak on what you know not of.
 
It wouldn't require a redo of the whole engine. Yes lots, but not the whole engine. No doubt Valve will add this into source someday but not anytime soon.

Death you don't understand how light works with Source and alot of other engines.(Like the BF1 engine for instance).
Basically all light is calculated beforehand(Though there is dynamic lights they arn't that good).
Thus doors wont block light. Because a door is dynamic, since the door can change position casting light for it would be bad when you have a world full of dynamic objects(physics). So they basically calculate through the door when the map is compiled.
 
They probably will introduce dynamic shadows eventually, but I would guess not for another year at least. The problem is, dynamic lights & shadows were developed a few years ahead of time. As you all recall, Doom3 was the first to use these things, and that was 2004. And, while it certainly looks great, such rendering is very computer resource intensive. Doom3, when it came out, was by far the most demanding game at that time, and that with rather low-poly models or low-res textures.

Now, you'll see FEAR, a game also using dynamic shadows, requiring a load of system resources. Quake 4 is also very computer intensive. And at that, FEAR has no big environments and Quake 4 doesn't have any special particle effects or physics.

My point? Current computers can't really handle fully dynamic lighting & shadowing. A year ago they sucked at it, now they're slightly better, but still, it's very taxing for even the high-end computers. This is why games that have dynamic L&S seriously cut down on something else. Like FEAR for example cutting down on environment size or Quake4 saving resources by having very few physics-related calculations.

Half-Life 2 has some good textures and models and, more importantly, outdoor spaces and loads of physics. These elements make it take the computer resources that it does. Adding dynamic L&S on top of that would make HL2 intolerably sluggish on all computers. Consider, Doom3 is a beast to run because it calculates the shadows from that zombie and each crate in the room for every frame. Now imagine if it had to also calculate the physics of that crate flying through the air, hitting the zombie and it flying back, while not forgetting to recalculate the shadows of them all. Thus, you should be able to see why dynamic L&S in the Source engine would be a bit too early just now...
 
I'd like to see maybe not fully dynamic stencil shadows but for Valve to use a similar shadow system to max payne 2 or bloodlines. I think those are bascially bitmaps thats react to the closest light source. That wouldn't be too taxing.

I'm not fussed though because the golden rule of thumb is gameplay over graphics. I'd rather see them upgrade some of the physics engine as it starts to age.
 
Solver said:
They probably will introduce dynamic shadows eventually, but I would guess not for another year at least. The problem is, dynamic lights & shadows were developed a few years ahead of time. As you all recall, Doom3 was the first to use these things, and that was 2004. And, while it certainly looks great, such rendering is very computer resource intensive. Doom3, when it came out, was by far the most demanding game at that time, and that with rather low-poly models or low-res textures.

Now, you'll see FEAR, a game also using dynamic shadows, requiring a load of system resources. Quake 4 is also very computer intensive. And at that, FEAR has no big environments and Quake 4 doesn't have any special particle effects or physics.

My point? Current computers can't really handle fully dynamic lighting & shadowing. A year ago they sucked at it, now they're slightly better, but still, it's very taxing for even the high-end computers. This is why games that have dynamic L&S seriously cut down on something else. Like FEAR for example cutting down on environment size or Quake4 saving resources by having very few physics-related calculations.

Half-Life 2 has some good textures and models and, more importantly, outdoor spaces and loads of physics. These elements make it take the computer resources that it does. Adding dynamic L&S on top of that would make HL2 intolerably sluggish on all computers. Consider, Doom3 is a beast to run because it calculates the shadows from that zombie and each crate in the room for every frame. Now imagine if it had to also calculate the physics of that crate flying through the air, hitting the zombie and it flying back, while not forgetting to recalculate the shadows of them all. Thus, you should be able to see why dynamic L&S in the Source engine would be a bit too early just now...

so then i suppose from ur descriptions, games come down to one of two things...limited lighting and shadows which allows open and complete areas or full lighting and shadows and the sacrifice becomes these open and complete areas.

generally speaking, gamers love open and complete areas and so thats why Half Life2 has been (and its mods) and continues to be the game of choice...that is until hardware technology catches up to the software part of it.
 
There is a way to render shadows cast by models using a Full Scene Pixel Shader, akin to the dynamic tonemapping for HDR. The problem with this is that I suspect that it might be incompatable at some level with HDR. If now however it would be possible to store lighting info in the map so that dynamic shadows could be rendered using the PS.
 
I think it'll be a long time until we see dynamic lighting and shadows in Source games. Even if dynamic shadows from the first-order lighting (likely using omni shadow mapping, which by itself is insanely performance prohibitive, moreso than the shadow volumes that Doom3 (and it's offspring) and FEAR use) are placed on top of the precomputed lighting, the visuals would be extremely inconsistent. You'd see shadows from players that are smooth and soft, but then right behind the player could be a very wide and chunky shadow from, say, a pillar that is going at the same angle. Right now the single directional shadow works out pretty well by comparison.

It's entirely possible that if Valve releases a large update enabling D3D10 support that omni shadow maps will be included as a part of it, since there are a LOT of new API features that will make them much, MUCH more practical to do on graphics hardware.

Actually, at one point I looked over the SDK to see if it would be possible to do omni SMs in Source through 'just' a mod, but sadly it doesn't seem like enough of the graphics pipeline is exposed to be able to do it (unless render-to-cubemap support is there but hasn't been found yet).
 
And also shadows cast on everything. Start up LC and look at the fisherman's shadow. It only appears on some planks.
 
Source probably has a very modular design. In order to implement dynamic shadows wouldn't require too much hacking at the main source code but there're a few considerations to take into account: such as performance.
 
Dr. Freeman said:
so then i suppose from ur descriptions, games come down to one of two things...limited lighting and shadows which allows open and complete areas or full lighting and shadows and the sacrifice becomes these open and complete areas.

generally speaking, gamers love open and complete areas and so thats why Half Life2 has been (and its mods) and continues to be the game of choice...that is until hardware technology catches up to the software part of it.

As of right now, yes, that's my idea. Something certainly has to be sacrificed for dynamic lights and shadows. It's either the openness of environments or physics or something else. The Doom3 engine is great (you have to admit that whatever you may think about the game), and Quake 4 is a prime example of that. Quake 4 further improved the engine, manages to have outdoor spaces (not Far Cry huge, but certainly big) and battles with 5-6 enemies at a time. What Quake 4 sacrifices is physics. It has a physics engine, but it's hardly ever used. And, some textures are low-res.

The FEAR engine is, I think, slightly weaker, and it sacrificed outdoor environments completely. It does, though, have amazing textures, too.

This is really quite amazing, actually. In the past, software hadn't been ahead of hardware. Previously, the best games made ran on top-of-the-line software. When Doom2 came out (and I remember being angry at it barely running), it ran well on the best machines. Ditto Half-Life, Quake 3, Unreal Tournament, etc. These games provided the best graphics and other things they could make, and ran well. Now, a game providing the best of everything wouldn't run, so essentially developers have to choose what they'll sacrifice.

While I am a big fan of dynamic lights and shadows, I like Valve's decision with HL2. They went for relatively very simplistic lighting and shadowing model, but they didn't sacrifice gameplay at all, they made the environments they wanted and also had great graphics. The engine's also great, though.
 
WhiteZero said:
lol
Don't refute what someone is saying without something to back yourself up with.

He shouldn't have to back himself up on that one. Valve have stated several times that the engine incredibly modular, allowing for pieces to be taken out, and new pieces to be put back in.
 
Yep, Source is a modular engine. Doesn't mean it's easy to add new stuff, but means that it was built with the idea that new features would be added.
 
Valve just needs to move the lamp in the sky a bit to the right. That would fix everything.
 
I e-mailed Valve about dynamic lights and shadows, like a year ago.
I don't have a copy of the reply anymore, but it went something like this:

"Yes, it's possible, but we don't have a date on that".

When I look at Doom 3 and Quake 4, they look amazing. The shadowing is just cool. When I play FEAR, it also looks just nice, except for a few levels at Armacham - multiple light sources and pitch black shadows.

And that is the main problem of today's hardware.

The rendering of dynamic shadows takes so much of GPU power, it's impossible to calculate light bouncing in real time.

Wait for the nightfall. Get a small room lamp. Put it somewhere in your room to create as much shadowing as possible. What do you see? No shadow is pitch black!
Creating non-pitch-black shadows in a game like Doom 3 requires smart placement of multiple light sources. It's pretty ineficient ;)

I think Unreal Engine 3.0 can do real-time light bouncing off specific materials. If it can not do such thing, it's just a tweaked Doom 3 engine.


ps - another issue is smooth shadows. Shadows in Doom3/FEAR are extremely sharp, pixel-to-pixel. Sure, you can turn on "smooth shadows" in FEAR, but this method simply renders like three shadows with different intensity and puts them all together and each is smaller than the second. Do I have to say what performance impact it has? :P
 
The problem isn't so much the GPU power to render the shadows, but the CPU power to calculate them (and the lights). Yep, FEAR has those smooth shadows, but they're an even worse performance hit. And I greatly love the dynamic lights and shadows in Doom3 and Quake4, they just somehow make the world look completely amazing.

BTW, little-known fact. Doom3 has a disabled feature (can be enabled through text files) where the plasma gun projectiles light up the environment dynamically. It looks absolutely amazing, but brings such a performance hit that it's disabled for good - and won't be on even if you set the game to highest settings, you got to enable that yourself.
 
Kazuki_Fuse said:
I'd like to see maybe not fully dynamic stencil shadows but for Valve to use a similar shadow system to max payne 2 or bloodlines. I think those are bascially bitmaps thats react to the closest light source. That wouldn't be too taxing.

I never noticed that in Bloodlines, its basically running of the same engine (abeit a pre-hacked version)

dreten said:
Parallax mapping would be nicer i guess...

I agree, especially for the cobbled backstreets. Some site stated in a preview that the paralx mapping used ingame was great, I just couldn't see any examples of paralax ingame at all
 
Solver said:
The problem isn't so much the GPU power to render the shadows, but the CPU power to calculate them (and the lights)

?? I'm not sure about that. Doom 3 has very little CPU lag for me (p4 2.4ghz) but the framerate gets slaughtered when the full shadow settings are on (ati 9600se). I think it has everything to do with the GPU. Correct me if I am wrong.
 
The CPU has a lot to say in that matter. As far as I know, a ~2GHz processor is not enough to transfer enough data to the graphic card. But I might be wrong.

But it's natural Radeon 9600SE struggles with Doom 3, it's a card that can be compared to Radeon 9000/9200, only with DirectX9 support.

edit - take a look at my system specs in my sig. I have a better graphic card than you, but I can't play Doom with shadows on. It just slows down to a crawl when an enemy shows up - and it's a slide-show when there are two imps at once. A friend of mine, with a Sempron 3000+ and a Radeon 9600Pro can play the game with no major slow downs and gets much higher timedemo results than I do. I never get more than 35fps, no matter the resolution or detail settings (with shadows). He gets over 50fps in 800x600/high.
 
DEATH eVADER said:
I never noticed that in Bloodlines, its basically running of the same engine (abeit a pre-hacked version)
Bloodlines rocks. And running through alleys watching your shadow shift is lovely :p
 
StAtiC said:
?? I'm not sure about that. Doom 3 has very little CPU lag for me (p4 2.4ghz) but the framerate gets slaughtered when the full shadow settings are on (ati 9600se). I think it has everything to do with the GPU. Correct me if I am wrong.

You have no way to reliably tell in-game whether your FPS drop is because of lack of power to calculate or to render. 2.4 GHz certainly isn't enough to calculate all that sorts of stuff - maybe 4 GHz would be someday.
 
?? I'm not sure about that. Doom 3 has very little CPU lag for me (p4 2.4ghz) but the framerate gets slaughtered when the full shadow settings are on (ati 9600se). I think it has everything to do with the GPU. Correct me if I am wrong.

Doom3 is fairly CPU bound, especially with shadows. Shadow volumes, which Doom3 use, require a LOT of CPU involvement. A slew of calculations (animation, normal/tangent/binormal rotation, shadow volume generation, etc.) have to be performed on the CPU, and the results sent to the GPU per frame. There has been research into generating shadow volumes using vertex shaders, but those aren't entirely optimized in terms of fill rate from what I can tell. With D3D10 though (due out next year) volumes can be generated entirely on the GPU, meaning all of the other calculations can be moved off of the CPU. However, by the time you're using D3D10, most developers will likely be using omni shadow maps, not shadow volumes, since those will have a significant speedup as well in D3D10.

2.4 GHz certainly isn't enough to calculate all that sorts of stuff - maybe 4 GHz would be someday.

You are seriously underestimating how fast your processor is. A CPU half that speed should still perform shadow volume generation fast enough.

Creating non-pitch-black shadows in a game like Doom 3 requires smart placement of multiple light sources. It's pretty ineficient

I think Unreal Engine 3.0 can do real-time light bouncing off specific materials. If it can not do such thing, it's just a tweaked Doom 3 engine.

On the first point, non pitch black shadows aren't that hard, as it just requires one more scene pass for the ambient light which is substantially cheaper than a regular light pass. The creators of Doom3 decided to forego it for artistic reasons.

UE3 doesn't do "real-time light bouncing of light" at all. Everything is still first-order lighting, they just have the ambient light pass that Doom3 doesn't have.
 
Solver said:
You have no way to reliably tell in-game whether your FPS drop is because of lack of power to calculate or to render. 2.4 GHz certainly isn't enough to calculate all that sorts of stuff - maybe 4 GHz would be someday.

Its down to the fact that the 9600 doesn't have full support for shadows, I've got a 6600GT with UltrashadowII and a 64 3000+, and Doom3 runs like a charm
 
Its down to the fact that the 9600 doesn't have full support for shadows, I've got a 6600GT with UltrashadowII and a 64 3000+, and Doom3 runs like a charm

The 9600 has full support for Doom3's shadows. Heck, even a Riva TNT has 100% full support. NV's Ultrashadow 2 is "just" an optimization for typical shadow volume rendering (I'm not an NV engineer, but I'm willing to bet they did stencil buffer related optimizations). Part of the reason your systems runs so much faster is that it _IS_ faster. You have a more powerful CPU, and a more powerful GPU. Of course it'll run like a charm for you by comparison.
 
DEATH eVADER said:
Its down to the fact that the 9600 doesn't have full support for shadows, I've got a 6600GT with UltrashadowII and a 64 3000+, and Doom3 runs like a charm
I hate people like you.

I've an R9550 and it's dynamic shadow-capable.
 
DEATH eVADER said:
Its down to the fact that the 9600 doesn't have full support for shadows, I've got a 6600GT with UltrashadowII and a 64 3000+, and Doom3 runs like a charm

Ultrashadow is a good piece of technology, yeah. Using depth bounds to render the shadows where it matters most is a very clever piece of work.
 
Back
Top