[FFmpeg-devel] [PATCH 1/2] ffplay: avoid window resize crash on osx with libsdl 1.2.14

Carl Eugen Hoyos cehoyos at ag.or.at
Wed Oct 12 23:53:05 CEST 2011


Jean First <jeanfirst <at> gmail.com> writes:

> +++ b/ffplay.c
> @@ -947,13 +947,7 @@ static int video_open(VideoState *is){
>      if(screen && is->width == screen->w && screen->w == w
>         && is->height== screen->h && screen->h == h)
>          return 0;
> -
> -#ifndef __APPLE__
>      screen = SDL_SetVideoMode(w, h, 0, flags);
> -#else
> -    /* setting bits_per_pixel = 0 or 32 causes blank video on OS X */
> -    screen = SDL_SetVideoMode(w, h, 24, flags);
> -#endif

This patch causes a double-free on exit in SDL_FreeYUVOverlay() for me on PPC
oSX 10.5, but since it fixes wrong colours in many samples, I am all for it.

Carl Eugen



More information about the ffmpeg-devel mailing list