Merge remote-tracking branch 'qatar/master'
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 16 Jul 2011 17:40:35 +0000 (19:40 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 16 Jul 2011 17:43:35 +0000 (19:43 +0200)
* qatar/master: (22 commits)
  arm: remove disabled function dct_unquantize_h263_inter_iwmmxt()
  Remove commented-out call to non-existing function print_pow1().
  Do not decode RV30 files if the extradata is too small
  flashsv: split flashsv_decode_block() off from flashsv_decode_frame().
  ppc: remove disabled code
  libspeexdec: Drop const qualifier to silence compiler warning.
  libopenjpeg: Drop const qualifier to silence compiler warning.
  alac: Remove unused dummy code.
  Remove unused structs and tables.
  vaapi: do not assert on value read from input bitstream
  flashsvenc: replace bitstream description by a link to the specification
  flashsvenc: drop unnecessary cast
  flashsvenc: improve some variable names and fix corresponding comments
  flashsvenc: merge two consecutive if-conditions
  flashsvenc: merge variable declarations and initializations
  flashsvenc: convert some debug av_log() to av_dlog()
  flashsvenc: whitespace cosmetics
  flashsvenc: drop some unnecessary parentheses
  flashsvenc: fix some comment typos
  aacps: skip some memcpy() if src and dst would be equal
  ...

Conflicts:
libavcodec/vaapi_mpeg2.c
libavformat/aviobuf.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
20 files changed:
1  2 
libavcodec/aacps.c
libavcodec/alac.c
libavcodec/arm/mpegvideo_iwmmxt.c
libavcodec/cabac.c
libavcodec/flashsv.c
libavcodec/flashsvenc.c
libavcodec/libopenjpeg.c
libavcodec/libspeexdec.c
libavcodec/mjpegdec.c
libavcodec/mpegaudioenc.c
libavcodec/ppc/dsputil_altivec.c
libavcodec/ppc/dsputil_ppc.c
libavcodec/ppc/fdct_altivec.c
libavcodec/ppc/mpegvideo_altivec.c
libavcodec/rv30.c
libavcodec/sp5x.h
libavcodec/vaapi_mpeg2.c
libavcodec/vc1data.c
libavformat/aviobuf.c
libavformat/utils.c

Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
@@@ -171,22 -160,23 +160,23 @@@ static int encode_bitstream(FlashSVCont
              /* copy the block to the temp buffer before compression
               * (if it differs from the previous frame's block) */
              res = copy_region_enc(p->data[0], s->tmpblock,
-                                   s->image_height - (hp + hs + 1),
-                                   wp, hs, ws, p->linesize[0], previous_frame);
+                                   s->image_height - (y_pos + cur_blk_height + 1),
+                                   x_pos, cur_blk_height, cur_blk_width,
+                                   p->linesize[0], previous_frame);
  
              if (res || *I_frame) {
-                 unsigned long zsize;
-                 zsize = 3 * block_width * block_height;
-                 ret   = compress2(ptr + 2, &zsize, s->tmpblock, 3 * ws * hs, 9);
+                 unsigned long zsize = 3 * block_width * block_height;
+                 ret = compress2(ptr + 2, &zsize, s->tmpblock,
+                                 3 * cur_blk_width * cur_blk_height, 9);
  
-                 //ret = deflateReset(&(s->zstream));
+                 //ret = deflateReset(&s->zstream);
                  if (ret != Z_OK)
-                     av_log(s->avctx, AV_LOG_ERROR, "error while compressing block %dx%d\n", i, j);
+                     av_log(s->avctx, AV_LOG_ERROR,
+                            "error while compressing block %dx%d\n", i, j);
  
-                 bytestream_put_be16(&ptr, (unsigned int) zsize);
+                 bytestream_put_be16(&ptr, zsize);
                  buf_pos += zsize + 2;
-                 //av_log(avctx, AV_LOG_ERROR, "buf_pos = %d\n", buf_pos);
 -                av_dlog(avctx, "buf_pos = %d\n", buf_pos);
++                av_dlog(s->avctx, "buf_pos = %d\n", buf_pos);
              } else {
                  pred_blocks++;
                  bytestream_put_be16(&ptr, 0);
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
@@@ -852,14 -844,6 +853,7 @@@ int ffio_fdopen(AVIOContext **s, URLCon
          av_free(buffer);
          return AVERROR(ENOMEM);
      }
-     if (ffio_init_context(*s, buffer, buffer_size,
-                       h->flags & AVIO_FLAG_WRITE, h,
-                       (void*)ffurl_read, (void*)ffurl_write, (void*)ffurl_seek) < 0) {
-         av_free(buffer);
-         av_freep(s);
-         return AVERROR(EIO);
-     }
 +
  #if FF_API_OLD_AVIO
      (*s)->is_streamed = h->is_streamed;
  #endif
@@@ -1848,9 -1819,9 +1848,9 @@@ static int has_duration(AVFormatContex
   *
   * Also computes the global bitrate if possible.
   */
- static void av_update_stream_timings(AVFormatContext *ic)
+ static void update_stream_timings(AVFormatContext *ic)
  {
 -    int64_t start_time, start_time1, end_time, end_time1;
 +    int64_t start_time, start_time1, start_time_text, end_time, end_time1;
      int64_t duration, duration1;
      int i;
      AVStream *st;
@@@ -2060,11 -2024,10 +2060,11 @@@ static void estimate_timings(AVFormatCo
      } else {
          av_log(ic, AV_LOG_WARNING, "Estimating duration from bitrate, this may be inaccurate\n");
          /* less precise: use bitrate info */
-         av_estimate_timings_from_bit_rate(ic);
+         estimate_timings_from_bit_rate(ic);
      }
-     av_update_stream_timings(ic);
+     update_stream_timings(ic);
  
 +#if 0
      {
          int i;
          AVStream av_unused *st;