Fixing OpenGL shader rotation

This commit is contained in:
Rémi 2019-11-16 19:52:47 +01:00
parent 9b192dc3c1
commit 6c47f02bdf

View File

@ -935,8 +935,14 @@ static void gl2_renderchain_recompute_pass_sizes(
break;
case RARCH_SCALE_VIEWPORT:
fbo_rect->img_width = fbo_rect->max_img_width =
if (gl->rotation % 180 == 90)
{
fbo_rect->img_width = fbo_rect->max_img_width =
fbo_scale->scale_x * vp_height;
} else {
fbo_rect->img_width = fbo_rect->max_img_width =
fbo_scale->scale_x * vp_width;
}
break;
}
@ -953,8 +959,14 @@ static void gl2_renderchain_recompute_pass_sizes(
break;
case RARCH_SCALE_VIEWPORT:
if (gl->rotation % 180 == 90)
{
fbo_rect->img_height = fbo_rect->max_img_height =
fbo_scale->scale_y * vp_width;
} else {
fbo_rect->img_height = fbo_rect->max_img_height =
fbo_scale->scale_y * vp_height;
}
break;
}