Moved ProcessLowerMinisegs back toAPI independent code.

This commit is contained in:
Christoph Oelckers 2018-06-20 10:10:30 +02:00
parent 013ac247ca
commit 9bdb5f1a5d
3 changed files with 15 additions and 14 deletions

View file

@ -481,18 +481,6 @@ void FDrawInfo::FloodLowerGap(seg_t * seg)
ClearFloodStencil(&ws); ClearFloodStencil(&ws);
} }
// This was temporarily moved out of gl_renderhacks.cpp so that the dependency on GLWall could be eliminated until things have progressed a bit.
void FDrawInfo::ProcessLowerMinisegs(TArray<seg_t *> &lowersegs)
{
for(unsigned int j=0;j<lowersegs.Size();j++)
{
seg_t * seg=lowersegs[j];
GLWall wall;
wall.ProcessLowerMiniseg(this, seg, seg->Subsector->render_sector, seg->PartnerSeg->Subsector->render_sector);
rendered_lines++;
}
}
// Same here for the dependency on the portal. // Same here for the dependency on the portal.
void FDrawInfo::AddSubsectorToPortal(FSectorPortalGroup *portal, subsector_t *sub) void FDrawInfo::AddSubsectorToPortal(FSectorPortalGroup *portal, subsector_t *sub)
{ {

View file

@ -196,7 +196,7 @@ public:
virtual void FloodUpperGap(seg_t * seg) = 0; virtual void FloodUpperGap(seg_t * seg) = 0;
virtual void FloodLowerGap(seg_t * seg) = 0; virtual void FloodLowerGap(seg_t * seg) = 0;
virtual void ProcessLowerMinisegs(TArray<seg_t *> &lowersegs) = 0; void ProcessLowerMinisegs(TArray<seg_t *> &lowersegs);
virtual void AddSubsectorToPortal(FSectorPortalGroup *portal, subsector_t *sub) = 0; virtual void AddSubsectorToPortal(FSectorPortalGroup *portal, subsector_t *sub) = 0;
virtual void AddWall(GLWall *w) = 0; virtual void AddWall(GLWall *w) = 0;

View file

@ -30,7 +30,8 @@
#include "r_sky.h" #include "r_sky.h"
#include "g_levellocals.h" #include "g_levellocals.h"
#include "hwrenderer/scene/hw_drawinfo.h" #include "hw_drawinfo.h"
#include "hw_drawstructs.h"
#include "hwrenderer/utility/hw_clock.h" #include "hwrenderer/utility/hw_clock.h"
sector_t * hw_FakeFlat(sector_t * sec, sector_t * dest, area_t in_area, bool back); sector_t * hw_FakeFlat(sector_t * sec, sector_t * dest, area_t in_area, bool back);
@ -844,6 +845,18 @@ bool HWDrawInfo::CollectSubsectorsCeiling(subsector_t * sub, sector_t * anchor)
// //
//========================================================================== //==========================================================================
void HWDrawInfo::ProcessLowerMinisegs(TArray<seg_t *> &lowersegs)
{
for(unsigned int j=0;j<lowersegs.Size();j++)
{
seg_t * seg=lowersegs[j];
GLWall wall;
wall.ProcessLowerMiniseg(this, seg, seg->Subsector->render_sector, seg->PartnerSeg->Subsector->render_sector);
rendered_lines++;
}
}
void HWDrawInfo::HandleHackedSubsectors() void HWDrawInfo::HandleHackedSubsectors()
{ {
viewsubsector = R_PointInSubsector(Viewpoint.Pos); viewsubsector = R_PointInSubsector(Viewpoint.Pos);