- Apr 9, 2008
- 1,706
- 1,491
Corey Peters from Valve said:If you're coming up against the t-junction limit I assume the map is either very large or densely populated with world geometry (converted to func_detail). Goldrush came up against this limit after final art pass.
There's no single way to resolve the t-junction issue. I'd recommend starting by removing some of the func_details (either deleting or converting to world geometry) to see if that helps fix the error. This will of course increase compile times and lose some of the benefits that func_details give you at run time (not directly cutting up world geometry and creating less vis leaves). This can be done in combination with func_visclusters to help keep compile times down by merging vis leaves within their volume.
It may be worth considering performance optimizations at this point if there are areas with a lot of func_detail work that run slower on low end machines. Pruning some of the detail here may just give you the head room needed to sneak under the limit.
If that's still not enough consider turning some of your geometry into models. Especially if you have a lot of repeated func_detail work that can be modeled. Models generally render faster than world geometry with the caveat that too many meshes isn't good either.
Using displacements on a beam like those is a bad idea due to the fact displacements use slightly bigger lightmap scales than regular geometry. Also displacements usually contain more polygons per face due to their nature.
I've done a little experiment comparing a normal compile to a compile with the -notjuncs switch.
Here's some images.
Without fixed t-juncs
Normal
Wireframe
Normal compile (with fixed t-juncs/waterindices)
Normal
Wireframe
What's interesting is that fixing t-junctions is done in order to eliminate cracks between faces but when I had a look around the map without any fixed t-junctions I couldn't see any cracks at all.
Not to say I will compile my map without fixing up t-junctions but I thought it was worth posting.