[FFmpeg-devel] trac issue #251 and AVFMT_RAWPICTURE

Stefano Sabatini stefano.sabatini-lala at poste.it
Mon May 30 01:27:42 CEST 2011


curiously today is the second time I step into the AVFMT_RAWPICTURE

yuv4mpeg is currently segfaulting with -vcodec copy, that's because
the code which converts AVFrame -> AVPicture in
ffmpeg.c:do_video_out() is not executed, and the code in

   picture = (AVPicture *)pkt->data;
   ptr = pkt->data[0];

   ptr = picture->data[0]; => set to NULL
   for(i=0;i<height;i++) {
        avio_write(pb, ptr, width);
        ptr += picture->linesize[0];

fails with a crash.

AVFMT_RAWPICTURE is currently used only in yuv4mpeg and in nullenc
(where it is not even required), so I wonder if it would make sense to
simply drop the flag (and simplify the API, which is currently
complicated for so small gain).
FFmpeg = Freak & Faithful Mere Power Elastic Guru

More information about the ffmpeg-devel mailing list