- Wrap midtex support

This commit is contained in:
Magnus Norddahl 2017-08-17 23:14:02 +02:00
parent c2fa360bbc
commit 8034793193

View file

@ -273,8 +273,12 @@ void RenderPolyWall::Render(const TriMatrix &worldToClip, const PolyClipPlane &c
// Masked walls clamp to the 0-1 range (no texture repeat) // Masked walls clamp to the 0-1 range (no texture repeat)
if (Masked) if (Masked)
{ {
ClampHeight(vertices[0], vertices[3]); bool wrap = (Line->flags & ML_WRAP_MIDTEX) || (Side->Flags & WALLF_WRAP_MIDTEX);
ClampHeight(vertices[1], vertices[2]); if (!wrap)
{
ClampHeight(vertices[0], vertices[3]);
ClampHeight(vertices[1], vertices[2]);
}
} }
PolyDrawArgs args; PolyDrawArgs args;