diff --git a/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.h b/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.h index f34c6b6ef7..dff0318e17 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.h +++ b/Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.h @@ -56,12 +56,7 @@ const int MAX_VIRTUAL_XFB = 4; inline bool addrRangesOverlap(u32 aLower, u32 aUpper, u32 bLower, u32 bUpper) { - return ( - (aLower >= bLower && aLower < bUpper) || - (aUpper >= bLower && aUpper < bUpper) || - (bLower >= aLower && bLower < aUpper) || - (bUpper >= aLower && bUpper < aUpper) - ); + return !((aLower >= bUpper) || (bLower >= aUpper)); } struct XFBSource diff --git a/Source/Plugins/Plugin_VideoOGL/Src/main.cpp b/Source/Plugins/Plugin_VideoOGL/Src/main.cpp index 5f885b5b02..e8e48a93fb 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/main.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/main.cpp @@ -468,12 +468,7 @@ void VideoFifo_CheckSwapRequest() inline bool addrRangesOverlap(u32 aLower, u32 aUpper, u32 bLower, u32 bUpper) { - return ( - (aLower >= bLower && aLower < bUpper) || - (aUpper >= bLower && aUpper < bUpper) || - (bLower >= aLower && bLower < aUpper) || - (bUpper >= aLower && bUpper < aUpper) - ); + return !((aLower >= bUpper) || (bLower >= aUpper)); } // Run from the graphics thread (from Fifo.cpp)