From 58495ea7149d733a1c22cb6feedc21b4489f6a47 Mon Sep 17 00:00:00 2001 From: Magnus Norddahl Date: Mon, 6 Feb 2017 16:04:27 +0100 Subject: [PATCH] Renamed Clip3DFloors to Clip3D to fix gcc compile error --- src/swrenderer/line/r_line.cpp | 6 +++--- src/swrenderer/line/r_renderdrawsegment.cpp | 8 ++++---- src/swrenderer/plane/r_visibleplanelist.cpp | 10 +++++----- src/swrenderer/r_renderthread.cpp | 2 +- src/swrenderer/r_renderthread.h | 2 +- src/swrenderer/scene/r_opaque_pass.cpp | 4 ++-- src/swrenderer/scene/r_portal.cpp | 14 +++++++------- src/swrenderer/scene/r_scene.cpp | 8 ++++---- src/swrenderer/scene/r_translucent_pass.cpp | 4 ++-- src/swrenderer/things/r_visiblesprite.cpp | 2 +- 10 files changed, 30 insertions(+), 30 deletions(-) diff --git a/src/swrenderer/line/r_line.cpp b/src/swrenderer/line/r_line.cpp index ddecf5879..5f5a57883 100644 --- a/src/swrenderer/line/r_line.cpp +++ b/src/swrenderer/line/r_line.cpp @@ -123,7 +123,7 @@ namespace swrenderer WallT.InitFromLine(Thread, v1->fPos() - ViewPos, v2->fPos() - ViewPos); } - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); if (!(clip3d->fake3D & FAKE3D_FAKEBACK)) { @@ -352,7 +352,7 @@ namespace swrenderer draw_segment->bFakeBoundary = false; draw_segment->foggy = foggy; - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); if (clip3d->fake3D & FAKE3D_FAKEMASK) draw_segment->fake = 1; else draw_segment->fake = 0; @@ -955,7 +955,7 @@ namespace swrenderer } } - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); // mark ceiling areas if (markceiling) diff --git a/src/swrenderer/line/r_renderdrawsegment.cpp b/src/swrenderer/line/r_renderdrawsegment.cpp index 67953dcfa..f4b6f97de 100644 --- a/src/swrenderer/line/r_renderdrawsegment.cpp +++ b/src/swrenderer/line/r_renderdrawsegment.cpp @@ -110,7 +110,7 @@ namespace swrenderer rw_lightstep = ds->lightstep; rw_light = ds->light + (x1 - ds->x1) * rw_lightstep; - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); CameraLight *cameraLight = CameraLight::Instance(); if (cameraLight->FixedLightLevel() < 0) @@ -478,7 +478,7 @@ namespace swrenderer WallC.tright.Y = ds->cy + ds->cdy; WallT = ds->tmapvals; - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); wallupper.Project(clip3d->sclipTop - ViewPos.Z, &WallC); walllower.Project(clip3d->sclipBottom - ViewPos.Z, &WallC); @@ -532,7 +532,7 @@ namespace swrenderer floorHeight = backsector->CenterFloor(); ceilingHeight = backsector->CenterCeiling(); - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); // maybe fix clipheights if (!(clip3d->fake3D & FAKE3D_CLIPBOTTOM)) clip3d->sclipBottom = floorHeight; @@ -938,7 +938,7 @@ namespace swrenderer top = MAX(frontcz1, frontcz2); bot = MIN(frontfz1, frontfz2); - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); if (clip3d->fake3D & FAKE3D_CLIPTOP) { top = MIN(top, clip3d->sclipTop); diff --git a/src/swrenderer/plane/r_visibleplanelist.cpp b/src/swrenderer/plane/r_visibleplanelist.cpp index 18c1f57e4..446741057 100644 --- a/src/swrenderer/plane/r_visibleplanelist.cpp +++ b/src/swrenderer/plane/r_visibleplanelist.cpp @@ -129,7 +129,7 @@ namespace swrenderer // kg3D - hack, store alpha in sky // i know there is ->alpha, but this also allows to identify fake plane // and ->alpha is for stacked sectors - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); if (clip3d->fake3D & (FAKE3D_FAKEFLOOR | FAKE3D_FAKECEILING)) sky = 0x80000000 | clip3d->fakeAlpha; else sky = 0; // not skyflatnum so it can't be a sky portal = nullptr; @@ -190,7 +190,7 @@ namespace swrenderer sky == check->sky && renderportal->CurrentPortalUniq == check->CurrentPortalUniq && renderportal->MirrorFlags == check->MirrorFlags && - Thread->Clip3DFloors->CurrentSkybox == check->CurrentSkybox && + Thread->Clip3D->CurrentSkybox == check->CurrentSkybox && ViewPos == check->viewpos ) { @@ -215,7 +215,7 @@ namespace swrenderer check->Additive = additive; check->CurrentPortalUniq = renderportal->CurrentPortalUniq; check->MirrorFlags = renderportal->MirrorFlags; - check->CurrentSkybox = Thread->Clip3DFloors->CurrentSkybox; + check->CurrentSkybox = Thread->Clip3D->CurrentSkybox; return check; } @@ -333,7 +333,7 @@ namespace swrenderer for (pl = visplanes[i]; pl; pl = pl->next) { // kg3D - draw only correct planes - if (pl->CurrentPortalUniq != renderportal->CurrentPortalUniq || pl->CurrentSkybox != Thread->Clip3DFloors->CurrentSkybox) + if (pl->CurrentPortalUniq != renderportal->CurrentPortalUniq || pl->CurrentSkybox != Thread->Clip3D->CurrentSkybox) continue; // kg3D - draw only real planes now if (pl->sky >= 0) { @@ -359,7 +359,7 @@ namespace swrenderer { for (pl = visplanes[i]; pl; pl = pl->next) { - if (pl->CurrentSkybox != Thread->Clip3DFloors->CurrentSkybox || pl->CurrentPortalUniq != renderportal->CurrentPortalUniq) + if (pl->CurrentSkybox != Thread->Clip3D->CurrentSkybox || pl->CurrentPortalUniq != renderportal->CurrentPortalUniq) continue; if (pl->sky < 0 && pl->height.Zat0() == height) diff --git a/src/swrenderer/r_renderthread.cpp b/src/swrenderer/r_renderthread.cpp index ba48993ca..41bb2fc5a 100644 --- a/src/swrenderer/r_renderthread.cpp +++ b/src/swrenderer/r_renderthread.cpp @@ -66,7 +66,7 @@ namespace swrenderer TranslucentPass = std::make_unique(this); SpriteList = std::make_unique(); Portal = std::make_unique(this); - Clip3DFloors = std::make_unique(this); + Clip3D = std::make_unique(this); PlayerSprites = std::make_unique(this); PlaneList = std::make_unique(this); DrawSegments = std::make_unique(this); diff --git a/src/swrenderer/r_renderthread.h b/src/swrenderer/r_renderthread.h index a0945cfee..e874dbe4e 100644 --- a/src/swrenderer/r_renderthread.h +++ b/src/swrenderer/r_renderthread.h @@ -61,7 +61,7 @@ namespace swrenderer std::unique_ptr TranslucentPass; std::unique_ptr SpriteList; std::unique_ptr Portal; - std::unique_ptr Clip3DFloors; + std::unique_ptr Clip3D; std::unique_ptr PlayerSprites; std::unique_ptr PlaneList; std::unique_ptr DrawSegments; diff --git a/src/swrenderer/scene/r_opaque_pass.cpp b/src/swrenderer/scene/r_opaque_pass.cpp index cf4155c4f..76528ae14 100644 --- a/src/swrenderer/scene/r_opaque_pass.cpp +++ b/src/swrenderer/scene/r_opaque_pass.cpp @@ -568,7 +568,7 @@ namespace swrenderer backupfp = floorplane; backupcp = ceilingplane; - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); // first check all floors for (int i = 0; i < (int)frontsector->e->XFloor.ffloors.Size(); i++) @@ -738,7 +738,7 @@ namespace swrenderer backupcp = ceilingplane; floorplane = nullptr; ceilingplane = nullptr; - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); for (unsigned int i = 0; i < line->backsector->e->XFloor.ffloors.Size(); i++) { clip3d->SetFakeFloor(line->backsector->e->XFloor.ffloors[i]); diff --git a/src/swrenderer/scene/r_portal.cpp b/src/swrenderer/scene/r_portal.cpp index 88ccb96c0..9053ebf15 100644 --- a/src/swrenderer/scene/r_portal.cpp +++ b/src/swrenderer/scene/r_portal.cpp @@ -98,7 +98,7 @@ namespace swrenderer if (!planes->HasPortalPlanes()) return; - Thread->Clip3DFloors->EnterSkybox(); + Thread->Clip3D->EnterSkybox(); CurrentPortalInSkybox = true; int savedextralight = extralight; @@ -213,7 +213,7 @@ namespace swrenderer visplaneStack.Push(pl); Thread->OpaquePass->RenderScene(); - Thread->Clip3DFloors->ResetClip(); // reset clips (floor/ceiling) + Thread->Clip3D->ResetClip(); // reset clips (floor/ceiling) planes->Render(); port->mFlags &= ~PORTSF_INSKYBOX; @@ -250,9 +250,9 @@ namespace swrenderer R_SetViewAngle(); CurrentPortalInSkybox = false; - Thread->Clip3DFloors->LeaveSkybox(); + Thread->Clip3D->LeaveSkybox(); - if (Thread->Clip3DFloors->fakeActive) return; + if (Thread->Clip3D->fakeActive) return; planes->ClearPortalPlanes(); } @@ -411,7 +411,7 @@ namespace swrenderer } // some portals have height differences, account for this here - Thread->Clip3DFloors->EnterSkybox(); // push 3D floor height map + Thread->Clip3D->EnterSkybox(); // push 3D floor height map CurrentPortalInSkybox = false; // first portal in a skybox should set this variable to false for proper clipping in skyboxes. // first pass, set clipping @@ -421,7 +421,7 @@ namespace swrenderer memcpy(floorclip + pds->x1, &pds->floorclip[0], pds->len * sizeof(*floorclip)); Thread->OpaquePass->RenderScene(); - Thread->Clip3DFloors->ResetClip(); // reset clips (floor/ceiling) + Thread->Clip3D->ResetClip(); // reset clips (floor/ceiling) if (!savedvisibility && camera) camera->renderflags &= ~RF_INVISIBLE; PlaneCycles.Clock(); @@ -451,7 +451,7 @@ namespace swrenderer if (Thread->MainThread) NetUpdate(); - Thread->Clip3DFloors->LeaveSkybox(); // pop 3D floor height map + Thread->Clip3D->LeaveSkybox(); // pop 3D floor height map CurrentPortalUniq = prevuniq2; // draw a red line around a portal if it's being highlighted diff --git a/src/swrenderer/scene/r_scene.cpp b/src/swrenderer/scene/r_scene.cpp index 18c5137df..905c0a097 100644 --- a/src/swrenderer/scene/r_scene.cpp +++ b/src/swrenderer/scene/r_scene.cpp @@ -215,8 +215,8 @@ namespace swrenderer void RenderScene::RenderThreadSlice(RenderThread *thread) { thread->FrameMemory->Clear(); - thread->Clip3DFloors->Cleanup(); - thread->Clip3DFloors->ResetClip(); // reset clips (floor/ceiling) + thread->Clip3D->Cleanup(); + thread->Clip3D->ResetClip(); // reset clips (floor/ceiling) thread->Portal->CopyStackedViewParameters(); thread->ClipSegments->Clear(0, viewwidth); thread->DrawSegments->Clear(); @@ -237,7 +237,7 @@ namespace swrenderer WallCycles.Clock(); thread->OpaquePass->RenderScene(); - thread->Clip3DFloors->ResetClip(); // reset clips (floor/ceiling) + thread->Clip3D->ResetClip(); // reset clips (floor/ceiling) if (thread == MainThread()) WallCycles.Unclock(); @@ -375,7 +375,7 @@ namespace swrenderer void RenderScene::Deinit() { MainThread()->TranslucentPass->Deinit(); - MainThread()->Clip3DFloors->Cleanup(); + MainThread()->Clip3D->Cleanup(); } ///////////////////////////////////////////////////////////////////////// diff --git a/src/swrenderer/scene/r_translucent_pass.cpp b/src/swrenderer/scene/r_translucent_pass.cpp index 06b61007d..460fb6228 100644 --- a/src/swrenderer/scene/r_translucent_pass.cpp +++ b/src/swrenderer/scene/r_translucent_pass.cpp @@ -140,7 +140,7 @@ namespace swrenderer if (renew) { - Thread->Clip3DFloors->fake3D |= FAKE3D_REFRESHCLIP; + Thread->Clip3D->fake3D |= FAKE3D_REFRESHCLIP; } DrawSegmentList *drawseglist = Thread->DrawSegments.get(); @@ -167,7 +167,7 @@ namespace swrenderer Thread->SpriteList->Sort(); Thread->DrawSegments->BuildSegmentGroups(); - Clip3DFloors *clip3d = Thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = Thread->Clip3D.get(); if (clip3d->height_top == nullptr) { // kg3D - no visible 3D floors, normal rendering DrawMaskedSingle(false); diff --git a/src/swrenderer/things/r_visiblesprite.cpp b/src/swrenderer/things/r_visiblesprite.cpp index 2bfd31f9b..809a21397 100644 --- a/src/swrenderer/things/r_visiblesprite.cpp +++ b/src/swrenderer/things/r_visiblesprite.cpp @@ -57,7 +57,7 @@ namespace swrenderer int colormapnum = spr->Light.ColormapNum; F3DFloor *rover; - Clip3DFloors *clip3d = thread->Clip3DFloors.get(); + Clip3DFloors *clip3d = thread->Clip3D.get(); // [RH] Check for particles if (spr->IsParticle())