1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-08-11 03:45:05 +02:00
Commit Graph

53 Commits

Author SHA1 Message Date
Clément Bœsch
15b26e88cb Merge commit '9df889a5f116c1ee78c2f239e0ba599c492431aa'
* commit '9df889a5f116c1ee78c2f239e0ba599c492431aa':
  h264: rename h264.[ch] to h264dec.[ch]

Merged-by: Clément Bœsch <u@pkh.me>
2016-07-29 11:01:36 +02:00
Anton Khirnov
9df889a5f1 h264: rename h264.[ch] to h264dec.[ch]
This is more consistent with the naming of other decoders.
2016-06-21 11:11:26 +02:00
Vittorio Giovara
41ed7ab45f cosmetics: Fix spelling mistakes
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-05-04 18:16:21 +02:00
Sebastien Zwickert
11d923d414 avcodec: add new Videotoolbox hwaccel. 2015-08-03 10:12:10 +02:00
Michael Niedermayer
daff49ccf3 Merge commit '80f955c90867561dcce769216bc497e13281eb38'
* commit '80f955c90867561dcce769216bc497e13281eb38':
  vda: Check the correct pointer for buffer allocation

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-03 04:36:31 +02:00
Luca Barbato
80f955c908 vda: Check the correct pointer for buffer allocation
CC: libav-stable@libav.org
Found-By: kropping
2015-07-03 01:58:32 +02:00
Michael Niedermayer
cc48409b51 Merge commit 'e7c5e17d4fbd7c83fb331bf327e25ebd8e6a8623'
* commit 'e7c5e17d4fbd7c83fb331bf327e25ebd8e6a8623':
  vda: Make output CVPixelBuffer format configurable

Conflicts:
	doc/APIchanges
	libavcodec/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-05-13 22:42:49 +02:00
Stefano Pigozzi
e7c5e17d4f vda: Make output CVPixelBuffer format configurable
This is useful for client programs to ask for nv12 surfaces instead of the
current default (uyvy), since those are more efficient to decode to.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-05-13 17:39:37 +02:00
Michael Niedermayer
36f862e04c Merge commit 'a0f2946068c62e18cb05ac25c0df3d86077251a6'
* commit 'a0f2946068c62e18cb05ac25c0df3d86077251a6':
  h264: use properly allocated AVFrames

Conflicts:
	libavcodec/h264.c
	libavcodec/h264.h
	libavcodec/h264_refs.c
	libavcodec/h264_slice.c
	libavcodec/svq3.c
	libavcodec/vda_h264.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-29 16:35:24 +02:00
Anton Khirnov
a0f2946068 h264: use properly allocated AVFrames 2015-04-29 05:52:58 +02:00
Michael Niedermayer
c299fbbb22 avcodec/vda_h264: try to fix build
Found-by: Stefano Pigozzi
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-02 16:04:22 +02:00
Rainer Hochecker
3e53211a57 vda: fix h264 decoding for avcC,vda wants the entire buffer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-04-02 15:06:28 +02:00
Michael Niedermayer
2ab6deb36f Merge commit '2cef68da69a17ed09c313ba3c3850ec1cc0a80e0'
* commit '2cef68da69a17ed09c313ba3c3850ec1cc0a80e0':
  vda: error out if decoded CVPixelBuffer is empty

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-06 22:13:39 +01:00
Stefano Pigozzi
2cef68da69 vda: error out if decoded CVPixelBuffer is empty
On some video samples, VDA silently fails to decode frames and returns
kVDADecoderNoErr. Error out in these cases to avoid producing AVFrames with
empty planes.

Signed-off-by: Stefano Pigozzi <stefano.pigozzi@gmail.com>
2015-01-05 15:35:39 +01:00
Michael Niedermayer
96abdf2ffd avcodec/vda_h264: fix bistream typo
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-12 03:27:04 +02:00
Michael Niedermayer
2856332719 avcodec/vda_h264: fix null pointer dereference
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-12 02:25:58 +02:00
Michael Niedermayer
5449239a03 Merge commit '67afcefb35932b420998f6f3fda46c7c85848a3f'
* commit '67afcefb35932b420998f6f3fda46c7c85848a3f':
  lavc: Add new VDA hwaccel

Conflicts:
	configure
	libavcodec/vda.h
	libavcodec/vda_h264.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-12 01:57:02 +02:00
Michael Niedermayer
c6a683bf22 Merge commit '31a46750c7eafe6bce6a3e4f09853cd0a585292b'
* commit '31a46750c7eafe6bce6a3e4f09853cd0a585292b':
  vda: use hwaccel private data for internal bitstream buffer

Conflicts:
	libavcodec/vda.h
	libavcodec/vda_h264.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-05-12 01:04:27 +02:00
Anton Khirnov
67afcefb35 lavc: Add new VDA hwaccel
It leverages the new hwaccel 1.2 features:

- get_buffer2 is never called
- the internal context is automatically initialized/deinitialized

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-05-11 15:00:03 +02:00
Anton Khirnov
31a46750c7 vda: use hwaccel private data for internal bitstream buffer 2014-05-11 15:00:03 +02:00
Xidorn Quan
31a0ca9e75 vda: fix crash when a frame is dropped.
Signed-off-by: Sebastien Zwickert <dilaroga@gmail.com>
2014-01-27 20:36:42 +01:00
Michael Niedermayer
4fb1221e66 h264: reduce whitespace differences to libav
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-11-03 01:16:31 +01:00
Xidorn Quan
ffd7fd7944 avcodec/vda_h264: use av_buffer to manage buffers
This patch fixes a leak of buffer when seeking occurs.
It adds a flag in struct vda_context for compatibility with apps which
currently use it. If the flag is not set, the hwaccel will behave like
before.

Signed-off-by: Sebastien Zwickert <dilaroga@gmail.com>
2013-05-27 09:05:55 +02:00
Michael Niedermayer
a62fced394 Merge commit '202c2acc40a6de8758b44ab3f5c85ab250079734'
* commit '202c2acc40a6de8758b44ab3f5c85ab250079734':
  vda: remove async decoder leftovers

Conflicts:
	libavcodec/vda_h264.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-03-13 13:53:02 +01:00
Michael Niedermayer
d469fa1923 Merge commit 'adfa53d67c7a3318157ea9d95e8bdcfb77139452'
* commit 'adfa53d67c7a3318157ea9d95e8bdcfb77139452':
  lavc: remove disabled FF_API_VDA_ASYNC cruft

Conflicts:
	libavcodec/vda.h
	libavcodec/vda_h264.c
	libavcodec/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-03-13 01:14:09 +01:00
Luca Barbato
202c2acc40 vda: remove async decoder leftovers
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2013-03-12 01:05:48 +01:00
Anton Khirnov
adfa53d67c lavc: remove disabled FF_API_VDA_ASYNC cruft 2013-03-09 08:37:11 +01:00
Michael Niedermayer
baf10ad186 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  hwaccel: consistent name prefixes for start_frame/end_frame/decode_slice

Conflicts:
	libavcodec/vda_h264.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-03-06 10:34:14 +01:00
Diego Biurrun
c57a593670 hwaccel: consistent name prefixes for start_frame/end_frame/decode_slice
Some hwaccels use name prefixes, some do not, others only use them for
some codecs.  Add prefixes everywhere for consistency.
2013-03-05 11:22:45 +01:00
Michael Niedermayer
b7fe35c9e5 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  h264: deMpegEncContextize

Conflicts:
	libavcodec/dxva2_h264.c
	libavcodec/h264.c
	libavcodec/h264.h
	libavcodec/h264_cabac.c
	libavcodec/h264_cavlc.c
	libavcodec/h264_loopfilter.c
	libavcodec/h264_mb_template.c
	libavcodec/h264_parser.c
	libavcodec/h264_ps.c
	libavcodec/h264_refs.c
	libavcodec/h264_sei.c
	libavcodec/svq3.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-02-16 23:30:09 +01:00
Anton Khirnov
2c54155407 h264: deMpegEncContextize
Most of the changes are just trivial are just trivial replacements of
fields from MpegEncContext with equivalent fields in H264Context.
Everything in h264* other than h264.c are those trivial changes.

The nontrivial parts are:
1) extracting a simplified version of the frame management code from
   mpegvideo.c. We don't need last/next_picture anymore, since h264 uses
   its own more complex system already and those were set only to appease
   the mpegvideo parts.
2) some tables that need to be allocated/freed in appropriate places.
3) hwaccels -- mostly trivial replacements.
   for dxva, the draw_horiz_band() call is moved from
   ff_dxva2_common_end_frame() to per-codec end_frame() callbacks,
   because it's now different for h264 and MpegEncContext-based
   decoders.
4) svq3 -- it does not use h264 complex reference system, so I just
   added some very simplistic frame management instead and dropped the
   use of ff_h264_frame_start(). Because of this I also had to move some
   initialization code to svq3.

Additional fixes for chroma format and bit depth changes by
Janne Grunau <janne-libav@jannau.net>

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2013-02-15 16:35:16 +01:00
Diego Biurrun
511cf612ac miscellaneous typo fixes 2012-12-21 00:18:34 +01:00
Clément Bœsch
8b63744f48 Fix "bistream" typo and add a check in tools/patcheck. 2012-12-18 02:47:34 +01:00
Michael Niedermayer
ac627b3d38 Merge commit '716d413c13981da15323c7a3821860536eefdbbb'
* commit '716d413c13981da15323c7a3821860536eefdbbb':
  Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormat

Conflicts:
	doc/examples/muxing.c
	ffmpeg.h
	ffmpeg_filter.c
	ffmpeg_opt.c
	ffplay.c
	ffprobe.c
	libavcodec/8bps.c
	libavcodec/aasc.c
	libavcodec/aura.c
	libavcodec/avcodec.h
	libavcodec/avs.c
	libavcodec/bfi.c
	libavcodec/bmp.c
	libavcodec/bmpenc.c
	libavcodec/c93.c
	libavcodec/cscd.c
	libavcodec/cyuv.c
	libavcodec/dpx.c
	libavcodec/dpxenc.c
	libavcodec/eatgv.c
	libavcodec/escape124.c
	libavcodec/ffv1.c
	libavcodec/flashsv.c
	libavcodec/fraps.c
	libavcodec/h264.c
	libavcodec/huffyuv.c
	libavcodec/iff.c
	libavcodec/imgconvert.c
	libavcodec/indeo3.c
	libavcodec/kmvc.c
	libavcodec/libopenjpegdec.c
	libavcodec/libopenjpegenc.c
	libavcodec/libx264.c
	libavcodec/ljpegenc.c
	libavcodec/mjpegdec.c
	libavcodec/mjpegenc.c
	libavcodec/motionpixels.c
	libavcodec/mpeg12.c
	libavcodec/mpeg12enc.c
	libavcodec/mpeg4videodec.c
	libavcodec/mpegvideo_enc.c
	libavcodec/pamenc.c
	libavcodec/pcxenc.c
	libavcodec/pgssubdec.c
	libavcodec/pngdec.c
	libavcodec/pngenc.c
	libavcodec/pnm.c
	libavcodec/pnmdec.c
	libavcodec/pnmenc.c
	libavcodec/ptx.c
	libavcodec/qdrw.c
	libavcodec/qpeg.c
	libavcodec/qtrleenc.c
	libavcodec/raw.c
	libavcodec/rawdec.c
	libavcodec/rl2.c
	libavcodec/sgidec.c
	libavcodec/sgienc.c
	libavcodec/snowdec.c
	libavcodec/snowenc.c
	libavcodec/sunrast.c
	libavcodec/targa.c
	libavcodec/targaenc.c
	libavcodec/tiff.c
	libavcodec/tiffenc.c
	libavcodec/tmv.c
	libavcodec/truemotion2.c
	libavcodec/utils.c
	libavcodec/vb.c
	libavcodec/vp3.c
	libavcodec/wnv1.c
	libavcodec/xl.c
	libavcodec/xwddec.c
	libavcodec/xwdenc.c
	libavcodec/yop.c
	libavdevice/v4l2.c
	libavdevice/x11grab.c
	libavfilter/avfilter.c
	libavfilter/avfilter.h
	libavfilter/buffersrc.c
	libavfilter/drawutils.c
	libavfilter/formats.c
	libavfilter/src_movie.c
	libavfilter/vf_ass.c
	libavfilter/vf_drawtext.c
	libavfilter/vf_fade.c
	libavfilter/vf_format.c
	libavfilter/vf_hflip.c
	libavfilter/vf_lut.c
	libavfilter/vf_overlay.c
	libavfilter/vf_pad.c
	libavfilter/vf_scale.c
	libavfilter/vf_transpose.c
	libavfilter/vf_yadif.c
	libavfilter/video.c
	libavfilter/vsrc_testsrc.c
	libavformat/movenc.c
	libavformat/mxf.h
	libavformat/utils.c
	libavformat/yuv4mpeg.c
	libavutil/imgutils.c
	libavutil/pixdesc.c
	libswscale/input.c
	libswscale/output.c
	libswscale/swscale_internal.h
	libswscale/swscale_unscaled.c
	libswscale/utils.c
	libswscale/x86/swscale_template.c
	libswscale/x86/yuv2rgb.c
	libswscale/x86/yuv2rgb_template.c
	libswscale/yuv2rgb.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-10-08 21:06:57 +02:00
Anton Khirnov
716d413c13 Replace PIX_FMT_* -> AV_PIX_FMT_*, PixelFormat -> AVPixelFormat 2012-10-08 07:13:26 +02:00
Carl Eugen Hoyos
6fa2532dd3 vda_h264.c: Change header inclusion order.
Fixes compilation with XCode 3.2.6.
Fixes ticket #1736.
2012-09-16 16:43:27 +02:00
Sebastien Zwickert
02f12de1c2 vda: better frame allocation. 2012-08-14 21:22:20 +02:00
Michael Niedermayer
7427d1ca4a Merge remote-tracking branch 'qatar/master'
* qatar/master:
  g723.1: simplify scale_vector()
  g723.1: simplify normalize_bits()
  vda: cosmetics: fix Doxygen comment formatting
  vda: better frame allocation
  vda: Merge implementation into one file
  vda: support synchronous decoding
  vda: Reuse the bitstream buffer and reallocate it only if needed
  build: Factor out mpegvideo encoding dependencies to CONFIG_MPEGVIDEOENC
  avprobe: Include libm.h for the log2 fallback
  proresenc: use the edge emulation buffer
  rtmp: handle bytes read reports
  configure: Fix typo in mpeg2video/svq1 decoder dependency declaration
  Use log2(x) instead of log(x) / log(2)
  x86: swscale: fix fragile memory accesses
  x86: swscale: remove disabled code
  x86: yadif: fix asm with suncc
  x86: cabac: allow building with suncc
  x86: mlpdsp: avoid taking address of void
  ARM: intmath: use native-size return types for clipping functions

Conflicts:
	configure
	ffprobe.c
	libavcodec/Makefile
	libavcodec/g723_1.c
	libavcodec/v210dec.h
	libavcodec/vda.h
	libavcodec/vda_h264.c
	libavcodec/x86/cabac.h
	libavfilter/x86/yadif_template.c
	libswscale/x86/rgb2rgb_template.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-14 15:34:39 +02:00
Sebastien Zwickert
694be29f13 vda: better frame allocation
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2012-08-14 12:48:46 +02:00
Sebastien Zwickert
dc87ac55ab vda: Merge implementation into one file
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2012-08-14 12:48:08 +02:00
Sebastien Zwickert
3c37970637 vda: support synchronous decoding
Note that the symbols used to run the hardware decoder in asynchronous mode
have been marked deprecated and will be dropped at a future version bump.

Signed-off-by: Diego Biurrun <diego@biurrun.de>
2012-08-14 12:47:27 +02:00
Sebastien Zwickert
cfc680ab39 vda: Reuse the bitstream buffer and reallocate it only if needed
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2012-08-14 12:47:15 +02:00
Sebastien Zwickert
1bfa349a8d vda: merge implementation into one file.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-14 03:39:31 +02:00
Sebastien Zwickert
7f3dfd2010 vda: support synchronous decoding.
Note that the symbols used to run the hardware decoder in asynchronous mode
has been marked as deprecated and will be dropped at a future version dump.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-08-14 03:39:23 +02: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
4dcd1a3145 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  adtsenc: Check frame size.
  txd: Fix order of operations.
  APIchanges: fill in some blanks
  timer: fix misspelling of "decicycles"
  Eliminate pointless 0/NULL initializers in AVCodec and similar declarations.
  indeo3: cosmetics
  md5proto: Fix order of operations.
  dca: Replace oversized unused get_bits() with skip_bits_long().

Conflicts:
	doc/APIchanges
	libavformat/mmsh.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2011-11-29 00:20:29 +01:00
Diego Biurrun
c88ebdb42c Eliminate pointless 0/NULL initializers in AVCodec and similar declarations. 2011-11-28 10:01:50 +01:00
Sebastien Zwickert
81852ef5d6 vda: get correctly the frame from h264 context. 2011-11-14 22:24:03 +01:00
Sebastien Zwickert
b46134f659 vda: reordering headers inclusion. 2011-11-14 22:24:03 +01:00