- fix sky sector portals
This commit is contained in:
parent
a3ee3c287e
commit
c21037fb03
3 changed files with 97 additions and 76 deletions
|
|
@ -52,13 +52,20 @@ void RenderPolyScene::SetViewpoint(const TriMatrix &worldToClip, const Vec4f &po
|
|||
|
||||
void RenderPolyScene::SetPortalSegments(const std::vector<PolyPortalSegment> &segments)
|
||||
{
|
||||
Cull.ClearSolidSegments();
|
||||
for (const auto &segment : segments)
|
||||
if (!segments.empty())
|
||||
{
|
||||
Cull.MarkSegmentCulled(segment.Start, segment.End);
|
||||
Cull.ClearSolidSegments();
|
||||
for (const auto &segment : segments)
|
||||
{
|
||||
Cull.MarkSegmentCulled(segment.Start, segment.End);
|
||||
}
|
||||
Cull.InvertSegments();
|
||||
PortalSegmentsAdded = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
PortalSegmentsAdded = false;
|
||||
}
|
||||
Cull.InvertSegments();
|
||||
PortalSegmentsAdded = true;
|
||||
}
|
||||
|
||||
void RenderPolyScene::Render(int portalDepth)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue