mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 23:12:24 +00:00
- Fix softpoly ignores status bar displacement
This commit is contained in:
parent
94e8d59dde
commit
4a730f6dd5
2 changed files with 5 additions and 1 deletions
|
@ -59,6 +59,7 @@ void PolyRenderer::RenderView(player_t *player, DCanvas *target)
|
||||||
using namespace swrenderer;
|
using namespace swrenderer;
|
||||||
|
|
||||||
RenderTarget = target;
|
RenderTarget = target;
|
||||||
|
RenderToCanvas = false;
|
||||||
int width = SCREENWIDTH;
|
int width = SCREENWIDTH;
|
||||||
int height = SCREENHEIGHT;
|
int height = SCREENHEIGHT;
|
||||||
float trueratio;
|
float trueratio;
|
||||||
|
@ -77,6 +78,7 @@ void PolyRenderer::RenderViewToCanvas(AActor *actor, DCanvas *canvas, int x, int
|
||||||
|
|
||||||
viewwidth = width;
|
viewwidth = width;
|
||||||
RenderTarget = canvas;
|
RenderTarget = canvas;
|
||||||
|
RenderToCanvas = true;
|
||||||
R_SetWindow(Viewpoint, Viewwindow, 12, width, height, height, true);
|
R_SetWindow(Viewpoint, Viewwindow, 12, width, height, height, true);
|
||||||
//viewport->SetViewport(&Thread, width, height, Viewwindow.WidescreenRatio);
|
//viewport->SetViewport(&Thread, width, height, Viewwindow.WidescreenRatio);
|
||||||
viewwindowx = x;
|
viewwindowx = x;
|
||||||
|
@ -88,6 +90,7 @@ void PolyRenderer::RenderViewToCanvas(AActor *actor, DCanvas *canvas, int x, int
|
||||||
DrawerThreads::WaitForWorkers();
|
DrawerThreads::WaitForWorkers();
|
||||||
|
|
||||||
RenderTarget = screen->GetCanvas();
|
RenderTarget = screen->GetCanvas();
|
||||||
|
RenderToCanvas = false;
|
||||||
R_ExecuteSetViewSize(Viewpoint, Viewwindow);
|
R_ExecuteSetViewSize(Viewpoint, Viewwindow);
|
||||||
float trueratio;
|
float trueratio;
|
||||||
ActiveRatio(width, height, &trueratio);
|
ActiveRatio(width, height, &trueratio);
|
||||||
|
@ -154,7 +157,7 @@ void PolyRenderer::SetSceneViewport()
|
||||||
{
|
{
|
||||||
using namespace swrenderer;
|
using namespace swrenderer;
|
||||||
|
|
||||||
if (RenderTarget == screen->GetCanvas()) // Rendering to screen
|
if (!RenderToCanvas) // Rendering to screen
|
||||||
{
|
{
|
||||||
int height;
|
int height;
|
||||||
if (screenblocks >= 10)
|
if (screenblocks >= 10)
|
||||||
|
|
|
@ -57,6 +57,7 @@ public:
|
||||||
|
|
||||||
PolyRenderThreads Threads;
|
PolyRenderThreads Threads;
|
||||||
DCanvas *RenderTarget = nullptr;
|
DCanvas *RenderTarget = nullptr;
|
||||||
|
bool RenderToCanvas = false;
|
||||||
FViewWindow Viewwindow;
|
FViewWindow Viewwindow;
|
||||||
FRenderViewpoint Viewpoint;
|
FRenderViewpoint Viewpoint;
|
||||||
PolyLightVisibility Light;
|
PolyLightVisibility Light;
|
||||||
|
|
Loading…
Reference in a new issue