Commit Graph

64 Commits

Author SHA1 Message Date
Michael Niedermayer d23727e042 avcodec/adxdec: Fix runtime error: left shift of negative value -1
Fixes: 705/clusterfuzz-testcase-5129572590813184

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-03-04 17:48:04 +01:00
Michael Niedermayer 444e9874a7 Merge commit 'def97856de6021965db86c25a732d78689bd6bb0'
* commit 'def97856de6021965db86c25a732d78689bd6bb0':
  lavc: AV-prefix all codec capabilities

Conflicts:
	cmdutils.c
	ffmpeg.c
	ffplay.c
	libavcodec/8svx.c
	libavcodec/aacenc.c
	libavcodec/ac3dec.c
	libavcodec/adpcm.c
	libavcodec/alac.c
	libavcodec/atrac3plusdec.c
	libavcodec/bink.c
	libavcodec/dnxhddec.c
	libavcodec/dvdec.c
	libavcodec/dvenc.c
	libavcodec/ffv1dec.c
	libavcodec/ffv1enc.c
	libavcodec/fic.c
	libavcodec/flacdec.c
	libavcodec/flacenc.c
	libavcodec/flvdec.c
	libavcodec/fraps.c
	libavcodec/frwu.c
	libavcodec/gifdec.c
	libavcodec/h261dec.c
	libavcodec/hevc.c
	libavcodec/iff.c
	libavcodec/imc.c
	libavcodec/libopenjpegdec.c
	libavcodec/libvo-aacenc.c
	libavcodec/libvorbisenc.c
	libavcodec/libvpxdec.c
	libavcodec/libvpxenc.c
	libavcodec/libx264.c
	libavcodec/mjpegbdec.c
	libavcodec/mjpegdec.c
	libavcodec/mpegaudiodec_float.c
	libavcodec/msmpeg4dec.c
	libavcodec/mxpegdec.c
	libavcodec/nvenc_h264.c
	libavcodec/nvenc_hevc.c
	libavcodec/pngdec.c
	libavcodec/qpeg.c
	libavcodec/ra288.c
	libavcodec/rv10.c
	libavcodec/s302m.c
	libavcodec/sp5xdec.c
	libavcodec/takdec.c
	libavcodec/tiff.c
	libavcodec/tta.c
	libavcodec/utils.c
	libavcodec/v210dec.c
	libavcodec/vp6.c
	libavcodec/vp9.c
	libavcodec/wavpack.c
	libavcodec/yop.c

Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 22:50:18 +02:00
Vittorio Giovara def97856de lavc: AV-prefix all codec capabilities
Express bitfields more simply.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:58 +01:00
Michael Niedermayer e932ae5940 Merge commit 'd5cf5afabbf43f00283e70b12afbe1da030d85b6'
* commit 'd5cf5afabbf43f00283e70b12afbe1da030d85b6':
  adxdec: get rid of an avpriv function

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-09 22:38:13 +02:00
Anton Khirnov d5cf5afabb adxdec: get rid of an avpriv function
The only thing the demuxer needs is the sample rate to set the timebase,
which can be simply read with AV_RB32.
2014-07-09 13:37:18 +00:00
Michael Niedermayer 8aead3ffa8 avformat/adxdec: dont return random data on EOF
Fixes use of uninitialized memory
Partly fixes; msan_uninit-mem_7fb7d24780d0_2744_R03T.CAK
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-01-07 16:05:56 +01:00
Michael Niedermayer ee77140afa Merge commit 'b2bed9325dbd6be0da1d91ffed3f513c40274fd2'
* commit 'b2bed9325dbd6be0da1d91ffed3f513c40274fd2':
  cosmetics: Group .name and .long_name together in codec/format declarations

Conflicts:
	libavcodec/8svx.c
	libavcodec/alac.c
	libavcodec/cljr.c
	libavcodec/dnxhddec.c
	libavcodec/dnxhdenc.c
	libavcodec/dpxenc.c
	libavcodec/dvdec.c
	libavcodec/dvdsubdec.c
	libavcodec/dvdsubenc.c
	libavcodec/ffv1dec.c
	libavcodec/flacdec.c
	libavcodec/flvdec.c
	libavcodec/fraps.c
	libavcodec/frwu.c
	libavcodec/g726.c
	libavcodec/gif.c
	libavcodec/gifdec.c
	libavcodec/h261dec.c
	libavcodec/h263dec.c
	libavcodec/iff.c
	libavcodec/imc.c
	libavcodec/libopencore-amr.c
	libavcodec/libopenjpegdec.c
	libavcodec/libopenjpegenc.c
	libavcodec/libspeexenc.c
	libavcodec/libvo-amrwbenc.c
	libavcodec/libvorbisenc.c
	libavcodec/libvpxenc.c
	libavcodec/libx264.c
	libavcodec/libxavs.c
	libavcodec/libxvid.c
	libavcodec/ljpegenc.c
	libavcodec/mjpegbdec.c
	libavcodec/mjpegdec.c
	libavcodec/mpeg12dec.c
	libavcodec/mpeg4videodec.c
	libavcodec/msmpeg4dec.c
	libavcodec/pgssubdec.c
	libavcodec/pngdec.c
	libavcodec/pngenc.c
	libavcodec/proresdec_lgpl.c
	libavcodec/proresenc_kostya.c
	libavcodec/ra144enc.c
	libavcodec/rawdec.c
	libavcodec/rv10.c
	libavcodec/sp5xdec.c
	libavcodec/takdec.c
	libavcodec/tta.c
	libavcodec/v210dec.c
	libavcodec/vp6.c
	libavcodec/wavpack.c
	libavcodec/xbmenc.c
	libavcodec/yop.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-04 12:34:23 +02:00
Diego Biurrun b2bed9325d cosmetics: Group .name and .long_name together in codec/format declarations 2013-10-03 23:32:01 +02:00
Clément Bœsch 1ec94b0f06 lavc: factorize ff_{thread_,re,}get_buffer error messages.
Coccinelle profile used:

  @@
  expression r, ctx, f, loglevel, str, flags;
  @@

  -if ((r = ff_get_buffer(ctx, f, flags)) < 0) {
  -    av_log(ctx, loglevel, str);
  -    return r;
  -}
  +if ((r = ff_get_buffer(ctx, f, flags)) < 0)
  +    return r;

  @@
  expression r, ctx, f, loglevel, str;
  @@

  -if ((r = ff_reget_buffer(ctx, f)) < 0) {
  -    av_log(ctx, loglevel, str);
  -    return r;
  -}
  +if ((r = ff_reget_buffer(ctx, f)) < 0)
  +    return r;

  @@
  expression r, ctx, f, loglevel, str, flags;
  @@

  -if ((r = ff_thread_get_buffer(ctx, f, flags)) < 0) {
  -    av_log(ctx, loglevel, str);
  -    return r;
  -}
  +if ((r = ff_thread_get_buffer(ctx, f, flags)) < 0)
  +    return r;

...along with some manual patches for the remaining ones.
2013-03-13 19:00:10 +01:00
Michael Niedermayer 80e9e63c94 Merge commit '759001c534287a96dc96d1e274665feb7059145d'
* commit '759001c534287a96dc96d1e274665feb7059145d':
  lavc decoders: work with refcounted frames.

Anton Khirnov (1):
      lavc decoders: work with refcounted frames.

Clément Bœsch (47):
      lavc/ansi: reset file
      lavc/ansi: re-do refcounted frame changes from Anton
      fraps: reset file
      lavc/fraps: switch to refcounted frames
      gifdec: reset file
      lavc/gifdec: switch to refcounted frames
      dsicinav: resolve conflicts
      smc: resolve conflicts
      zmbv: resolve conflicts
      rpza: resolve conflicts
      vble: resolve conflicts
      xxan: resolve conflicts
      targa: resolve conflicts
      vmnc: resolve conflicts
      utvideodec: resolve conflicts
      tscc: resolve conflicts
      ulti: resolve conflicts
      ffv1dec: resolve conflicts
      dnxhddec: resolve conflicts
      v210dec: resolve conflicts
      vp3: resolve conflicts
      vcr1: resolve conflicts
      v210x: resolve conflicts
      wavpack: resolve conflicts
      pngdec: fix compilation
      roqvideodec: resolve conflicts
      pictordec: resolve conflicts
      mdec: resolve conflicts
      tiertexseqv: resolve conflicts
      smacker: resolve conflicts
      vb: resolve conflicts
      vqavideo: resolve conflicts
      xl: resolve conflicts
      tmv: resolve conflicts
      vmdav: resolve conflicts
      truemotion1: resolve conflicts
      truemotion2: resolve conflicts
      lcldec: fix compilation
      libcelt_dec: fix compilation
      qdrw: fix compilation
      r210dec: fix compilation
      rl2: fix compilation
      wnv1: fix compilation
      yop: fix compilation
      tiff: resolve conflicts
      interplayvideo: fix compilation
      qpeg: resolve conflicts (FIXME/TESTME).

Hendrik Leppkes (33):
      012v: convert to refcounted frames
      8bps: fix compilation
      8svx: resolve conflicts
      4xm: resolve conflicts
      aasc: resolve conflicts
      bfi: fix compilation
      aura: fix compilation
      alsdec: resolve conflicts
      avrndec: convert to refcounted frames
      avuidec: convert to refcounted frames
      bintext: convert to refcounted frames
      cavsdec: resolve conflicts
      brender_pix: convert to refcounted frames
      cinepak: resolve conflicts
      cinepak: avoid using AVFrame struct directly in private context
      cljr: fix compilation
      cpia: convert to refcounted frames
      cscd: resolve conflicts
      iff: resolve conflicts and do proper conversion to refcounted frames
      4xm: fix reference frame handling
      cyuv: fix compilation
      dxa: fix compilation
      eacmv: fix compilation
      eamad: fix compilation
      eatgv: fix compilation
      escape124: remove unused variable.
      escape130: convert to refcounted frames
      evrcdec: convert to refcounted frames
      exr: convert to refcounted frames
      mvcdec: convert to refcounted frames
      paf: properly free the frame data on decode close
      sgirle: convert to refcounted frames
      lavfi/moviesrc: use refcounted frames

Michael Niedermayer (56):
      Merge commit '759001c534287a96dc96d1e274665feb7059145d'
      resolve conflicts in headers
      motion_est: resolve conflict
      mpeg4videodec: fix conflicts
      dpcm conflict fix
      dpx: fix conflicts
      indeo3: resolve confilcts
      kmvc: resolve conflicts
      kmvc: resolve conflicts
      h264: resolve conflicts
      utils: resolve conflicts
      rawdec: resolve conflcits
      mpegvideo: resolve conflicts
      svq1enc: resolve conflicts
      mpegvideo: dont clear data, fix assertion failure on fate vsynth1 with threads
      pthreads: resolve conflicts
      frame_thread_encoder: simple compilefix not yet tested
      snow: update to buffer refs
      crytsalhd: fix compile
      dirac: switch to new API
      sonic: update to new API
      svq1: resolve conflict, update to new API
      ffwavesynth: update to new buffer API
      g729: update to new API
      indeo5: fix compile
      j2kdec: update to new buffer API
      linopencore-amr: fix compile
      libvorbisdec: update to new API
      loco: fix compile
      paf: update to new API
      proresdec: update to new API
      vp56: update to new api / resolve conflicts
      xface: convert to refcounted frames
      xan: fix compile&fate
      v408: update to ref counted buffers
      v308: update to ref counted buffers
      yuv4dec: update to ref counted buffers
      y41p: update to ref counted frames
      xbm: update to refcounted frames
      targa_y216: update to refcounted buffers
      qpeg: fix fate/crash
      cdxl: fix fate
      tscc: fix reget buffer useage
      targa_y216dec: fix style
      msmpeg4: fix fate
      h264: ref_picture() copy fields that have been lost too
      update_frame_pool: use channel field
      h264: Put code that prevents deadlocks back
      mpegvideo: dont allow last == current
      wmalossless: fix buffer ref messup
      ff_alloc_picture: free tables in case of dimension mismatches
      h264: fix null pointer dereference and assertion failure
      frame_thread_encoder: update to bufrefs
      ec: fix used arrays
      snowdec: fix off by 1 error in dimensions check
      h264: disallow single unpaired fields as references of frames

Paul B Mahol (2):
      lavc/vima: convert to refcounted frames
      sanm: convert to refcounted frames

Conflicts:
	libavcodec/4xm.c
	libavcodec/8bps.c
	libavcodec/8svx.c
	libavcodec/aasc.c
	libavcodec/alsdec.c
	libavcodec/anm.c
	libavcodec/ansi.c
	libavcodec/avs.c
	libavcodec/bethsoftvideo.c
	libavcodec/bfi.c
	libavcodec/c93.c
	libavcodec/cavsdec.c
	libavcodec/cdgraphics.c
	libavcodec/cinepak.c
	libavcodec/cljr.c
	libavcodec/cscd.c
	libavcodec/dnxhddec.c
	libavcodec/dpcm.c
	libavcodec/dpx.c
	libavcodec/dsicinav.c
	libavcodec/dvdec.c
	libavcodec/dxa.c
	libavcodec/eacmv.c
	libavcodec/eamad.c
	libavcodec/eatgq.c
	libavcodec/eatgv.c
	libavcodec/eatqi.c
	libavcodec/error_resilience.c
	libavcodec/escape124.c
	libavcodec/ffv1.h
	libavcodec/ffv1dec.c
	libavcodec/flicvideo.c
	libavcodec/fraps.c
	libavcodec/frwu.c
	libavcodec/g723_1.c
	libavcodec/gifdec.c
	libavcodec/h264.c
	libavcodec/h264.h
	libavcodec/h264_direct.c
	libavcodec/h264_loopfilter.c
	libavcodec/h264_refs.c
	libavcodec/huffyuvdec.c
	libavcodec/idcinvideo.c
	libavcodec/iff.c
	libavcodec/indeo2.c
	libavcodec/indeo3.c
	libavcodec/internal.h
	libavcodec/interplayvideo.c
	libavcodec/ivi_common.c
	libavcodec/jvdec.c
	libavcodec/kgv1dec.c
	libavcodec/kmvc.c
	libavcodec/lagarith.c
	libavcodec/libopenjpegdec.c
	libavcodec/mdec.c
	libavcodec/mimic.c
	libavcodec/mjpegbdec.c
	libavcodec/mjpegdec.c
	libavcodec/mmvideo.c
	libavcodec/motion_est.c
	libavcodec/motionpixels.c
	libavcodec/mpc7.c
	libavcodec/mpeg12.c
	libavcodec/mpeg4videodec.c
	libavcodec/mpegvideo.c
	libavcodec/mpegvideo.h
	libavcodec/msrle.c
	libavcodec/msvideo1.c
	libavcodec/nuv.c
	libavcodec/options_table.h
	libavcodec/pcx.c
	libavcodec/pictordec.c
	libavcodec/pngdec.c
	libavcodec/pnmdec.c
	libavcodec/pthread.c
	libavcodec/qpeg.c
	libavcodec/qtrle.c
	libavcodec/r210dec.c
	libavcodec/rawdec.c
	libavcodec/roqvideodec.c
	libavcodec/rpza.c
	libavcodec/smacker.c
	libavcodec/smc.c
	libavcodec/svq1dec.c
	libavcodec/svq1enc.c
	libavcodec/targa.c
	libavcodec/tiertexseqv.c
	libavcodec/tiff.c
	libavcodec/tmv.c
	libavcodec/truemotion1.c
	libavcodec/truemotion2.c
	libavcodec/tscc.c
	libavcodec/ulti.c
	libavcodec/utils.c
	libavcodec/utvideodec.c
	libavcodec/v210dec.c
	libavcodec/v210x.c
	libavcodec/vb.c
	libavcodec/vble.c
	libavcodec/vcr1.c
	libavcodec/vmdav.c
	libavcodec/vmnc.c
	libavcodec/vp3.c
	libavcodec/vp56.c
	libavcodec/vp56.h
	libavcodec/vp6.c
	libavcodec/vqavideo.c
	libavcodec/wavpack.c
	libavcodec/xl.c
	libavcodec/xxan.c
	libavcodec/zmbv.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-03-12 03:23:28 +01:00
Anton Khirnov 759001c534 lavc decoders: work with refcounted frames. 2013-03-08 07:38:30 +01:00
Michael Niedermayer d13f434dbb Merge commit 'e3db34291f4401a16f6ac92721617a9f33cd4c31'
* commit 'e3db34291f4401a16f6ac92721617a9f33cd4c31':
  amrnb: decode directly to the user-provided AVFrame
  als: decode directly to the user-provided AVFrame
  alac: decode directly to the user-provided AVFrame
  adxenc: alloc/free coded_frame instead of keeping it in the ADXContext
  adx: decode directly to the user-provided AVFrame

Conflicts:
	libavcodec/alsdec.c
	libavcodec/amrnbdec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-02-13 11:39:05 +01:00
Justin Ruggles 0588935e64 adx: decode directly to the user-provided AVFrame 2013-02-12 12:21:21 -05:00
Michael Niedermayer 874c5b02c4 Merge commit '594d4d5df3c70404168701dd5c90b7e6e5587793'
* commit '594d4d5df3c70404168701dd5c90b7e6e5587793':
  lavc: add a wrapper for AVCodecContext.get_buffer().

Conflicts:
	libavcodec/4xm.c
	libavcodec/8svx.c
	libavcodec/bmv.c
	libavcodec/cljr.c
	libavcodec/cscd.c
	libavcodec/dnxhddec.c
	libavcodec/dpcm.c
	libavcodec/dpx.c
	libavcodec/eacmv.c
	libavcodec/eamad.c
	libavcodec/frwu.c
	libavcodec/g723_1.c
	libavcodec/gifdec.c
	libavcodec/idcinvideo.c
	libavcodec/iff.c
	libavcodec/indeo3.c
	libavcodec/internal.h
	libavcodec/interplayvideo.c
	libavcodec/kmvc.c
	libavcodec/mpc7.c
	libavcodec/mpegaudiodec.c
	libavcodec/pcx.c
	libavcodec/pngdec.c
	libavcodec/pnmdec.c
	libavcodec/rl2.c
	libavcodec/snow.c
	libavcodec/targa.c
	libavcodec/tscc.c
	libavcodec/txd.c
	libavcodec/utils.c
	libavcodec/v210dec.c
	libavcodec/vb.c
	libavcodec/vmdav.c
	libavcodec/vp56.c
	libavcodec/vqavideo.c
	libavcodec/wavpack.c
	libavcodec/wnv1.c
	libavcodec/xl.c
	libavcodec/yop.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-12-05 15:18:12 +01:00
Anton Khirnov 594d4d5df3 lavc: add a wrapper for AVCodecContext.get_buffer().
It will be useful in the upcoming transition to refcounted AVFrames.
2012-12-04 21:41:59 +01:00
Michael Niedermayer eadba3e94d Merge commit 'cbcd497f384f0f8ef3f76f85b29b644b900d6b9f'
* commit 'cbcd497f384f0f8ef3f76f85b29b644b900d6b9f':
  adxdec: use planar sample format
  adpcmdec: use planar sample format for adpcm_thp
  adpcmdec: use planar sample format for adpcm_ea_xas
  adpcmdec: use planar sample format for adpcm_ea_r1/r2/r3
  adpcmdec: use planar sample format for adpcm_xa
  adpcmdec: use planar sample format for adpcm_ima_ws for vqa version 3
  adpcmdec: use planar sample format for adpcm_4xm
  adpcmdec: use planar sample format for adpcm_ima_wav
  adpcmdec: use planar sample format for adpcm_ima_qt
  pcmdec: use planar sample format for pcm_lxf
  mace: use planar sample format
  atrac1: use planar sample format
  build: non-x86: Only compile mpegvideo optimizations when necessary
  rtpdec_mpeg4: au_headers is a single array, simple av_free is enough
  avcodec: free extended_data instead address of it
  fate: Add tests of the ff_make_absolute_url function
  url: Handle relative urls starting with two slashes
  url: Handle relative urls being just a new query string
  url: Don't treat slashes in query parameters as directory separators

Conflicts:
	libavcodec/adxdec.c
	libavcodec/mips/Makefile
	libavcodec/pcm.c
	libavcodec/utils.c
	libavformat/Makefile
	libavformat/utils.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-10-10 13:01:27 +02:00
Justin Ruggles cbcd497f38 adxdec: use planar sample format 2012-10-09 09:03:52 -04:00
Michael Niedermayer 7a72695c05 Merge commit '36ef5369ee9b336febc2c270f8718cec4476cb85'
* commit '36ef5369ee9b336febc2c270f8718cec4476cb85':
  Replace all CODEC_ID_* with AV_CODEC_ID_*
  lavc: add AV prefix to codec ids.

Conflicts:
	doc/APIchanges
	doc/examples/decoding_encoding.c
	doc/examples/muxing.c
	ffmpeg.c
	ffprobe.c
	ffserver.c
	libavcodec/8svx.c
	libavcodec/avcodec.h
	libavcodec/dnxhd_parser.c
	libavcodec/dvdsubdec.c
	libavcodec/error_resilience.c
	libavcodec/h263dec.c
	libavcodec/libvorbisenc.c
	libavcodec/mjpeg_parser.c
	libavcodec/mjpegenc.c
	libavcodec/mpeg12.c
	libavcodec/mpeg4videodec.c
	libavcodec/mpegvideo.c
	libavcodec/mpegvideo_enc.c
	libavcodec/pcm.c
	libavcodec/r210dec.c
	libavcodec/utils.c
	libavcodec/v210dec.c
	libavcodec/version.h
	libavdevice/alsa-audio-dec.c
	libavdevice/bktr.c
	libavdevice/v4l2.c
	libavformat/asfdec.c
	libavformat/asfenc.c
	libavformat/avformat.h
	libavformat/avidec.c
	libavformat/caf.c
	libavformat/electronicarts.c
	libavformat/flacdec.c
	libavformat/flvdec.c
	libavformat/flvenc.c
	libavformat/framecrcenc.c
	libavformat/img2.c
	libavformat/img2dec.c
	libavformat/img2enc.c
	libavformat/ipmovie.c
	libavformat/isom.c
	libavformat/matroska.c
	libavformat/matroskadec.c
	libavformat/matroskaenc.c
	libavformat/mov.c
	libavformat/movenc.c
	libavformat/mp3dec.c
	libavformat/mpeg.c
	libavformat/mpegts.c
	libavformat/mxf.c
	libavformat/mxfdec.c
	libavformat/mxfenc.c
	libavformat/nsvdec.c
	libavformat/nut.c
	libavformat/oggenc.c
	libavformat/pmpdec.c
	libavformat/rawdec.c
	libavformat/rawenc.c
	libavformat/riff.c
	libavformat/sdp.c
	libavformat/utils.c
	libavformat/vocenc.c
	libavformat/wtv.c
	libavformat/xmv.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-07 22:45:46 +02:00
Anton Khirnov 36ef5369ee Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
Michael Niedermayer 8dfb13ea59 adxdec: Check available space before decoding block.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-04-16 02:18:10 +02:00
Michael Niedermayer 7f83db3124 Merge remote-tracking branch 'qatar/master'
* qatar/master: (46 commits)
  mtv: Make sure audio_subsegments is not 0
  v4l2: use V4L2_FMT_FLAG_EMULATED only if it is defined
  avconv: add symbolic names for -vsync parameters
  flvdec: Fix compiler warning for uninitialized variables
  rtsp: Fix compiler warning for uninitialized variable
  ulti: convert to new bytestream API.
  swscale: Use standard multiple inclusion guards in ppc/ header files.
  Place some START_TIMER invocations in separate blocks.
  v4l2: list available formats
  v4l2: set the proper codec_tag
  v4l2: refactor device_open
  v4l2: simplify away io_method
  v4l2: cosmetics
  v4l2: uniform and format options
  v4l2: do not force interlaced mode
  avio: exit early in fill_buffer without read_packet
  vc1dec: fix invalid memory access for small video dimensions
  rv34: fix invalid memory access for small video dimensions
  rv34: joint coefficient decoding and dequantization
  avplay: Don't call avio_set_interrupt_cb(NULL)
  ...

Conflicts:
	Changelog
	avconv.c
	doc/APIchanges
	doc/indevs.texi
	libavcodec/adxenc.c
	libavcodec/dnxhdenc.c
	libavcodec/h264.c
	libavdevice/v4l2.c
	libavformat/flvdec.c
	libavformat/mtv.c
	libswscale/utils.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-05 02:03:12 +01:00
Michael Niedermayer ad1c8dd673 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  fate: add dxtory test
  adx_parser: rewrite.
  adxdec: Validate channel count to fix a division by zero.
  adxdec: Do not require extradata.
  cmdutils: K&R reformatting cosmetics
  alacdec: implement the 2-pass prediction type.
  alacenc: implement the 2-pass prediction type.
  alacenc: do not generate invalid multi-channel ALAC files
  alacdec: fill in missing or guessed info about the extradata format.
  utvideo: proper median prediction for interlaced videos
  lavu: bump lavu minor for av_popcount64
  dca: K&R formatting cosmetics
  dct: K&R formatting cosmetics
  lavf: flush decoders in avformat_find_stream_info().
  win32: detect number of CPUs using affinity
  Add av_popcount64
  snow: Restore three mistakenly removed casts.

Conflicts:
	cmdutils.c
	doc/APIchanges
	libavcodec/adx_parser.c
	libavcodec/adxdec.c
	libavcodec/alacenc.c
	libavutil/avutil.h
	tests/fate/screen.mak

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-04 01:12:34 +01:00
Justin Ruggles 730280f90d adxdec: clear eof flag and channel states when seeking 2012-01-03 18:47:42 -05:00
Michael Niedermayer 4f1a787744 adxdec: Do not require extradata.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
2012-01-03 16:28:17 -05:00
Michael Niedermayer 6b6b84ae16 adxdec: Fix division by zero
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-12-18 20:49:34 +01:00
Michael Niedermayer bdd62a615a adxdec: Do not require extradata.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2011-12-18 20:49:34 +01:00
Michael Niedermayer e4de71677f Merge remote-tracking branch 'qatar/master'
* qatar/master:
  aac_latm: reconfigure decoder on audio specific config changes
  latmdec: fix audio specific config parsing
  Add avcodec_decode_audio4().
  avcodec: change number of plane pointers from 4 to 8 at next major bump.
  Update developers documentation with coding conventions.
  svq1dec: avoid undefined get_bits(0) call
  ARM: h264dsp_neon cosmetics
  ARM: make some NEON macros reusable
  Do not memcpy raw video frames when using null muxer
  fate: update asf seektest
  vp8: flush buffers on size changes.
  doc: improve general documentation for MacOSX
  asf: use packet dts as approximation of pts
  asf: do not call av_read_frame
  rtsp: Initialize the media_type_mask in the rtp guessing demuxer
  Cleaned up alacenc.c

Conflicts:
	doc/APIchanges
	doc/developer.texi
	libavcodec/8svx.c
	libavcodec/aacdec.c
	libavcodec/ac3dec.c
	libavcodec/avcodec.h
	libavcodec/nellymoserdec.c
	libavcodec/tta.c
	libavcodec/utils.c
	libavcodec/version.h
	libavcodec/wmadec.c
	libavformat/asfdec.c
	tests/ref/seek/lavf_asf

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-12-03 03:00:30 +01:00
Justin Ruggles 0eea212943 Add avcodec_decode_audio4().
Deprecate avcodec_decode_audio3().
Implement audio support in avcodec_default_get_buffer().
Implement the new audio decoder API in all audio decoders.
2011-12-02 17:40:40 -05:00
Michael Niedermayer 5c15b78e4a Merge remote-tracking branch 'qatar/master'
* qatar/master: (42 commits)
  swscale: fix signed overflow in yuv2mono_X_c_template
  snow: fix integer overflows
  svq1enc: remove stale altivec-related hack
  snow: fix signed overflow in byte to 32-bit replication
  adx: rename ff_adx_decode_header() to avpriv_adx_decode_header()
  avformat: add CRI ADX format demuxer
  adx: add an ADX parser.
  adx: move header decoding to ADX common code
  adx: calculate the number of blocks in a packet
  adx: define and use 2 new macro constants BLOCK_SIZE and BLOCK_SAMPLES
  adx: check for unsupported ADX formats
  adx: simplify encoding by using put_sbits()
  adx: calculate correct LPC coeffs
  adx: use 12-bit coefficients instead of 14-bit to avoid integer overflow
  adx: simplify adx_decode() by using get_sbits() to read residual samples
  adx: fix the data offset parsing in adx_decode_header()
  adx: remove unneeded post-decode channel interleaving
  adx: validate header values
  adx: cosmetics: general pretty-printing and comment clean-up
  adx: remove useless comments
  ...

Conflicts:
	Changelog
	libavcodec/cook.c
	libavcodec/fraps.c
	libavcodec/nuv.c
	libavcodec/pthread.c
	libavcodec/version.h
	libavformat/Makefile
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-11-27 00:30:13 +01:00
Justin Ruggles 9d2dd356c2 adx: rename ff_adx_decode_header() to avpriv_adx_decode_header()
It is used by the ADX decoder, and therefore needs to be exported in order to
work with shared libs.
2011-11-26 17:00:00 -05:00
Justin Ruggles 27360ccc5e adx: add an ADX parser.
This simplifies the decoder so it doesn't have to process an in-packet header
or handle arbitrary-sized packets. It also fixes decoding of files with large
headers.
2011-11-26 16:25:07 -05:00
Justin Ruggles d8cec2d7fc adx: move header decoding to ADX common code 2011-11-26 16:25:07 -05:00
Justin Ruggles 7ff55d9bdb adx: calculate the number of blocks in a packet 2011-11-26 16:25:07 -05:00
Justin Ruggles 05c1f11b56 adx: define and use 2 new macro constants BLOCK_SIZE and BLOCK_SAMPLES 2011-11-26 16:25:07 -05:00
Justin Ruggles d1745619db adx: check for unsupported ADX formats 2011-11-26 16:25:07 -05:00
Justin Ruggles b237248e29 adx: calculate correct LPC coeffs
Instead of using fixed coefficients, the correct way is to calculate the
coefficients using the highpass cutoff frequency from the ADX stream header
and the sample rate.
2011-11-26 16:25:06 -05:00
Justin Ruggles 954d94dd5e adx: use 12-bit coefficients instead of 14-bit to avoid integer overflow 2011-11-26 16:25:06 -05:00
Justin Ruggles c52ddc6024 adx: simplify adx_decode() by using get_sbits() to read residual samples 2011-11-26 16:25:06 -05:00
Justin Ruggles ca9e4727ba adx: fix the data offset parsing in adx_decode_header()
first 2 bytes are 0x80, 0x00. offset is only 16-bit.
this is according to format descriptions on multimedia wiki and wikipedia.
2011-11-26 16:25:06 -05:00
Justin Ruggles 837bbd19eb adx: remove unneeded post-decode channel interleaving
instead interleave channels while decoding
2011-11-26 16:25:06 -05:00
Justin Ruggles e2d1eace00 adx: validate header values 2011-11-26 16:25:06 -05:00
Justin Ruggles 8db67610c0 adx: cosmetics: general pretty-printing and comment clean-up 2011-11-26 16:25:06 -05:00
Justin Ruggles fbc79a9101 adx: remove useless comments 2011-11-26 16:25:06 -05:00
Justin Ruggles e0722d7fb7 adx: change short to int16_t 2011-11-26 16:25:06 -05:00
Justin Ruggles dd1b9f7cd9 adx: rename struct PREV to ADXChannelState 2011-11-26 16:25:06 -05:00
Michael Niedermayer faba79e080 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  mxfdec: Include FF_INPUT_BUFFER_PADDING_SIZE when allocating extradata.
  H.264: tweak some other x86 asm for Atom
  probe: Fix insane flow control.
  mpegts: remove invalid error check
  s302m: use nondeprecated audio sample format API
  lavc: use designated initialisers for all codecs.
  x86: cabac: add operand size suffixes missing from 6c32576

Conflicts:
	libavcodec/ac3enc_float.c
	libavcodec/flacenc.c
	libavcodec/frwu.c
	libavcodec/pictordec.c
	libavcodec/qtrleenc.c
	libavcodec/v210enc.c
	libavcodec/wmv2dec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-07-30 06:46:08 +02:00
Anton Khirnov ec6402b7c5 lavc: use designated initialisers for all codecs.
It's more readable and less prone to breakage.
2011-07-29 08:42:34 +02:00
Mans Rullgard 2912e87a6c Replace FFmpeg with Libav in licence headers
Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-03-19 13:33:20 +00:00
Diego Elio Pettenò e7e2df27f8 Add ff_ prefix to data symbols of encoders, decoders, hwaccel, parsers, bsf.
None of these symbols should be accessed directly, so declare them as
hidden.

Signed-off-by: Mans Rullgard <mans@mansr.com>
(cherry picked from commit d36beb3f69)
2011-01-28 03:15:34 +01:00
Diego Elio Pettenò d36beb3f69 Add ff_ prefix to data symbols of encoders, decoders, hwaccel, parsers, bsf.
None of these symbols should be accessed directly, so declare them as
hidden.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2011-01-26 16:08:45 +00:00