- fix the culling bugs in softpoly by switching to a pseudo-angle clipper
This commit is contained in:
parent
31ea33bfc4
commit
e12f48699e
6 changed files with 136 additions and 148 deletions
|
|
@ -208,10 +208,9 @@ void RenderPolyPlane::Render(const TriMatrix &worldToClip, const Vec4f &clipPlan
|
|||
vdist = dist;
|
||||
}
|
||||
|
||||
int sx1, sx2;
|
||||
LineSegmentRange range = cull.GetSegmentRangeForLine(line->v1->fX(), line->v1->fY(), line->v2->fX(), line->v2->fY(), sx1, sx2);
|
||||
if (range == LineSegmentRange::HasSegment)
|
||||
portalSegments.push_back({ sx1, sx2 });
|
||||
angle_t angle1, angle2;
|
||||
if (cull.GetAnglesForLine(line->v1->fX(), line->v1->fY(), line->v2->fX(), line->v2->fY(), angle1, angle2))
|
||||
portalSegments.push_back({ angle1, angle2 });
|
||||
}
|
||||
|
||||
if (inside)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue