Good ways to cut VVIS ???

Toxindude

L3: Member
Aug 2, 2012
103
4
I am looking for ways to cut down my compile time. My VVIS takes insanly long I'm talkin hours. I have a rather large map. You can see here http://forums.tf2maps.net/showthread.php?t=21165

VVIS slows my PC down to almost a halt and I have a pretty good rig. I am woking on optimization right now.
 

fubarFX

The "raw" in "nodraw"
aa
Jun 1, 2009
1,720
1,978
if you haven't heard of func_detail, you should start with this.
try loading your portal file in hammer to see what's up. try to eliminate all excessive divisions
then once you have of good grasp of how visibility works in source, you can go on and use func_viscluster
 
Last edited:

Toxindude

L3: Member
Aug 2, 2012
103
4
Thanks fubar, Yeah I do know about func_detail I should have mentioned that. I have never used func_viscluster before is there anything explaining how it works ?

I read somewhere to make only the internal brush work func_detail and to leave the exterior walls alone is this correct ?

Also I did a bunch of skip/hint work in the mid of my map similar to what RaVaGe suggested in the link above. Can that slow VVIS ?
 

RaVaGe

aa
Jun 23, 2010
733
1,210
Yeah, the cross at the middle can slow vvis, but if everything is well func_detailled, it can't slow a lot your compile time.
 
Sep 7, 2012
638
500
I read somewhere to make only the internal brush work func_detail and to leave the exterior walls alone is this correct ?

If you do this, then your vvis will be much faster. However, your optimization will likely be quite poor.
 

Toxindude

L3: Member
Aug 2, 2012
103
4
If you do this, then your vvis will be much faster. However, your optimization will likely be quite poor.

That was my thought because. If you func_detail the internals doesn't that make the walls non solid making the skip/hint inaffective ?
 

RaVaGe

aa
Jun 23, 2010
733
1,210
Yeah you need to keep your basic brushwork, otherwise the optimization will be uselless.

A little example from my map, still in dev, so some things aren't yet in func_detail (respawn roofs, houses at the outside, structures into the main building). And a lot of hints are missing, but I always like to do some optimisation before finishing my map.

OPTI.jpg
 
Last edited:

Toxindude

L3: Member
Aug 2, 2012
103
4
So are you using hint/skip to fill in doorways to the internals of structures to separate the outside from inside. I guess I'm somewhat confused by the hint/skip. I watched a video of this guy cutting them at corners and such but he didn't fill in doorways and windows can they be used in this way ?

Also did you draw a giant skip brush over the whole map ?

How do you plan on doing your Skybox ? Not talkin a 3D just the regular Skybox brush.
 

A Boojum Snark

Toraipoddodezain Mazahabado
aa
Nov 2, 2007
4,775
7,669
So are you using hint/skip to fill in doorways to the internals of structures to separate the outside from inside. I guess I'm somewhat confused by the hint/skip. I watched a video of this guy cutting them at corners and such but he didn't fill in doorways and windows can they be used in this way ?
Hint merely makes a leaf slice. Sometimes you might need to hint a doorway IF it was improperly sliced and the leaf goes "through" the doorway which would result in stuff being rendered that doesn't need to. Most of the time it is not needed.
Corners... that's also a case by case basis. Really, you can't explain when you use hint, you need to understand the concept behind how vis works, then you will understand when and where you need hints. Hints are for when the compiler doesn't do something that should be done.

Also did you draw a giant skip brush over the whole map ?
I hope he didn't... that is actually detrimental.
 

RaVaGe

aa
Jun 23, 2010
733
1,210
So are you using hint/skip to fill in doorways to the internals of structures to separate the outside from inside. I guess I'm somewhat confused by the hint/skip. I watched a video of this guy cutting them at corners and such but he didn't fill in doorways and windows can they be used in this way ?

Most of the time I use areaportals to fill my doors and windows, but it depends if I can easily optimize an arena or not, if the doorway lead to a plain and big area, I use an areaportal, if it leads to another small room, I use an hint brush.

Also did you draw a giant skip brush over the whole map ?

The under face is textured as a hint brush, I textured all the other face in skip simply because vvis don't have to cut these. Here is an example :

hint.jpg


As you can see, if all your brush is textured in hint, vvis will cut the two sides of the brush, and will make appears another visleaf, the skip texture just say to vvis to simply skip this texture, and will not cut it. You need to put a skip texture on the side of the brush too.


How do you plan on doing your Skybox ? Not talkin a 3D just the regular Skybox brush.

No idea, I will probably do something like that:

dev2.jpg


I will use an areaportal for this one, because you still can see the other side if you jump high enough.

But be aware that the areaportals use a lot of ressources, especially in multiplayer when the server as to compute every areaportals for every players, that's a lot ! So use them sparingly.
 

Toxindude

L3: Member
Aug 2, 2012
103
4
Thanks guys that helped a TON!

I actually went in last night and deleted about half of the interior for the base's. It was an optimization nightmare. I am working on simplifying the layout more.

RaVaGe your post with snaps of your projects was an inspiration :)
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,694
2,579
Another question: Is VBSP supposed to look at user-made hints first and then calculate automatic slicing based on the results? Or are they two unconnected processes? Because I've found that sometimes if I indent a metal TOP SECRET door, I'll get a visleaf the size of the door stretching across the hallway. And then if I try to fix it by placing a hint brush in that space, it'll slice across it but still keep the visleaf going across the hallway.
 
Sep 7, 2012
638
500
Another question: Is VBSP supposed to look at user-made hints first and then calculate automatic slicing based on the results? Or are they two unconnected processes? Because I've found that sometimes if I indent a metal TOP SECRET door, I'll get a visleaf the size of the door stretching across the hallway. And then if I try to fix it by placing a hint brush in that space, it'll slice across it but still keep the visleaf going across the hallway.

I don't have too much experience with hint but I would think you have to make the hint face stretch all along the wall, not just the indenture.
 

A Boojum Snark

Toraipoddodezain Mazahabado
aa
Nov 2, 2007
4,775
7,669
VBSP just does it's own thing. You can't always predict or control where portals show up, which is why hints are something akin to a "negative optimization" because generally you're only going to make MORE leaves (and thus increase calculations), in exchange for preventing certain leaves from seeing each other.

Thinking about it now though, a program has to operate in some logical manner, and it could be that VBSP goes through the process of portalling the map in first-come first-served sense via file order. Next time there is a stubborn leaf across a hall, try making the hint brush before the door is cut into the wall (or clone/delete the wall afterwards).
 

Toxindude

L3: Member
Aug 2, 2012
103
4
So I compiled my tester map testing out my hint/skip brushes to see if they work. I get in game and use mat_wireframe 1,2 or 3 doesn't matter even r_draw commands.

I look at a wall with a room on the other side and there are models placed in that room. The models don't show up in wireframe. You can see the wireframe room on the other side but no wireframe models. I went back and removed the skip/hint brushes, compiled and ran the map. Still you can see the room over there but the models don't show. If you run around the corner the models are clearly there in there purple black checker awesomeness.

Disregard this post the TF2 Update fixed this issue.
 
Last edited: