Merge pull request #1583 from reicast/fh/rend-vscaler

fix scissor test and vertical scaling when using the Y scaler
This commit is contained in:
David Miller 2019-05-06 10:33:46 -04:00 committed by GitHub
commit e7c44df627
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 0 deletions

View File

@ -656,6 +656,8 @@ static bool RenderFrame()
{
scale_x=fb_scale_x;
scale_y=fb_scale_y;
if (SCALER_CTL.interlace == 0)
scale_y *= SCALER_CTL.vscalefactor / 0x400;
//work out scaling parameters !
//Pixel doubling is on VO, so it does not affect any pixel operations
@ -868,6 +870,12 @@ static bool RenderFrame()
float min_y = pvrrc.fb_Y_CLIP.min / scale_y;
if (!is_rtt)
{
if (SCALER_CTL.interlace)
{
// Clipping is done after scaling/filtering so account for that if enabled
height *= SCALER_CTL.vscalefactor / 0x400;
min_y *= SCALER_CTL.vscalefactor / 0x400;
}
if (settings.rend.Rotate90)
{
float t = width;

View File

@ -1651,6 +1651,8 @@ bool RenderFrame()
{
scale_x=fb_scale_x;
scale_y=fb_scale_y;
if (SCALER_CTL.interlace == 0)
scale_y *= SCALER_CTL.vscalefactor / 0x400;
//work out scaling parameters !
//Pixel doubling is on VO, so it does not affect any pixel operations
@ -1900,6 +1902,12 @@ bool RenderFrame()
float min_y = pvrrc.fb_Y_CLIP.min / scale_y;
if (!is_rtt)
{
if (SCALER_CTL.interlace)
{
// Clipping is done after scaling/filtering so account for that if enabled
height *= SCALER_CTL.vscalefactor / 0x400;
min_y *= SCALER_CTL.vscalefactor / 0x400;
}
if (settings.rend.Rotate90)
{
float t = width;