mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-25 17:10:12 +00:00
Calculate 1:1 PAR from right dimensions.
Frame cache can be stale or have awkward dimensions which don't really reflect 1:1 PAR semantics.
This commit is contained in:
parent
347fdaadce
commit
321ffcbca6
@ -1396,7 +1396,7 @@ static void d3d9_set_aspect_ratio(void *data, unsigned aspect_ratio_idx)
|
||||
switch (aspect_ratio_idx)
|
||||
{
|
||||
case ASPECT_RATIO_SQUARE:
|
||||
gfx_set_square_pixel_viewport(g_extern.frame_cache.width, g_extern.frame_cache.height);
|
||||
gfx_set_square_pixel_viewport(g_system.system.av_info.geometry.base_width, g_extern.system.av_info.geometry.base_height);
|
||||
break;
|
||||
|
||||
case ASPECT_RATIO_CORE:
|
||||
|
2
gfx/gl.c
2
gfx/gl.c
@ -2400,7 +2400,7 @@ static void gl_set_aspect_ratio(void *data, unsigned aspect_ratio_idx)
|
||||
switch (aspect_ratio_idx)
|
||||
{
|
||||
case ASPECT_RATIO_SQUARE:
|
||||
gfx_set_square_pixel_viewport(g_extern.frame_cache.width, g_extern.frame_cache.height);
|
||||
gfx_set_square_pixel_viewport(g_extern.system.av_info.geometry.base_width, g_extern.system.av_info.geometry.base_height);
|
||||
break;
|
||||
|
||||
case ASPECT_RATIO_CORE:
|
||||
|
@ -286,7 +286,7 @@ static void gx_set_aspect_ratio(void *data, unsigned aspect_ratio_idx)
|
||||
gx_video_t *gx = (gx_video_t*)driver.video_data;
|
||||
|
||||
if (aspect_ratio_idx == ASPECT_RATIO_SQUARE)
|
||||
gfx_set_square_pixel_viewport(g_extern.frame_cache.width, g_extern.frame_cache.height);
|
||||
gfx_set_square_pixel_viewport(g_extern.system.av_info.geometry.base_width, g_extern.system.av_info.geometry.base_height);
|
||||
else if (aspect_ratio_idx == ASPECT_RATIO_CORE)
|
||||
gfx_set_core_viewport();
|
||||
else if (aspect_ratio_idx == ASPECT_RATIO_CONFIG)
|
||||
|
Loading…
Reference in New Issue
Block a user