Simplify video_context_driver_translate_aspect

This commit is contained in:
twinaphex 2020-03-28 05:44:58 +01:00
parent 8b8d9e0841
commit 4589fde775
2 changed files with 4 additions and 7 deletions

View File

@ -24419,15 +24419,12 @@ bool video_context_driver_get_video_output_next(void)
return true;
}
bool video_context_driver_translate_aspect(gfx_ctx_aspect_t *aspect)
void video_context_driver_translate_aspect(gfx_ctx_aspect_t *aspect)
{
if (!video_context_data || !aspect)
return false;
if (!current_video_context.translate_aspect)
return false;
if (!video_context_data || !aspect || !current_video_context.translate_aspect)
return;
*aspect->aspect = current_video_context.translate_aspect(
video_context_data, aspect->width, aspect->height);
return true;
}
void video_context_driver_free(void)

View File

@ -1796,7 +1796,7 @@ bool video_context_driver_set_flags(gfx_ctx_flags_t *flags);
bool video_context_driver_get_metrics(gfx_ctx_metrics_t *metrics);
bool video_context_driver_translate_aspect(gfx_ctx_aspect_t *aspect);
void video_context_driver_translate_aspect(gfx_ctx_aspect_t *aspect);
bool video_context_driver_input_driver(gfx_ctx_input_t *inp);