Spiffae
Newbie
- Joined
- May 22, 2003
- Messages
- 1,211
- Reaction score
- 0
Hi -
I've been playing a lot of CS: Source, and I think i've determined something about how HL2 (and all source games) can seem to have so much cool realtime reflection (on guns etc.) without taking a huge rendering hit.
It has to do with environment maps. An environment map is essentially a 360 degree photograph that is an approximation of what is going on around a given object.
In most games, You'll see one, maybe two environment maps per level. mostly it's something along the lines of sky above, ground below, and it works for giving you nice chrome deagles and such. In Source, however, there are dozens, if not hundreds of environment maps. It seems that Valve has a tool that allows them to break a level into chunks, and then quickly generate environment maps that accurately portray what's around. In de_dust, there are five seperate maps between the CT spawn, and the entrance to the "T" dome area. generally the differences are subtle, but it really makes a difference when you're transitioning from outdoors to indoors. Let me illustrate.
(This would be easier to do if I had a weapon that was a ball of chrome, and it's easier to see in motion, but we'll work with what we've got)
Here's near the CT Spawn. You can see the rear of th gun reflecting the shadowed wall behind me, and the rest reflecting sun and sky.
Now it gets a bit more interesting. I'm standing near a wooden door, and it appears that the door is reflecting in the side of the gun. It's actually just a good environment map, but the illusion is almost perfect.
Here we're entering the dome tunnel (whatever the CT kids call it) you can see a glint of light from the entrance shining on the back of the gun, but the front and sides are dark, reflecting the dark walls inside.
Now in the underpass. Halfway throught the tunnel, the gun is reflecting both the entrance behind me, and the light coming in up ahead. It's just an environment map, but it's a great illusion of true reflection.
My Favorite - almost out of the tunnel, you can see the gun reflecting the sky, sun, and sand up ahead, while the back is still showing the tunnel exit that i'm standing in. It looks great.
This isn't CS:S related, this is a fundamental technology of the Source Engine. I thought this might be enlightening. I only posted it here because the HL2 forums don't have IMG code enabled.
Comments?
I've been playing a lot of CS: Source, and I think i've determined something about how HL2 (and all source games) can seem to have so much cool realtime reflection (on guns etc.) without taking a huge rendering hit.
It has to do with environment maps. An environment map is essentially a 360 degree photograph that is an approximation of what is going on around a given object.
In most games, You'll see one, maybe two environment maps per level. mostly it's something along the lines of sky above, ground below, and it works for giving you nice chrome deagles and such. In Source, however, there are dozens, if not hundreds of environment maps. It seems that Valve has a tool that allows them to break a level into chunks, and then quickly generate environment maps that accurately portray what's around. In de_dust, there are five seperate maps between the CT spawn, and the entrance to the "T" dome area. generally the differences are subtle, but it really makes a difference when you're transitioning from outdoors to indoors. Let me illustrate.
(This would be easier to do if I had a weapon that was a ball of chrome, and it's easier to see in motion, but we'll work with what we've got)
Here's near the CT Spawn. You can see the rear of th gun reflecting the shadowed wall behind me, and the rest reflecting sun and sky.
Now it gets a bit more interesting. I'm standing near a wooden door, and it appears that the door is reflecting in the side of the gun. It's actually just a good environment map, but the illusion is almost perfect.
Here we're entering the dome tunnel (whatever the CT kids call it) you can see a glint of light from the entrance shining on the back of the gun, but the front and sides are dark, reflecting the dark walls inside.
Now in the underpass. Halfway throught the tunnel, the gun is reflecting both the entrance behind me, and the light coming in up ahead. It's just an environment map, but it's a great illusion of true reflection.
My Favorite - almost out of the tunnel, you can see the gun reflecting the sky, sun, and sand up ahead, while the back is still showing the tunnel exit that i'm standing in. It looks great.
This isn't CS:S related, this is a fundamental technology of the Source Engine. I thought this might be enlightening. I only posted it here because the HL2 forums don't have IMG code enabled.
Comments?