[Gtkradiant] 45 degree model clipping q3map2 fix

Rudolf Polzer divVerent at alientrap.org
Wed Jan 19 02:58:47 CST 2011


On Tue, Jan 18, 2011 at 11:39:23PM -0800, Nerius Landys wrote:
> I committed a fix to q3map2 which fixes model clipping where the model tris are
> at 45 degree angles to the axis planes.

Thanks for pointing out in the comment the dead code - fixed this in
NetRadiant's q3map2 too now.

The extrusion itself is fixed "another way" in NR, by avoiding the loop
entirely and using direct comparisons of the absolutes instead. Mainly because
in NR's q3map2, there are different selectable extrusion methods. However,
I plan to change NR's code to be 100% consistent with ZeroRadiant's choice of
normal in the default extrusion method.

As for the different extrusion methods - the default method is somewhat nice,
but not totally suitable for terrain steeper than 45 degrees; however, the
issue is very subtle and possibly not even noticeable in the Q3 engine, and
also only affects few terrains. One of the modes I have in NetRadiant is an
"always downwards" extrusion, which works perfectly for overhang free terrain,
and an "along triangle normal" extrusion, which works well for any terrain that
has no "spikes". If you have both overhangs and spikes, there probably is no
perfect extrusion...

it also contains a "zero volume" extrusion method, however, I suppose no engine
supports that yet (that method creates a brush that contains its plane, and its
opposite, and expects the engine to treat this as a single collision triangle);
I plan to make the DarkPlaces engine support such brushes, however. It already
supports collision triangles, so this wouldn't be a big step any more, but it
would reduce the number of collision triangles the engine has to deal with on
terrain by factor five.

Best regards,

Rudolf Polzer



More information about the Gtkradiant mailing list