summaryrefslogtreecommitdiffstats
path: root/src/render
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2021-02-18 12:21:52 +0100
committeraap <aap@papnet.eu>2021-02-18 12:21:52 +0100
commit996772faf2b7ed17269af194c6d9dcbdb37732fe (patch)
treecfb4d76317a169f665bf1f500e36d4aa2c0e54ec /src/render
parentMerge branch 'miami' of github.com:GTAmodding/re3 into miami (diff)
downloadre3-996772faf2b7ed17269af194c6d9dcbdb37732fe.tar
re3-996772faf2b7ed17269af194c6d9dcbdb37732fe.tar.gz
re3-996772faf2b7ed17269af194c6d9dcbdb37732fe.tar.bz2
re3-996772faf2b7ed17269af194c6d9dcbdb37732fe.tar.lz
re3-996772faf2b7ed17269af194c6d9dcbdb37732fe.tar.xz
re3-996772faf2b7ed17269af194c6d9dcbdb37732fe.tar.zst
re3-996772faf2b7ed17269af194c6d9dcbdb37732fe.zip
Diffstat (limited to 'src/render')
-rw-r--r--src/render/Antennas.cpp4
-rw-r--r--src/render/Clouds.cpp13
-rw-r--r--src/render/Coronas.cpp8
-rw-r--r--src/render/Fluff.cpp2
-rw-r--r--src/render/Glass.cpp4
-rw-r--r--src/render/MBlur.cpp3
-rw-r--r--src/render/Particle.cpp5
-rw-r--r--src/render/PointLights.cpp4
-rw-r--r--src/render/Renderer.cpp33
-rw-r--r--src/render/Rubbish.cpp4
-rw-r--r--src/render/Shadows.cpp8
-rw-r--r--src/render/Skidmarks.cpp4
-rw-r--r--src/render/SpecialFX.cpp2
-rw-r--r--src/render/WaterCannon.cpp2
-rw-r--r--src/render/WaterLevel.cpp4
15 files changed, 99 insertions, 1 deletions
diff --git a/src/render/Antennas.cpp b/src/render/Antennas.cpp
index 452069a0..5e30aca2 100644
--- a/src/render/Antennas.cpp
+++ b/src/render/Antennas.cpp
@@ -1,5 +1,6 @@
#include "common.h"
+#include "main.h"
#include "Antennas.h"
CAntenna CAntennas::aAntennas[NUMANTENNAS];
@@ -70,6 +71,7 @@ CAntennas::Render(void)
{
int i, j;
+ PUSH_RENDERGROUP("CAntennas::Render");
for(i = 0; i < NUMANTENNAS; i++){
if(!aAntennas[i].active)
continue;
@@ -101,6 +103,8 @@ CAntennas::Render(void)
}
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)FALSE);
+
+ POP_RENDERGROUP();
}
void
diff --git a/src/render/Clouds.cpp b/src/render/Clouds.cpp
index e3a8c86e..9cd32c5f 100644
--- a/src/render/Clouds.cpp
+++ b/src/render/Clouds.cpp
@@ -1,5 +1,6 @@
#include "common.h"
+#include "main.h"
#include "Sprite.h"
#include "Sprite2d.h"
#include "General.h"
@@ -119,6 +120,8 @@ CClouds::Render(void)
if(!CGame::CanSeeOutSideFromCurrArea())
return;
+ PUSH_RENDERGROUP("CClouds::Render");
+
CCoronas::SunBlockedByClouds = false;
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)FALSE);
@@ -301,6 +304,8 @@ CClouds::Render(void)
RwRenderStateSet(rwRENDERSTATEZTESTENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATESRCBLEND, (void*)rwBLENDSRCALPHA);
RwRenderStateSet(rwRENDERSTATEDESTBLEND, (void*)rwBLENDINVSRCALPHA);
+
+ POP_RENDERGROUP();
}
bool
@@ -313,6 +318,8 @@ void
CClouds::RenderBackground(int16 topred, int16 topgreen, int16 topblue,
int16 botred, int16 botgreen, int16 botblue, int16 alpha)
{
+ PUSH_RENDERGROUP("CClouds::RenderBackground");
+
CVector right = CrossProduct(TheCamera.GetUp(), TheCamera.GetForward());
right.Normalise();
float c = right.Magnitude2D();
@@ -415,6 +422,8 @@ CClouds::RenderBackground(int16 topred, int16 topgreen, int16 topblue,
ms_colourBottom.g = fogg;
ms_colourBottom.b = fogb;
}
+
+ POP_RENDERGROUP();
}
void
@@ -423,6 +432,8 @@ CClouds::RenderHorizon(void)
if(UseDarkBackground())
return;
+ PUSH_RENDERGROUP("CClouds::RenderHorizon");
+
ms_colourBottom.a = 230;
ms_colourTop.a = 80;
@@ -457,4 +468,6 @@ CClouds::RenderHorizon(void)
CSprite2d::DrawAnyRect(0.0f, topleft, SCREEN_WIDTH, topright, 0.0f, botleft, SCREEN_WIDTH, botright,
ms_colourBkGrd, ms_colourBkGrd, ms_colourBkGrd, ms_colourBkGrd);
+
+ POP_RENDERGROUP();
}
diff --git a/src/render/Coronas.cpp b/src/render/Coronas.cpp
index e3d3416c..8b137aad 100644
--- a/src/render/Coronas.cpp
+++ b/src/render/Coronas.cpp
@@ -249,6 +249,8 @@ CCoronas::Render(void)
int i, j;
int screenw, screenh;
+ PUSH_RENDERGROUP("CCoronas::Render");
+
screenw = RwRasterGetWidth(RwCameraGetRaster(Scene.camera));
screenh = RwRasterGetHeight(RwCameraGetRaster(Scene.camera));
@@ -432,6 +434,8 @@ CCoronas::Render(void)
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEZTESTENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)TRUE);
+
+ POP_RENDERGROUP();
}
void
@@ -442,6 +446,8 @@ CCoronas::RenderReflections(void)
CEntity *entity;
if(CWeather::WetRoads > 0.0f){
+ PUSH_RENDERGROUP("CCoronas::RenderReflections");
+
CSprite::InitSpriteBuffer();
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)FALSE);
@@ -517,6 +523,8 @@ CCoronas::RenderReflections(void)
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEZTESTENABLE, (void*)TRUE);
+
+ POP_RENDERGROUP();
}else{
for(i = 0; i < NUMCORONAS; i++)
aCoronas[i].renderReflection = false;
diff --git a/src/render/Fluff.cpp b/src/render/Fluff.cpp
index 30e271fb..e92eee29 100644
--- a/src/render/Fluff.cpp
+++ b/src/render/Fluff.cpp
@@ -459,6 +459,7 @@ void CMovingThings::Update()
void CMovingThings::Render()
{
+ PUSH_RENDERGROUP("CMovingThings::Render");
CSmokeTrails::Update();
int i;
@@ -471,6 +472,7 @@ void CMovingThings::Render()
CPlaneTrails::Render();
CSmokeTrails::Render();
CPlaneBanners::Render();
+ POP_RENDERGROUP();
}
void CMovingThings::RegisterOne(CEntity *pEnt, uint16 nType) {
diff --git a/src/render/Glass.cpp b/src/render/Glass.cpp
index c6d02755..3409a058 100644
--- a/src/render/Glass.cpp
+++ b/src/render/Glass.cpp
@@ -276,6 +276,8 @@ CGlass::Render(void)
RwRenderStateSet(rwRENDERSTATEDESTBLEND, (void *)rwBLENDONE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void *)TRUE);
+ PUSH_RENDERGROUP("CGlass::Render");
+
for ( int32 i = 0; i < NUM_GLASSPANES; i++ )
{
if ( aGlassPanes[i].m_bActive )
@@ -285,6 +287,8 @@ CGlass::Render(void)
for ( uint32 i = 0; i < NumGlassEntities; i++ )
RenderEntityInGlass(apEntitiesToBeRendered[i]);
+ POP_RENDERGROUP();
+
NumGlassEntities = 0;
RenderHiLightPolys();
diff --git a/src/render/MBlur.cpp b/src/render/MBlur.cpp
index a94a5245..9f5122dc 100644
--- a/src/render/MBlur.cpp
+++ b/src/render/MBlur.cpp
@@ -6,6 +6,7 @@
#include <d3d8caps.h>
#endif
+#include "main.h"
#include "General.h"
#include "RwHelper.h"
#include "Camera.h"
@@ -333,6 +334,7 @@ CMBlur::MotionBlurRender(RwCamera *cam, uint32 red, uint32 green, uint32 blue, u
#ifdef EXTENDED_COLOURFILTER
CPostFX::Render(cam, red, green, blue, blur, type, bluralpha);
#else
+ PUSH_RENDERGROUP("CMBlur::MotionBlurRender");
RwRGBA color = { (RwUInt8)red, (RwUInt8)green, (RwUInt8)blue, (RwUInt8)blur };
#ifdef GTA_PS2
if( pFrontBuffer )
@@ -348,6 +350,7 @@ CMBlur::MotionBlurRender(RwCamera *cam, uint32 red, uint32 green, uint32 blue, u
RwRasterPopContext();
}
#endif
+ POP_RENDERGROUP();
#endif
}
diff --git a/src/render/Particle.cpp b/src/render/Particle.cpp
index 8c9cde12..14b48243 100644
--- a/src/render/Particle.cpp
+++ b/src/render/Particle.cpp
@@ -1,5 +1,6 @@
#include "common.h"
+#include "main.h"
#include "General.h"
#include "Timer.h"
#include "TxdStore.h"
@@ -1785,6 +1786,8 @@ void CParticle::Update()
void CParticle::Render()
{
+ PUSH_RENDERGROUP("CParticle::Render");
+
RwRenderStateSet(rwRENDERSTATETEXTUREADDRESS, (void *)rwTEXTUREADDRESSWRAP);
RwRenderStateSet(rwRENDERSTATETEXTUREPERSPECTIVE, (void *)TRUE);
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void *)FALSE);
@@ -2282,6 +2285,8 @@ void CParticle::Render()
RwRenderStateSet(rwRENDERSTATEZTESTENABLE, (void *)TRUE);
RwRenderStateSet(rwRENDERSTATESRCBLEND, (void *)rwBLENDSRCALPHA);
RwRenderStateSet(rwRENDERSTATEDESTBLEND, (void *)rwBLENDINVSRCALPHA);
+
+ POP_RENDERGROUP();
}
void CParticle::RemovePSystem(tParticleType type)
diff --git a/src/render/PointLights.cpp b/src/render/PointLights.cpp
index 3e73c57f..13872401 100644
--- a/src/render/PointLights.cpp
+++ b/src/render/PointLights.cpp
@@ -159,6 +159,8 @@ CPointLights::RenderFogEffect(void)
if(CCutsceneMgr::IsRunning())
return;
+ PUSH_RENDERGROUP("CPointLights::RenderFogEffect");
+
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATESRCBLEND, (void*)rwBLENDONE);
@@ -302,6 +304,8 @@ CPointLights::RenderFogEffect(void)
}
CSprite::FlushSpriteBuffer();
+
+ POP_RENDERGROUP();
}
bool
diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp
index dfbc02d7..6b306b6c 100644
--- a/src/render/Renderer.cpp
+++ b/src/render/Renderer.cpp
@@ -130,8 +130,13 @@ CRenderer::RenderOneRoad(CEntity *e)
return;
if(gbShowCollisionPolys)
CCollision::DrawColModel_Coloured(e->GetMatrix(), *CModelInfo::GetModelInfo(e->GetModelIndex())->GetColModel(), e->GetModelIndex());
- else
+ else{
+ PUSH_RENDERGROUP(CModelInfo::GetModelInfo(e->GetModelIndex())->GetModelName());
+
e->Render();
+
+ POP_RENDERGROUP();
+ }
}
void
@@ -178,6 +183,8 @@ CRenderer::RenderOneNonRoad(CEntity *e)
}
#endif
+ PUSH_RENDERGROUP(CModelInfo::GetModelInfo(e->GetModelIndex())->GetModelName());
+
resetLights = e->SetupLighting();
if(e->IsVehicle()){
@@ -206,6 +213,8 @@ CRenderer::RenderOneNonRoad(CEntity *e)
}
e->RemoveLighting(resetLights);
+
+ POP_RENDERGROUP();
}
void
@@ -231,6 +240,7 @@ CRenderer::RenderRoads(void)
int i;
CEntity *e;
+ PUSH_RENDERGROUP("CRenderer::RenderRoads");
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
SetCullMode(rwCULLMODECULLBACK);
@@ -242,6 +252,7 @@ CRenderer::RenderRoads(void)
if(IsRoad(e))
RenderOneRoad(e);
}
+ POP_RENDERGROUP();
}
inline bool PutIntoSortedVehicleList(CVehicle *veh)
@@ -264,6 +275,7 @@ CRenderer::RenderEverythingBarRoads(void)
CEntity *e;
EntityInfo ei;
+ PUSH_RENDERGROUP("CRenderer::RenderEverythingBarRoads");
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
SetCullMode(rwCULLMODECULLBACK);
@@ -295,6 +307,7 @@ CRenderer::RenderEverythingBarRoads(void)
}else
RenderOneNonRoad(e);
}
+ POP_RENDERGROUP();
}
void
@@ -302,6 +315,7 @@ CRenderer::RenderBoats(void)
{
CLink<EntityInfo> *node;
+ PUSH_RENDERGROUP("CRenderer::RenderBoats");
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
SetCullMode(rwCULLMODECULLBACK);
@@ -330,6 +344,7 @@ CRenderer::RenderBoats(void)
CVehicle *v = (CVehicle*)node->item.ent;
RenderOneNonRoad(v);
}
+ POP_RENDERGROUP();
}
#ifdef NEW_RENDERER
@@ -433,6 +448,7 @@ CRenderer::RenderWorld(int pass)
switch(pass){
case 0:
// Roads
+ PUSH_RENDERGROUP("CRenderer::RenderWorld - Roads");
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)FALSE);
for(i = 0; i < ms_nNoOfVisibleBuildings; i++){
e = ms_aVisibleBuildingPtrs[i];
@@ -446,9 +462,11 @@ CRenderer::RenderWorld(int pass)
if(e->bIsBIGBuilding || IsRoad(e))
RenderOneBuilding(e, node->item.sort);
}
+ POP_RENDERGROUP();
break;
case 1:
// Opaque
+ PUSH_RENDERGROUP("CRenderer::RenderWorld - Opaque");
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)FALSE);
for(i = 0; i < ms_nNoOfVisibleBuildings; i++){
e = ms_aVisibleBuildingPtrs[i];
@@ -469,14 +487,17 @@ CRenderer::RenderWorld(int pass)
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, FALSE);
WorldRender::RenderBlendPass(PASS_NOZ);
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)TRUE);
+ POP_RENDERGROUP();
break;
case 2:
// Transparent
+ PUSH_RENDERGROUP("CRenderer::RenderWorld - Transparent");
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEDESTBLEND, (void*)rwBLENDONE);
WorldRender::RenderBlendPass(PASS_ADD);
RwRenderStateSet(rwRENDERSTATEDESTBLEND, (void*)rwBLENDINVSRCALPHA);
WorldRender::RenderBlendPass(PASS_BLEND);
+ POP_RENDERGROUP();
break;
}
}
@@ -487,11 +508,13 @@ CRenderer::RenderPeds(void)
int i;
CEntity *e;
+ PUSH_RENDERGROUP("CRenderer::RenderPeds");
for(i = 0; i < ms_nNoOfVisibleVehicles; i++){
e = ms_aVisibleVehiclePtrs[i];
if(e->IsPed())
RenderOneNonRoad(e);
}
+ POP_RENDERGROUP();
}
void
@@ -502,6 +525,7 @@ CRenderer::RenderVehicles(void)
EntityInfo ei;
CLink<EntityInfo> *node;
+ PUSH_RENDERGROUP("CRenderer::RenderVehicles");
// not the real thing
for(i = 0; i < ms_nNoOfVisibleVehicles; i++){
e = ms_aVisibleVehiclePtrs[i];
@@ -518,6 +542,7 @@ CRenderer::RenderVehicles(void)
node != &gSortedVehiclesAndPeds.head;
node = node->prev)
RenderOneNonRoad(node->item.ent);
+ POP_RENDERGROUP();
}
void
@@ -526,6 +551,7 @@ CRenderer::RenderTransparentWater(void)
int i;
CEntity *e;
+ PUSH_RENDERGROUP("CRenderer::RenderTransparentWater");
RwRenderStateSet(rwRENDERSTATETEXTURERASTER, nil);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)FALSE);
@@ -549,6 +575,7 @@ CRenderer::RenderTransparentWater(void)
CWaterLevel::RenderTransparentWater();
SetStencilState(0);
+ POP_RENDERGROUP();
}
void
@@ -569,20 +596,24 @@ CRenderer::ClearForFrame(void)
void
CRenderer::RenderFadingInEntities(void)
{
+ PUSH_RENDERGROUP("CRenderer::RenderFadingInEntities");
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
SetCullMode(rwCULLMODECULLBACK);
DeActivateDirectional();
SetAmbientColours();
CVisibilityPlugins::RenderFadingEntities();
+ POP_RENDERGROUP();
}
void
CRenderer::RenderFadingInUnderwaterEntities(void)
{
+ PUSH_RENDERGROUP("CRenderer::RenderFadingInUnderwaterEntities");
DeActivateDirectional();
SetAmbientColours();
CVisibilityPlugins::RenderFadingUnderwaterEntities();
+ POP_RENDERGROUP();
}
void
diff --git a/src/render/Rubbish.cpp b/src/render/Rubbish.cpp
index bd69f875..147c97b1 100644
--- a/src/render/Rubbish.cpp
+++ b/src/render/Rubbish.cpp
@@ -54,6 +54,8 @@ CRubbish::Render(void)
if(RubbishVisibility == 0)
return;
+ PUSH_RENDERGROUP("CRubbish::Render");
+
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)TRUE);
@@ -150,6 +152,8 @@ CRubbish::Render(void)
RwRenderStateSet(rwRENDERSTATEFOGENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
+
+ POP_RENDERGROUP();
}
void
diff --git a/src/render/Shadows.cpp b/src/render/Shadows.cpp
index 91f53acf..ae079821 100644
--- a/src/render/Shadows.cpp
+++ b/src/render/Shadows.cpp
@@ -1068,6 +1068,8 @@ CShadows::SetRenderModeForShadowType(uint8 ShadowType)
void
CShadows::RenderStoredShadows(void)
{
+ PUSH_RENDERGROUP("CShadows::RenderStoredShadows");
+
RenderBuffer::ClearRenderBuffer();
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void *)FALSE);
@@ -1241,12 +1243,16 @@ CShadows::RenderStoredShadows(void)
RwRenderStateSet(rwRENDERSTATETEXTUREADDRESS, (void *)rwTEXTUREADDRESSWRAP);
ShadowsStoredToBeRendered = 0;
+
+ POP_RENDERGROUP();
}
void
CShadows::RenderStaticShadows(void)
{
+ PUSH_RENDERGROUP("CShadows::RenderStaticShadows");
+
RenderBuffer::ClearRenderBuffer();
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void *)FALSE);
@@ -1313,6 +1319,8 @@ CShadows::RenderStaticShadows(void)
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void *)FALSE);
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void *)TRUE);
+
+ POP_RENDERGROUP();
}
diff --git a/src/render/Skidmarks.cpp b/src/render/Skidmarks.cpp
index 07039c17..08df330d 100644
--- a/src/render/Skidmarks.cpp
+++ b/src/render/Skidmarks.cpp
@@ -96,6 +96,8 @@ CSkidmarks::Render(void)
{
int i, j;
+ PUSH_RENDERGROUP("CSkidmarks::Render");
+
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATESRCBLEND, (void*)rwBLENDSRCALPHA);
@@ -152,6 +154,8 @@ CSkidmarks::Render(void)
RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void*)FALSE);
RwRenderStateSet(rwRENDERSTATEZWRITEENABLE, (void*)TRUE);
RwRenderStateSet(rwRENDERSTATEZTESTENABLE, (void*)TRUE);
+
+ POP_RENDERGROUP();
}
void
diff --git a/src/render/SpecialFX.cpp b/src/render/SpecialFX.cpp
index 4391f19e..b44848f9 100644
--- a/src/render/SpecialFX.cpp
+++ b/src/render/SpecialFX.cpp
@@ -164,6 +164,7 @@ CSpecialFX::Shutdown(void)
void
CSpecialFX::Render(void)
{
+ PUSH_RENDERGROUP("CSpecialFX::Render");
CMotionBlurStreaks::Render();
CBulletTraces::Render();
CBrightLights::Render();
@@ -173,6 +174,7 @@ CSpecialFX::Render(void)
if(!(gbNewRenderer && FredIsInFirstPersonCam()))
#endif
C3dMarkers::Render();
+ POP_RENDERGROUP();
}
void
diff --git a/src/render/WaterCannon.cpp b/src/render/WaterCannon.cpp
index 0f8b22a7..4976f8a3 100644
--- a/src/render/WaterCannon.cpp
+++ b/src/render/WaterCannon.cpp
@@ -307,9 +307,11 @@ void CWaterCannons::Update(void)
void CWaterCannons::Render(void)
{
+ PUSH_RENDERGROUP("CWaterCannons::Render");
for ( int32 i = 0; i < NUM_WATERCANNONS; i++ )
{
if ( aCannons[i].m_nId != 0 )
aCannons[i].Render();
}
+ POP_RENDERGROUP();
}
diff --git a/src/render/WaterLevel.cpp b/src/render/WaterLevel.cpp
index 3d33dbf6..e91aa790 100644
--- a/src/render/WaterLevel.cpp
+++ b/src/render/WaterLevel.cpp
@@ -1202,6 +1202,8 @@ CWaterLevel::RenderTransparentWater(void)
if ( !CGame::CanSeeWaterFromCurrArea() )
return;
+ PUSH_RENDERGROUP("CWaterLevel::RenderTransparentWater");
+
float fWaterDrawDist = _GetWavyDrawDist();
float fWaterDrawDistLarge = fWaterDrawDist + 90.0f;
float fWavySectorMaxRenderDistSqr = SQR(fWaterDrawDist);
@@ -1485,6 +1487,8 @@ CWaterLevel::RenderTransparentWater(void)
DefinedState();
#endif
+
+ POP_RENDERGROUP();
}
void CWaterLevel::RenderOneFlatSmallWaterPoly(float fX, float fY, float fZ, RwRGBA const &color)