mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-24 21:21:04 +00:00
- implemented pixelratio for the classic software renderer
This commit is contained in:
parent
93c05fc97e
commit
72054fb5e2
2 changed files with 5 additions and 3 deletions
|
@ -253,7 +253,7 @@ namespace swrenderer
|
|||
auto viewport = Thread->Viewport.get();
|
||||
|
||||
double pspritexscale = viewport->viewwindow.centerxwide / 160.0;
|
||||
double pspriteyscale = pspritexscale * viewport->YaspectMul;
|
||||
double pspriteyscale = pspritexscale * viewport->BaseYaspectMul;
|
||||
double pspritexiscale = 1 / pspritexscale;
|
||||
|
||||
int tleft = tex->GetScaledLeftOffset();
|
||||
|
|
|
@ -98,12 +98,14 @@ namespace swrenderer
|
|||
virtwidth = virtwidth * AspectMultiplier(viewwindow.WidescreenRatio) / 48;
|
||||
}
|
||||
|
||||
double ypixelstretch = (level.info) ? level.info->pixelstretch : 1.2;
|
||||
|
||||
BaseYaspectMul = 320.0 * virtheight2 / (r_Yaspect * virtwidth2);
|
||||
YaspectMul = 320.0 * virtheight / (r_Yaspect * virtwidth);
|
||||
YaspectMul = 320.0 * virtheight / (r_Yaspect * virtwidth) * ypixelstretch / 1.2;
|
||||
IYaspectMul = (double)virtwidth * r_Yaspect / 320.0 / virtheight;
|
||||
InvZtoScale = YaspectMul * CenterX;
|
||||
|
||||
WallTMapScale2 = IYaspectMul / CenterX;
|
||||
WallTMapScale2 = IYaspectMul / CenterX * 1.2 / ypixelstretch;
|
||||
|
||||
// thing clipping
|
||||
fillshort(screenheightarray, viewwidth, (short)viewheight);
|
||||
|
|
Loading…
Reference in a new issue