From df1ad8e122e43967710470e275844b62c4962e5d Mon Sep 17 00:00:00 2001 From: aap Date: Sun, 28 Feb 2021 15:29:58 +0100 Subject: fix postfx --- src/extras/postfx.cpp | 3 +++ src/rw/RwHelper.cpp | 8 ++++++++ 2 files changed, 11 insertions(+) (limited to 'src') diff --git a/src/extras/postfx.cpp b/src/extras/postfx.cpp index 03d4833e..425a22d4 100644 --- a/src/extras/postfx.cpp +++ b/src/extras/postfx.cpp @@ -48,6 +48,9 @@ CPostFX::InitOnce(void) void CPostFX::Open(RwCamera *cam) { + if(pFrontBuffer) + Close(); + uint32 width = Pow(2.0f, int32(log2(RwRasterGetWidth (RwCameraGetRaster(cam))))+1); uint32 height = Pow(2.0f, int32(log2(RwRasterGetHeight(RwCameraGetRaster(cam))))+1); uint32 depth = RwRasterGetDepth(RwCameraGetRaster(cam)); diff --git a/src/rw/RwHelper.cpp b/src/rw/RwHelper.cpp index ef2d1c0f..a633a139 100644 --- a/src/rw/RwHelper.cpp +++ b/src/rw/RwHelper.cpp @@ -6,6 +6,7 @@ #include "Timecycle.h" #include "skeleton.h" #include "Debug.h" +#include "MBlur.h" #if !defined(FINAL) || defined(DEBUGMENU) #include "rtcharse.h" #endif @@ -526,6 +527,13 @@ CameraSize(RwCamera * camera, RwRect * rect, RsGlobal.width = rect->w; RsGlobal.height = rect->h; + +#ifdef FIX_BUGS + if(CMBlur::BlurOn){ + CMBlur::MotionBlurClose(); + CMBlur::MotionBlurOpen(camera); + } +#endif } return; -- cgit v1.2.3