summaryrefslogtreecommitdiff
path: root/libavutil
Commit message (Collapse)AuthorAge
* x86/aacpsdsp: add ff_ps_hybrid_synthesis_deint_{sse,sse4}James Almer2017-06-18
| | | | About 2x faster than the c version.
* avutil/tests: remove float_dsp testJames Almer2017-06-14
| | | | | | It's been ported to checkasm. Signed-off-by: James Almer <jamrial@gmail.com>
* hwcontext: Improve allocation in derived contextsMark Thompson2017-06-14
| | | | | | | | | Use the flags argument of av_hwframe_ctx_create_derived() to pass the mapping flags which will be used on allocation. Also, set the format and hardware context on the allocated frame automatically - the user should not be required to do this themselves. (cherry picked from commit c5714b51aad41fef56dddac1d542e7fc6b984627)
* hwcontext_qsv: Implement mapping frames to the child device typeMark Thompson2017-06-14
| | | | (cherry picked from commit e1c5d56b18b82e3fb42382b1b1f972e8b371fc38)
* hwcontext_qsv: Implement mapping frames from the child device typeMark Thompson2017-06-14
| | | | | | Factorises out existing surface initialisation code to reuse. (cherry picked from commit eaa5e0710496db50fc164806e5f49eaaccc83bb5)
* hwcontext: Add frame context mapping for nontrivial contextsMark Thompson2017-06-14
| | | | | | | | | Some frames contexts are not usable without additional format-specific state in hwctx. This change adds new functions frames_derive_from and frames_derive_to to initialise this state appropriately when deriving a frames context which will require it to be set. (cherry picked from commit 27978155bc661eec9f22bcf82c9cfc099cff4365)
* hwcontext_qsv: Support derivation from child devicesMark Thompson2017-06-14
| | | | (cherry picked from commit aa51bb3d2756ed912ee40645efccf5f4a9609696)
* hwcontext: Make it easier to work with device typesMark Thompson2017-06-14
| | | | | | | | Adds functions to convert to/from strings and a function to iterate over all supported device types. Also adds a new invalid type AV_HWDEVICE_TYPE_NONE, which acts as a sentinel value. (cherry picked from commit b7487f4f3c39b4b202e1ea7bb2de13902f2dee45)
* hwcontext: Add device derivationMark Thompson2017-06-14
| | | | | | | Creates a new device context from another of a different type which refers to the same underlying hardware. (cherry picked from commit b266ad56fe0e4ce5bb70118ba2e2b1dabfaf76ce)
* hwcontext_vaapi: Try to support the VDPAU wrapperMark Thompson2017-06-14
| | | | | | | | | | The driver is somewhat bitrotten (not updated for years) but is still usable for decoding with this change. To support it, this adds a new driver quirk to indicate no support at all for surface attributes. Based on a patch by wm4 <nfxjfg@googlemail.com>. (cherry picked from commit e791b915c774408fbc0ec9e7270b021899e08ccc)
* x86inc: Add some additional cpuflag relationsHenrik Gramner2017-06-12
| | | | | | | | Simplifies writing assembly code that depends on available instructions. LZCNT implies SSE2 BMI1 implies AVX+LZCNT AVX2 implies BMI2
* x86inc: Remove argument from WIN64_RESTORE_XMMAnton Mitrofanov2017-06-09
| | | | | The use of rsp was pretty much hardcoded there and probably didn't work otherwise with stack_size > 0.
* x86inc: Prefer r14/r15 over r12/r13 on x86-64Henrik Gramner2017-06-09
| | | | | | | Due to a peculiarity in the ModR/M addressing encoding, the r12 and r13 registers sometimes requires an additional byte when used as a base register. r14 and r15 doesn't have that issue, so prefer using them.
* x86inc: Make REP_RET identical to RET in SSSE3+ functionsHenrik Gramner2017-06-09
| | | | There's no point in emitting a rep prefix before ret on modern CPUs.
* x86inc: Fix call with memory operandsHenrik Gramner2017-06-09
| | | | | | We overload the `call` instruction with a macro, but it would misbehave when the macro argument wasn't a valid identifier. Fix it by explicitly checking if the argument is an identifier.
* libavutil/eval: Add round function to expression parserKevin Mark2017-06-06
| | | | | | | We have floor, ceil, and trunc. Let's add round. Signed-off-by: Kevin Mark <kmark937@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avutil/softfloat: Fix sign error in and improve documentation of av_int2sf()Michael Niedermayer2017-06-04
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avutil/pixfmt: remove superfluous defineJames Almer2017-06-01
| | | | | | It's an AVColorSpace value since 82ad9cbd32c873bced9adf4a2bb67dcda7294c61. Signed-off-by: James Almer <jamrial@gmail.com>
* Merge commit 'b83aea73404f6f9314e72fe5d6238deaffa12b2c'Clément Bœsch2017-05-19
|\ | | | | | | | | | | | | | | | | * commit 'b83aea73404f6f9314e72fe5d6238deaffa12b2c': des-test: Pass the proper types to av_des_*() functions See 183c3fa48acaf4561d5269ab9a766d13ae70140c Merged-by: Clément Bœsch <u@pkh.me>
| * des-test: Pass the proper types to av_des_*() functionsDiego Biurrun2017-01-24
| | | | | | | | Fixes a number of incompatible pointer type warnings.
* | avutil/hwcontext_dxva2: Don't improperly free IDirect3DSurface9 objectsAaron Levinson2017-05-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add dxva2_pool_release_dummy() and use it in call to av_buffer_create() in dxva2_pool_alloc(). Prior to this change, av_buffer_create() was called with NULL for the third argument, which indicates that av_buffer_default_free() should be used to free the buffer's data. Eventually, it gets to buffer_pool_free() and calls buf->free() on a surface object (which is av_buffer_default_free()). This can result in a crash when the debug version of the C-runtime is used on Windows. While it doesn't appear to result in a crash when the release version of the C-runtime is used on Windows, it likely results in memory corruption, since av_free() is being called on memory that was allocated using IDirectXVideoAccelerationService::CreateSurface(). Signed-off-by: Aaron Levinson <alevinsn@aracnet.com> Reviewed-by: wm4 <nfxjfg@googlemail.com> Reviewed-by: Steven Liu <lingjiujianke@gmail.com> Reviewed-by: Mark Thompson <sw@jkqxz.net>
* | hwcontext_videotoolbox: fix fate-sourcewm42017-05-15
| | | | | | | | Thanks to James Darnley for figuring out what the hell it wanted.
* | videotoolbox: add hwcontext supportwm42017-05-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds tons of code for no other benefit than making VideoToolbox support conform with the new hwaccel API (using hw_device_ctx and hw_frames_ctx). Since VideoToolbox decoding does not actually require the user to allocate frames, the new code does mostly nothing. One benefit is that ffmpeg_videotoolbox.c can be dropped once generic hwaccel support for ffmpeg.c is merged from Libav. Does not consider VDA or VideoToolbox encoding. Fun fact: the frame transfer functions are copied from vaapi, as the mapping makes copying generic boilerplate. Mapping itself is not exported by the VT code, because I don't know how to test.
* | x86/float_dsp: remove usage of integer instructionsJames Almer2017-05-12
| |
* | Merge commit '52627248e49e58eb4b78e4fcda90a64f4c476ea3'James Almer2017-05-08
|\| | | | | | | | | | | | | * commit '52627248e49e58eb4b78e4fcda90a64f4c476ea3': frame: add a cropping rectangle to AVFrame Merged-by: James Almer <jamrial@gmail.com>
| * frame: add a cropping rectangle to AVFrameAnton Khirnov2017-01-12
| | | | | | | | | | Extend the width/height doxy to clarify that it should store coded values.
* | avutil/softfloat: Fix overflow in av_div_sf()Michael Niedermayer2017-05-06
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avutil/softfloat: Fix multiple runtime error: left shift of negative value -8Michael Niedermayer2017-05-06
| | | | | | | | | | | | | | Fixes: 1352/clusterfuzz-testcase-minimized-5757565017260032 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Merge commit '00b6a765430e5c5cacf0bd1be8b318d631cd4e14'Clément Bœsch2017-05-05
|\| | | | | | | | | | | | | * commit '00b6a765430e5c5cacf0bd1be8b318d631cd4e14': hmac: Explicitly convert types at function pointer assignment Merged-by: Clément Bœsch <cboesch@gopro.com>
| * hmac: Explicitly convert types at function pointer assignmentDiego Biurrun2017-01-09
| | | | | | | | | | Fixes a number of warnings of the type libavutil/hmac.c:61:21: warning: assignment from incompatible pointer type
* | lavu/sha512: update length argument following sha+md5 changesClément Bœsch2017-05-05
| |
* | Merge commit 'e435beb1ea5380a90774dbf51fdc8c941e486551'Clément Bœsch2017-05-05
|\| | | | | | | | | | | | | * commit 'e435beb1ea5380a90774dbf51fdc8c941e486551': crypto: consistently use size_t as type for length parameters Merged-by: Clément Bœsch <cboesch@gopro.com>
| * crypto: consistently use size_t as type for length parametersDiego Biurrun2017-01-09
| | | | | | | | size_t is the correct type to use for sizes.
| * x86inc: Avoid using eax/rax for storing the stack pointerHenrik Gramner2017-01-09
| | | | | | | | | | | | | | | | | | | | | | When allocating stack space with an alignment requirement that is larger than the current stack alignment we need to store a copy of the original stack pointer in order to be able to restore it later. If we chose to use another register for this purpose we should not pick eax/rax since it can be overwritten as a return value. Signed-off-by: Anton Khirnov <anton@khirnov.net>
* | lavu/timecode: Increase AV_TIMECODE_STR_SIZE.Carl Eugen Hoyos2017-05-05
| | | | | | | | | | Fixes the following warning: libavutil/timecode.c:103:60: warning: '%02d' directive output may be truncated writing between 2 and 10 bytes into a region of size between 0 and 7
* | Merge commit '92db5083077a8b0f8e1050507671b456fd155125'James Almer2017-05-04
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '92db5083077a8b0f8e1050507671b456fd155125': build: Generate pkg-config files from Make and not from configure build: Store library version numbers in .version files Includes cherry-picked commits 8a34f3659371680ca523aecfd9098c28f0f809eb and ee164727dd64c199b87118917e674b17c25e0da3 to fix issues. Changes were also made to retain support for raise_major and build_suffix. Reviewed-by: ubitux Merged-by: James Almer <jamrial@gmail.com>
| * build: Generate pkg-config files from Make and not from configureDiego Biurrun2016-12-22
| | | | | | | | | | | | | | | | This moves work from the configure to the Make stage where it can be parallelized and ensures that pkgconfig files are updated when library versions change. Bug-Id: 449
* | Merge commit '11a9320de54759340531177c9f2b1e31e6112cc2'Clément Bœsch2017-05-03
|\| | | | | | | | | | | | | | | | | * commit '11a9320de54759340531177c9f2b1e31e6112cc2': build: Move build-system-related helper files to a separate subdirectory "ffbuild" directory name is used instead of "avbuild". Merged-by: Clément Bœsch <u@pkh.me>
* | avutil/softfloat: use ldexp(), fixes undefined shiftMichael Niedermayer2017-05-02
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Merge commit '05a603a94e4b3eeefa5e18ae653a848001461e89'Clément Bœsch2017-04-26
|\| | | | | | | | | | | | | * commit '05a603a94e4b3eeefa5e18ae653a848001461e89': ppc: Merge types_altivec.h into util_altivec.h Merged-by: Clément Bœsch <u@pkh.me>
| * ppc: Merge types_altivec.h into util_altivec.hDiego Biurrun2016-12-14
| | | | | | | | There is no point in keeping the two separate.
* | libavutil/thread.h: Fixed g++ build error when ASSERT_LEVEL is greater than 1Aaron Levinson2017-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Purpose: libavutil/thread.h: Fixed g++ build error when ASSERT_LEVEL is greater than 1. This is only relevant when thread.h is included by C++ files. In this case, the relevant code is only defined if HAVE_PTHREADS is defined as 1. Use configure --assert-level=2 to do so. Note: Issue discovered as a result of Coverity build failure. Cause of build failure pinpointed by Hendrik Leppkes. Comments: -- libavutil/thread.h: Altered ASSERT_PTHREAD_NORET definition such that it uses av_make_error_string instead of av_err2str(). av_err2str() uses a "parenthesized type followed by an initializer list", which is apparently not valid C++. This issue started occurring because thread.h is now included by the DeckLink C++ files. The alteration does the equivalent of what av_err2str() does, but instead declares the character buffer as a local variable. Signed-off-by: Marton Balint <cus@passwd.hu>
* | Merge commit '2170017a1cd033b6f28e16476921022712a522d8'James Almer2017-04-13
|\| | | | | | | | | | | | | | | | | * commit '2170017a1cd033b6f28e16476921022712a522d8': avutil: fix data race in av_get_cpu_flags() This commit is a noop, see fed50c4304eecb352e29ce789cdb96ea84d6162f Merged-by: James Almer <jamrial@gmail.com>
| * avutil: fix data race in av_get_cpu_flags()Wan-Teh Chang2016-12-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make the one-time initialization in av_get_cpu_flags() thread-safe. The static variables |flags|, |cpuflags_mask|, and |checked| in libavutil/cpu.c are read and written using normal load and store operations. These are considered as data races. The fix is to use atomic load and store operations. Remove the |checked| variable because the invalid value of -1 for |flags| can be used to indicate the same condition. Rename |flags| to |cpu_flags| and move it to file scope. The fix can be verified by running the libavutil/tests/cpu_init.c test program under ThreadSanitizer: ./configure --toolchain=clang-tsan make libavutil/tests/cpu_init libavutil/tests/cpu_init There should be no warnings from ThreadSanitizer. Co-author: Dmitry Vyukov of Google, who suggested the data race fix. Signed-off-by: Wan-Teh Chang <wtc@google.com>
| * Add missing #includes for standalone spherical-information-related headersDiego Biurrun2016-12-08
| |
| * lavc: Add spherical packet side data APIVittorio Giovara2016-12-07
| | | | | | | | Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
| * lavu: Add AVSphericalMapping type and frame side dataVittorio Giovara2016-12-07
| | | | | | | | | | | | | | | | While no decoder currently exports spherical information, this type represents a frame property that has to be passed through from container to frames. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* | Merge commit '075acbb6ff5740b2eea1bb7dd3afbc8e66e2ebf8'James Almer2017-04-13
|\| | | | | | | | | | | | | * commit '075acbb6ff5740b2eea1bb7dd3afbc8e66e2ebf8': lavu: Add a video section to Doxygen documentation Merged-by: James Almer <jamrial@gmail.com>
| * lavu: Add a video section to Doxygen documentationVittorio Giovara2016-12-07
| | | | | | | | | | | | | | Fill it with AVStereo3D and AVDisplayMatrix documentation. Apply the necessary changes to make verbatim code look good in doxygen. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* | x86/float_dsp: add ff_vector_fmul_reverse_avx2James Almer2017-04-11
| | | | | | | | | | | | ~20% faster than AVX. Signed-off-by: James Almer <jamrial@gmail.com>