Merge remote-tracking branch 'qatar/master'
authorMichael Niedermayer <michaelni@gmx.at>
Sun, 25 Mar 2012 00:56:53 +0000 (01:56 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sun, 25 Mar 2012 00:56:53 +0000 (01:56 +0100)
* qatar/master:
  avc: Add a function for converting mp4 style extradata to annex b
  pthread: free progress if buffer allocation failed.
  lavc/avconv: support changing frame sizes in codecs with frame mt.
  libavformat: Document who sets the AVStream.id field
  utvideo: mark output picture as keyframe.
  sunrast: Add support for negative linesize.
  vp8: fix update_lf_deltas in libavcodec/vp8.c
  ralf: read Huffman code lengths without GetBitContext

Conflicts:
ffmpeg.c
libavcodec/sunrastenc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
ffmpeg.c
libavcodec/pthread.c
libavcodec/utils.c
libavcodec/utvideo.c
libavcodec/vp8.c
libavformat/avc.c
libavformat/avc.h
libavformat/avformat.h
libavformat/movenc.c

diff --cc ffmpeg.c
+++ b/ffmpeg.c
@@@ -553,10 -501,7 +553,10 @@@ static int codec_get_buffer(AVCodecCont
      FrameBuffer *buf;
      int ret, i;
  
-     if (!ist->buffer_pool && (ret = alloc_buffer(s, ist, &ist->buffer_pool)) < 0)
 +    if(av_image_check_size(s->width, s->height, 0, s) || s->pix_fmt<0)
 +        return -1;
 +
+     if (!ist->buffer_pool && (ret = alloc_buffer(ist, s, &ist->buffer_pool)) < 0)
          return ret;
  
      buf              = ist->buffer_pool;
      if (buf->w != s->width || buf->h != s->height || buf->pix_fmt != s->pix_fmt) {
          av_freep(&buf->base[0]);
          av_free(buf);
-         if ((ret = alloc_buffer(s, ist, &buf)) < 0)
 +        ist->dr1 = 0;
+         if ((ret = alloc_buffer(ist, s, &buf)) < 0)
              return ret;
      }
      buf->refcount++;
Simple merge
@@@ -513,19 -475,14 +508,23 @@@ static int video_get_buffer(AVCodecCont
      }
      pic->extended_data = pic->data;
      avci->buffer_count++;
+     pic->width  = buf->width;
+     pic->height = buf->height;
+     pic->format = buf->pix_fmt;
+     pic->sample_aspect_ratio = s->sample_aspect_ratio;
  
 -    if(s->pkt) pic->pkt_pts= s->pkt->pts;
 -    else       pic->pkt_pts= AV_NOPTS_VALUE;
 +    if (s->pkt) {
 +        pic->pkt_pts = s->pkt->pts;
 +        pic->pkt_pos = s->pkt->pos;
 +    } else {
 +        pic->pkt_pts = AV_NOPTS_VALUE;
 +        pic->pkt_pos = -1;
 +    }
      pic->reordered_opaque= s->reordered_opaque;
 +    pic->sample_aspect_ratio = s->sample_aspect_ratio;
 +    pic->width               = s->width;
 +    pic->height              = s->height;
 +    pic->format              = s->pix_fmt;
  
      if(s->debug&FF_DEBUG_BUFFERS)
          av_log(s, AV_LOG_DEBUG, "default_get_buffer called on pic %p, %d "
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge