Fix aspect correction in fullscreen mode.

Previously, we only set the viewingrange according to the physical screen's
dimensions, but didn't correct yxaspect for a potential non-square pixel
ratio.

git-svn-id: https://svn.eduke32.com/eduke32@2603 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2012-04-09 19:22:31 +00:00
parent a03eadb22e
commit 7cf95a9b0f

View file

@ -13266,8 +13266,13 @@ void setaspect_new()
if (fullscreen)
{
int32_t pixratio;
x=r_screenxy/100; y=r_screenxy%100;
if (y==0 || x==0) { x=4; y=3; }
pixratio = divscale16(xdim*y, ydim*x);
yx = divscale16(yx, pixratio);
}
else
{
@ -13275,7 +13280,7 @@ void setaspect_new()
y = ydim;
}
vr = (65536*x*3)/(y*4);
vr = divscale16(x*3, y*4);
setaspect(vr, yx);
}