map optimization qeustion
Post Reply
Quote
Re: map optimization qeustion
Posted by Jacfu on Sun Mar 4th at 1:04pm 2007


Hi all - Maybe somebody can help me out here. I'm busy looking at optimizing my map, I've read all about hints ect. and when I ran my map with mat_wireframe 1, I found that the engine is drawing way too much in one specific area:

and here is the wireframe:

now my qeustion is, why is the engine drawing all the stuff behind this wall? It is solid world brush, so everything behind it does not need to be drawn, right?

The frame rates are relativly ok - some areas go down to 40 and the higest is around the 120 mark. average frame rate is 70 - 90. I reckon I hav to mess around with more hinting but I have read that that could even mess up the framerates more if you don't know what you are doing.





Quote
Re: map optimization qeustion
Posted by Orpheus on Sun Mar 4th at 1:25pm 2007


[edited out





The best things in life, aren't things.



Quote
Re: map optimization qeustion
Posted by Jacfu on Sun Mar 4th at 1:33pm 2007






Quote
Re: map optimization qeustion
Posted by Jacfu on Sun Mar 4th at 1:57pm 2007


Lol - soz bout the screens - fixed that last one /

heres a hammer veiw from above/





Quote
Re: map optimization qeustion
Posted by Orpheus on Sun Mar 4th at 3:31pm 2007


*puts on thinking cap*

Lets see, if it were me guessing I'd say its one of two things.

1) You are using the wrong command, and its not giving you the accurate information.. IE GL_Wireframe 1 or GL_Wireframe 2 in HL1.

2) Even thought the wall is solid, its not tall enough to block off the complete view. (Not yours, the engines view)





The best things in life, aren't things.



Quote
Re: map optimization qeustion
Posted by reaper47 on Sun Mar 4th at 3:33pm 2007


This is a bit strange, indeed. You didn't build all these brushes of func_details, did you? image

Generally, BSP-optimization is a hard thing to grasp. I suppose you've read the one and only Z@C optimization guide, but you might find some enlightenment in this (highly technical) article on BSP-visibility.

The result could come from vertical visibility rather than horizontal. In other words, the leaf you're in is so high it can "look over the roofs" and see what's behind. A huge HINT brush spanning the whole map at the exact height of the roof/balcony could help.






Quote
Re: map optimization qeustion
Posted by Jacfu on Sun Mar 4th at 4:07pm 2007


Thanks for the info guys. I also thought that somehow I made those brushes func_details, but they are solid world brushes. I'll check out that second link in more detail and try the GL_Wireframe 1 command too.





Quote
Re: map optimization qeustion
Posted by Orpheus on Sun Mar 4th at 4:29pm 2007


Well since reaper said sorta the same as me, perhaps I ain't to far off the mark.



The best things in life, aren't things.



Quote
Re: map optimization qeustion
Posted by reaper47 on Sun Mar 4th at 4:49pm 2007


Speaking of gl_wireframe... gl_wireframe = mat_wireframe in HL2. I think "mat_wireframe 3" turns off the "triangle mode" and shows full polygon edges only, which is a bit clearer. It never shows undrawn polygons, though, so it's always accurate for performance testing.





Quote
Re: map optimization qeustion
Posted by omegaslayer on Sun Mar 4th at 6:05pm 2007


From looking at your map - its drawing everything it should be. Read what reaper47 said about bsp visability. Essentially the vis leaf your standing in is seeing around the building (because its wide), as well as over it (because its tall). You can easily fix this with hint brushes. But you need to get a better understanding of visablity (once again read reaper's tuts).





Quote
Re: map optimization qeustion
Posted by Jacfu on Sun Mar 4th at 8:39pm 2007


Yeah, that "BSP" tut is very informative. I realize now that it's better to plan your map with bsp in mind - trying to fix everything at nr.99 wastes time.

I added hint brushes finally and got vvis down from 1min44 to 1min09 -

and vrad from 7min22 to 6min. It's not a lot though ( framerates only slightly better ) so I better do some more reading to try and figure out what the hell I'm doing. Thanks for the help all!

btw, I updated the link to the map.





Quote
Re: map optimization qeustion
Posted by BlisTer on Mon Mar 5th at 4:37pm 2007


? quoting omegaslayer
From looking at your map - its drawing everything it should be.

indeed. also don't think of hint brushes as a magic optimisation tool. you can guide vvis in the right direction with them based on a thought-out design, but if your basic design is flawed they won't help you much.

It is helpfull to be thinking of optimisation with double-lines while you plan out your map. ingame, everything will be rendered that is reachable by a double line starting from you point of view. The first line is everything you see, the second line is everything that first line can see that is within your field of view.

Sorry for a childish drawing but here's what's happening in that shot you showed us. the green lines are what you can see, the red lines are what the green lines can see, and thus what gets rendered by the engine.

image




These words are my diaries screaming out loud




Post Reply