Commit 32f1a288 authored by Marton Balint's avatar Marton Balint

ffplay: handle fullscreen status on resize event

In some cases resize events can happen even during fullscreen, so let's pass
the proper flag to SDL_SetVideoMode.

Fixes ticket #3964.
Reported-by: 's avatarJeff Dwork <jeff@reggie.com>
Signed-off-by: 's avatarMarton Balint <cus@passwd.hu>
parent 6843b9dc
......@@ -3467,7 +3467,7 @@ static void event_loop(VideoState *cur_stream)
break;
case SDL_VIDEORESIZE:
screen = SDL_SetVideoMode(FFMIN(16383, event.resize.w), event.resize.h, 0,
SDL_HWSURFACE|SDL_RESIZABLE|SDL_ASYNCBLIT|SDL_HWACCEL);
SDL_HWSURFACE|(is_full_screen?SDL_FULLSCREEN:SDL_RESIZABLE)|SDL_ASYNCBLIT|SDL_HWACCEL);
if (!screen) {
av_log(NULL, AV_LOG_FATAL, "Failed to set video mode\n");
do_exit(cur_stream);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment