From 95716b65ca39c016d7cbfdc221a0572766ae620d Mon Sep 17 00:00:00 2001 From: Nimetu Date: Wed, 18 Aug 2021 14:21:43 +0300 Subject: [PATCH] Fix comparing x twice in Direct3d setupScissor --- nel/src/3d/driver/direct3d/driver_direct3d_matrix.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/nel/src/3d/driver/direct3d/driver_direct3d_matrix.cpp b/nel/src/3d/driver/direct3d/driver_direct3d_matrix.cpp index 6e7520fb7..988f9c9eb 100644 --- a/nel/src/3d/driver/direct3d/driver_direct3d_matrix.cpp +++ b/nel/src/3d/driver/direct3d/driver_direct3d_matrix.cpp @@ -283,18 +283,16 @@ void CDriverD3D::setupScissor (const class CScissor& scissor) // Get viewport _ScissorTouched = false; float x= scissor.X; + float y= scissor.Y; float width= scissor.Width; float height= scissor.Height; - if(x==0 && x==0 && width==1 && height==1) + if(x==0 && y==0 && width==1 && height==1) { setRenderState (D3DRS_SCISSORTESTENABLE, FALSE); } else { - - float y= scissor.Y; - if (_HWnd) { // Get the render target size