From eaee3d6ac5378a9d144e16142b59355016fab949 Mon Sep 17 00:00:00 2001 From: Rachael Alexanderson Date: Tue, 31 Dec 2019 08:59:38 -0500 Subject: [PATCH] - fixed softpoly backend unconditionally applying linear scaling --- src/win32/win32polyvideo.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/win32/win32polyvideo.cpp b/src/win32/win32polyvideo.cpp index 2c2111979..fb9d5612a 100644 --- a/src/win32/win32polyvideo.cpp +++ b/src/win32/win32polyvideo.cpp @@ -6,6 +6,8 @@ EXTERN_CVAR(Bool, vid_vsync) +bool ViewportLinearScale(); + extern HWND Window; #include @@ -168,7 +170,10 @@ void I_PolyPresentUnlock(int x, int y, int width, int height) dstrect.top = y; dstrect.right = x + width; dstrect.bottom = y + height; - device->StretchRect(surface, &srcrect, backbuffer, &dstrect, D3DTEXF_LINEAR); + if (ViewportLinearScale()) + device->StretchRect(surface, &srcrect, backbuffer, &dstrect, D3DTEXF_LINEAR); + else + device->StretchRect(surface, &srcrect, backbuffer, &dstrect, D3DTEXF_POINT); result = device->EndScene(); if (SUCCEEDED(result))