Fog speed


(MindLink) #1

Hey there…
I’ve been working on a map for Enemy Territory and decided to add some global fog to it as nice “effect”. Without any fog the map runs at a good 125 fps on my system (p4 2,4 gig, 512 megs ram, gf 3)… I copied the original Wurzburg Radar-fog and added the parameters to the worldspawn
(fog, fogclip, farplanedist).
Now when I compile and enter the map everything looks fine and works fine, but the framerate drops to an incredible 50-60 fps where I had 125 before… O_o … Now why is this and is there any way around it? Wasn’t fog even supposed to help speed things up by clipping things beyond it’s visibility?


(Wils) #2

That doesn’t sound like it’s set up correctly, but I couldn’t tell you what you’d missed without seeing the map. If you’re using q3map2 to cut the map up into vis blocks, make sure your gridsize is set small enough in the worldspawn for it to be effective.

Some other things to remember is that fog still adds an extra pass to every surface it falls on, and that culling the now-unseen polys will actually cost you a little performance too.

It’s only worth using the combination farplane/vis-based culling stuff if you end up getting improved performance out of it. If your fog is very thin it won’t be culling enough to be worth the effort, and if your vis blocks are too big (or you’re not using this method) you’ll find it ends up having to cull too much behind the farplane.


(MindLink) #3

Well I could even live with the fog not culling anything since the map works out fine set up like it is now… I’d just like to add the fog as an effect since it fits the atmosphere of the map.
I tried several blocksizes (from “2048 2048 0” down to “512 512 0”) but it didn’t make any real difference.
I’m using quite a bunch of new textures in my map and haven’t written shaders for all of them yet (so most of them use 1 pass only anyways), but I don’t think that should make a big difference…?