summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
...
* libavcodec/videotoolbox: fix decoding of h264 streams with minor SPS changesAman Gupta2017-11-20
| | | | | | | | | | | | | | | | | | | | | | | | | | Previously the codec kept an entire copy of the SPS, and restarted the VT decoder session whenever it changed. This fixed decoding errors in [1], as described in 9519983c. On further inspection, that sample features an SPS change from High/4.0 to High/3.2 while moving from one scene to another. Yesterday I received [2], which contains minor SPS changes where the profile and level do not change. These occur frequently and are not associated with scene changes. After 9519983c, the VT decoder session is recreated unnecessarily when these are encountered causing visual glitches. This commit simplifies the state kept in the VTContext to include just the first three bytes of the SPS, containing the profile and level details. This is populated initially when the VT decoder session is created, and used to detect changes and force a restart. This means minor SPS changes are fed directly into the existing decoder, whereas profile/level changes force the decoder session to be recreated with the new parameters. After this commit, both samples [1] and [2] playback as expected. [1] https://s3.amazonaws.com/tmm1/videotoolbox/spschange.ts [2] https://s3.amazonaws.com/tmm1/videotoolbox/spschange2.ts Signed-off-by: Aman Gupta <aman@tmm1.net>
* Revert "tests/fate: addition of test case for hls variant stream creation ↵Steven Liu2017-11-21
| | | | | | with master playlist" This reverts commit 218ce1f6237b39090015809468f8e933bb09d9b8.
* compat/cuda: Pass a logging context to load functionsMark Thompson2017-11-20
| | | | Reviewed-by: Timo Rothenpieler <timo@rothenpieler.org>
* lavf/qsv_vpp: check the return value of ff_formats_ref()Zhong Li2017-11-20
| | | | | | | | | Fixes the build warning of "ignoring return value of ‘ff_formats_ref’, declared with attribute warn_unused_result" Signed-off-by: Zhong Li <zhong.li@intel.com> Reviewed-by: Carl Eugen Hoyos <ceffmpeg@gmail.com> Signed-off-by: Mark Thompson <sw@jkqxz.net>
* lavf/qsv_overlay: check the return value of ff_formats_ref()Zhong Li2017-11-20
| | | | | | | | | Fixes the build warning of "ignoring return value of ‘ff_formats_ref’, declared with attribute warn_unused_result" Signed-off-by: Zhong Li <zhong.li@intel.com> Reviewed-by: Carl Eugen Hoyos <ceffmpeg@gmail.com> Signed-off-by: Mark Thompson <sw@jkqxz.net>
* lavu/qsv: remove unused variableZhong Li2017-11-20
| | | | | | | Fixes build warning of "variable 's' is declared but not used" Signed-off-by: Zhong Li <zhong.li@intel.com> Signed-off-by: Mark Thompson <sw@jkqxz.net>
* hwcontext_vaapi: add the fourcc of I420 format map.Jun Zhao2017-11-20
| | | | | | | VA-API 2.0 have enable the I420, so enable this map. Signed-off-by: Jun Zhao <jun.zhao@intel.com> Signed-off-by: Mark Thompson <sw@jkqxz.net>
* avcodec: Implement mpeg4 nvdec hwaccelPhilip Langdale2017-11-20
| | | | | | | | | | | | | | | | | | | | This was predictably nightmarish, given how ridiculous mpeg4 is. I had to stare at the cuvid parser output for a long time to work out what each field was supposed to be, and even then, I still don't fully understand some of them. Particularly: vop_coded: If I'm reading the decoder correctly, this flag will always be 1 as the decoder will not pass the hwaccel any frame where it is not 1. divx_flags: There's obviously no documentation on what the possible flags are. I simply observed that this is '0' for a normal bitstream and '5' for packed b-frames. gmc_enabled: I had a number of guesses as to what this mapped to. I picked the condition I did based on when the cuvid parser was setting flag. Also note that as with the vdpau hwaccel, the decoder needs to consume the entire frame and not the slice.
* avcodec: Implement mpeg1 nvdec hwaccelPhilip Langdale2017-11-20
| | | | | Once I remembered that there's a separate decoder type for mpeg1, even though params struct is shared with mpeg2, everything worked.
* avcodec: Refactor common nvdec hwaccel logicPhilip Langdale2017-11-20
| | | | | | | | | The 'simple' hwaccels (not h.264 and hevc) all use the same bitstream management and reference lookup logic so let's refactor all that into common functions. I verified that casting a signed int -1 to unsigned char produces 255 according to the C language specification.
* avfilter/avfiltergraph: pass correct audio/video flagsPaul B Mahol2017-11-20
| | | | | | Previously video flags where set for audio option. Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter/af_afftfilt: add missing error checkPaul B Mahol2017-11-20
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter/af_headphone: add missing error checkPaul B Mahol2017-11-20
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter/af_afir: add missing error checkPaul B Mahol2017-11-20
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter/af_surround: add missing error checkPaul B Mahol2017-11-20
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* lavf/mov: Do not mix variable declaration and code.Carl Eugen Hoyos2017-11-20
| | | | | Fixes a warning: libavformat/mov.c:1195:5: warning: ISO C90 forbids mixed declarations and code
* avfilter/af_extrastereo: fix filtering when clipping is disabledPaul B Mahol2017-11-20
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avformat/hlsenc: use FFABS to instead of absSteven Liu2017-11-20
| | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/swfenc: use FFABS to instead of absSteven Liu2017-11-20
| | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/mxf: use FFABS to instead of absSteven Liu2017-11-20
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/mp3dec: use FFABS to instead of absSteven Liu2017-11-20
| | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* tests/fate: addition of test case for hls variant stream creation with ↵Vishwanath Dixit2017-11-20
| | | | | | master playlist Reviewed-by: Steven Liu <lingjiujianke@gmail.com>
* avformat/hlsenc: creation of hls master playlist fileVishwanath Dixit2017-11-20
| | | | Reviewed-by: Steven Liu <lingjiujianke@gmail.com>
* avformat/hlsenc: creation of hls variant streams in a single hlsenc instanceVishwanath Dixit2017-11-20
| | | | Reviewed-by: Steven Liu <lingjiujianke@gmail.com>
* avformat/movenc: write clap atom for uncompressed yuv in movDave Rice2017-11-20
| | | | | | fixes 6145 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/movenc: correct ImageDescription for uncompressed ycbcrDave Rice2017-11-20
| | | | | | | Per https://developer.apple.com/library/content/technotes/tn2162/_index.html Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* ffmpeg: add ui64 type to SpecifierOptpkviet2017-11-20
| | | | | | | | | Adds ui64 (uint64_t) as a possible type for SpecifierOpt. This enables use of uint64_t options with SpecifierOpt such as channel_layout when expressed as a 64 bit channel mask. Signed-off-by: pkviet <pkv.stream@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avcodec: remove unnecessary AVPacketSideDataType enum offsetJames Almer2017-11-19
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* doc/codecs.texi: Remove documentation of removed codec flags.Carl Eugen Hoyos2017-11-20
| | | | The flags were removed in b79a7da3
* Merge commit '3152058bf1dca318898550efacf0286f4836cae6'James Almer2017-11-19
|\ | | | | | | | | | | | | * commit '3152058bf1dca318898550efacf0286f4836cae6': libavcodec: Don't use dllexport, only dllimport when building DLLs Merged-by: James Almer <jamrial@gmail.com>
| * libavcodec: Don't use dllexport, only dllimport when building DLLsMartin Storsjö2017-11-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The only purpose of dllexport (which is set while building the library that exports the symbols) is to have the linker automatically export such symbols into a DLL without using a def file - it doesn't affect the generated code. For both MSVC and mingw builds, this isn't essential since we override what symbols to export via an autogenerated def file instead. Update a comment in configure to refer to the right concept. With lld, this avoids warnings about duplicate export directives, when some symbols are requested to be exported both via dllexport attributes and via the autogenerated def file. This also reduces the number of lines of code marginally. Signed-off-by: Martin Storsjö <martin@martin.st>
* | configure: fix module dependencies on zlibJames Almer2017-11-19
| | | | | | | | | | | | | | | | select should not be used with external libraries. It's mean to soft enable internal modules/features. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: James Almer <jamrial@gmail.com>
* | avfilter/af_surround: add some more layoutsPaul B Mahol2017-11-19
| | | | | | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* | avfilter: fix indentationPaul B Mahol2017-11-19
| | | | | | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* | avformat/subfile: allow to extract till EOFGyan Doshi2017-11-19
| | | | | | | | | | Users can set end offset as 0 to extract till end of file. Tested locally and documented.
* | lavfi/af_pan: fix sign handling in channel coefficient parserMichael Roitzsch2017-11-19
| | | | | | | | | | When a channel formula ends with a subtraction, the next formula will otherwise have its first coefficient negated.
* | configure: add audio_frame_queue dependency for aptx codecJames Darnley2017-11-19
| |
* | avfilter: add acontrast filterPaul B Mahol2017-11-19
| | | | | | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* | avformat/dashenc: fix min_seg_duration option sizeJames Cowgill2017-11-19
| | | | | | | | | | | | | | | | | | | | In the DASHContext structure, min_seg_duration is declared as an int, but the AVOption list claimed it was an INT64. Change the option list to use the correct size, which should fix some initialization errors seen on big-endian platforms. Signed-off-by: James Cowgill <jcowgill@debian.org> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | ffmpeg: Allow "-to" on input files in addition to "-t"Vitaly _Vi Shukela2017-11-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | For some strange reason "-t" option was only implemented for input files while both "-t" and "-to" were available for use for output files. This made extracting a range from input file inconvenient. This patch enables -to option for input so one can do ffmpeg -ss 1:23:20 -to 1:27:22.3 -i myinput.mkv ... Signed-off-by: Vitaly _Vi Shukela <vi0oss@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | ffmpeg_filter: use nb_threads=1 on unused filtergraphDHE2017-11-19
| | | | | | | | | | Signed-off-by: DHE <git@dehacked.net> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat: remove unnecessary AVStreamParseType enum offsetJames Almer2017-11-18
| | | | | | | | Signed-off-by: James Almer <jamrial@gmail.com>
* | lavf/tcp: Fix the type of the optlen argument to getsockopt().Carl Eugen Hoyos2017-11-18
| | | | | | | | | | Fixes a warning on aix: libavformat/tcp.c:283:58: warning: passing argument 5 of 'getsockopt' from incompatible pointer type
* | avcodec: Implement mpeg2 nvdec hwaccelPhilip Langdale2017-11-18
| | | | | | | | | | | | This is mostly straight-forward. The weird part is that it should just work for mpeg1, but I see corruption in my test cases, so I'm going to try and fix that separately.
* | avcodec: Fix reference data type for nvdec vc1 hwaccelPhilip Langdale2017-11-18
| | | | | | | | | | | | | | | | | | | | | | I took the reference lookup code from the vp9 hwaccel where the type is unsigned char, but for vc1, the type is signed int. This is particularly important because the value used when there's no reference is different (255 vs -1). It didn't seem to break anything, but for mpeg1/2/4, this mistake caused decode errors.
* | Ignore libavcodec/tests/mpeg12framerate, a test programJim DeLaHunt2017-11-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add to libavcodec/tests/.gitignore an entry for test program libavcodec/tests/mpeg12framerate . Other similar test programs, e.g. jpeg2000dwt and dct, are ignored in a similar way. On initially checking out master, and doing "./configure" and "make clean", "git status" reports no untracked files. After running "make fate", "git status" reports untracked file "libavcodec/tests/mpeg12framerate". mpeg12framerate is a unit test program. It was apparently introduced in commit 278c308ceae6b8d7bac1dfc24518821aae603988, on Tue Sep 12 22:11:56 2017 +0100. It added a new function ff_mpeg12_find_best_frame_rate() to libavcodec/mpeg12framerate.c , and the code in libavcodec/tests/mpeg12framerate.c to exercise that function. This commit also added the new program to the FATE suite, but it omitted a .gitignore entry. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | lavf/mov: don't read outside frag_index boundsJohn Stebbins2017-11-18
| | | | | | | | | | | | | | | | | | | | | | Potentially fixes: https://bugs.chromium.org/p/chromium/issues/detail?id=786269#c1 In theory, the crash can be triggered by an invalid stream that has either tfdt or trun outside of the moof Reviewed-by: Dale Curtis <dalecurtis@chromium.org> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Use ff_thread_once for fixed, float table init.Dale Curtis2017-11-18
| | | | | | | | | | | | | | | | These tables are static so they should only be initialized once instead of on every call to ff_mpadsp_init(). Signed-off-by: Dale Curtis <dalecurtis@chromium.org> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Fix leak of frame_duration_buffer in mov_fix_index().Dale Curtis2017-11-18
| | | | | | | | | | | | | | | | | | Should be unconditionally freed at the end of mov_fix_index() in case it hasn't been used during the fix up. Signed-off-by: Dale Curtis <dalecurtis@chromium.org> Reviewed-by: Sasi Inguva <isasi-at-google.com@ffmpeg.org> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avcodec/mlpdsp: Fix undefined shift ff_mlp_pack_output()Michael Niedermayer2017-11-18
| | | | | | | | | | | | | | | | Fixes: runtime error: left shift of negative value -7862264 Fixes: 4074/clusterfuzz-testcase-minimized-4516104123711488 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>