mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-23 12:32:34 +00:00
- removed more old code from flat renderer.
VBOHeightCheck was from early development when interpolation was not reflected by the vertex buffer. # Conflicts: # src/gl/scene/gl_flats.cpp
This commit is contained in:
parent
07649fd31a
commit
84a55667d9
3 changed files with 20 additions and 58 deletions
|
@ -118,8 +118,6 @@ void FDrawInfo::DrawSubsectors(GLFlat *flat, int pass, bool istrans)
|
|||
flat->SetupLights(this, flat->sector->lighthead, lightdata, flat->sector->PortalGroup);
|
||||
}
|
||||
gl_RenderState.ApplyLightIndex(flat->dynlightindex);
|
||||
if (iboindex >= 0)
|
||||
{
|
||||
if (vcount > 0 && !ClipLineShouldBeActive())
|
||||
{
|
||||
drawcalls.Clock();
|
||||
|
@ -147,19 +145,6 @@ void FDrawInfo::DrawSubsectors(GLFlat *flat, int pass, bool istrans)
|
|||
index += (sub->numlines - 2) * 3;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Draw the subsectors belonging to this sector
|
||||
for (int i=0; i<flat->sector->subsectorcount; i++)
|
||||
{
|
||||
subsector_t * sub = flat->sector->subsectors[i];
|
||||
if (ss_renderflags[sub->Index()]& flat->renderflags || istrans)
|
||||
{
|
||||
DrawSubsector(flat, sub);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Draw the subsectors assigned to it due to missing textures
|
||||
if (!(flat->renderflags&SSRF_RENDER3DPLANES))
|
||||
|
|
|
@ -269,14 +269,7 @@ void GLFlat::SetFrom3DFloor(F3DFloor *rover, bool top, bool underside)
|
|||
|
||||
alpha = rover->alpha/255.0f;
|
||||
renderstyle = rover->flags&FF_ADDITIVETRANS? STYLE_Add : STYLE_Translucent;
|
||||
if (plane.model->VBOHeightcheck(plane.isceiling))
|
||||
{
|
||||
iboindex = plane.vindex;
|
||||
}
|
||||
else
|
||||
{
|
||||
iboindex = -1;
|
||||
}
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
|
@ -338,15 +331,8 @@ void GLFlat::ProcessSector(HWDrawInfo *di, sector_t * frontsector)
|
|||
}
|
||||
|
||||
if (alpha != 0.f && frontsector->GetTexture(sector_t::floor) != skyflatnum)
|
||||
{
|
||||
if (frontsector->VBOHeightcheck(sector_t::floor))
|
||||
{
|
||||
iboindex = frontsector->iboindex[sector_t::floor];
|
||||
}
|
||||
else
|
||||
{
|
||||
iboindex = -1;
|
||||
}
|
||||
|
||||
ceiling = false;
|
||||
renderflags = SSRF_RENDERFLOOR;
|
||||
|
@ -398,16 +384,8 @@ void GLFlat::ProcessSector(HWDrawInfo *di, sector_t * frontsector)
|
|||
}
|
||||
|
||||
if (alpha != 0.f && frontsector->GetTexture(sector_t::ceiling) != skyflatnum)
|
||||
{
|
||||
if (frontsector->VBOHeightcheck(sector_t::ceiling))
|
||||
{
|
||||
iboindex = frontsector->iboindex[sector_t::ceiling];
|
||||
}
|
||||
else
|
||||
{
|
||||
iboindex = -1;
|
||||
}
|
||||
|
||||
ceiling = true;
|
||||
renderflags = SSRF_RENDERCEILING;
|
||||
|
||||
|
|
|
@ -1092,7 +1092,6 @@ public:
|
|||
int ibocount; // number of indices per plane (identical for all planes.) If this is -1 the index buffer is not in use.
|
||||
|
||||
float GetReflect(int pos) { return gl_plane_reflection_i? reflect[pos] : 0; }
|
||||
bool VBOHeightcheck(int pos) const { return vboheight[pos] == GetPlaneTexZ(pos); }
|
||||
FSectorPortalGroup *GetPortalGroup(int plane) { return portals[plane]; }
|
||||
|
||||
enum
|
||||
|
|
Loading…
Reference in a new issue