diff --git a/gfx/drivers/gl.c b/gfx/drivers/gl.c index ab14c67237..fdadbd3077 100644 --- a/gfx/drivers/gl.c +++ b/gfx/drivers/gl.c @@ -2865,7 +2865,8 @@ static bool gl2_frame(void *data, const void *frame, if (gl->should_resize) { - video_info->cb_set_resize(context_data, + if (gl->ctx_driver->set_resize) + gl->ctx_driver->set_resize(context_data, width, height); gl->should_resize = false; diff --git a/gfx/drivers/gl1.c b/gfx/drivers/gl1.c index a91e22d2d4..bb956ec74c 100644 --- a/gfx/drivers/gl1.c +++ b/gfx/drivers/gl1.c @@ -720,8 +720,9 @@ static bool gl1_gfx_frame(void *data, const void *frame, mode.width = width; mode.height = height; - video_info->cb_set_resize(video_info->context_data, - mode.width, mode.height); + if (gl1->ctx_driver->set_resize) + gl1->ctx_driver->set_resize(video_info->context_data, + mode.width, mode.height); gl1_gfx_set_viewport(gl1, video_width, video_height, false, true); diff --git a/gfx/drivers/gl_core.c b/gfx/drivers/gl_core.c index 5c2035e92f..e426a3cb18 100644 --- a/gfx/drivers/gl_core.c +++ b/gfx/drivers/gl_core.c @@ -1877,7 +1877,9 @@ static bool gl_core_frame(void *data, const void *frame, if (gl->should_resize) { - video_info->cb_set_resize(context_data, width, height); + if (gl->ctx_driver->set_resize) + gl->ctx_driver->set_resize(context_data, + width, height); gl->should_resize = false; } diff --git a/gfx/drivers/vulkan.c b/gfx/drivers/vulkan.c index 8191b638e7..fec29e856c 100644 --- a/gfx/drivers/vulkan.c +++ b/gfx/drivers/vulkan.c @@ -2241,7 +2241,8 @@ static bool vulkan_frame(void *data, const void *frame, mode.width = width; mode.height = height; - video_info->cb_set_resize(context_data, mode.width, mode.height); + if (vk->ctx_driver->set_resize) + vk->ctx_driver->set_resize(context_data, mode.width, mode.height); vk->should_resize = false; } diff --git a/retroarch.c b/retroarch.c index 0d6c5f7f61..06d5198b16 100644 --- a/retroarch.c +++ b/retroarch.c @@ -32694,7 +32694,6 @@ void video_driver_build_info(video_frame_info_t *video_info) video_info->input_driver_nonblock_state = p_rarch->input_driver_nonblock_state; video_info->context_data = p_rarch->video_context_data; video_info->cb_swap_buffers = p_rarch->current_video_context.swap_buffers; - video_info->cb_set_resize = p_rarch->current_video_context.set_resize; video_info->userdata = VIDEO_DRIVER_GET_PTR_INTERNAL(false); diff --git a/retroarch.h b/retroarch.h index d84eb8eeda..e6a25478c5 100644 --- a/retroarch.h +++ b/retroarch.h @@ -1198,7 +1198,6 @@ typedef struct video_frame_info } osd_stat_params; void (*cb_swap_buffers)(void*); - bool (*cb_set_resize)(void*, unsigned, unsigned); void *context_data; void *userdata;