aboutsummaryrefslogtreecommitdiffstats
path: root/src/extras/postfx.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2020-11-19 19:07:32 +0100
committeraap <aap@papnet.eu>2020-11-19 19:07:32 +0100
commit07fe099b4e1fd877176f2b2947841ee82aa91ed0 (patch)
treeb76756d54baef5a3ee506875c866cd8a5947242d /src/extras/postfx.cpp
parent8963cbcb7cd507485064c44e9f9e226c958d34b6 (diff)
neo screen droplets
Diffstat (limited to 'src/extras/postfx.cpp')
-rw-r--r--src/extras/postfx.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/extras/postfx.cpp b/src/extras/postfx.cpp
index f7b120a8..2ea08141 100644
--- a/src/extras/postfx.cpp
+++ b/src/extras/postfx.cpp
@@ -376,6 +376,14 @@ CPostFX::NeedFrontBuffer(int32 type)
}
void
+CPostFX::GetBackBuffer(RwCamera *cam)
+{
+ RwRasterPushContext(pBackBuffer);
+ RwRasterRenderFast(RwCameraGetRaster(cam), 0, 0);
+ RwRasterPopContext();
+}
+
+void
CPostFX::Render(RwCamera *cam, uint32 red, uint32 green, uint32 blue, uint32 blur, int32 type, uint32 bluralpha)
{
if(pFrontBuffer == nil)
@@ -391,11 +399,8 @@ CPostFX::Render(RwCamera *cam, uint32 red, uint32 green, uint32 blue, uint32 blu
blur = AvgAlpha;
}
- if(NeedBackBuffer()){
- RwRasterPushContext(pBackBuffer);
- RwRasterRenderFast(RwCameraGetRaster(cam), 0, 0);
- RwRasterPopContext();
- }
+ if(NeedBackBuffer())
+ GetBackBuffer(cam);
DefinedState();