1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-09-09 17:20:21 +02:00
Commit Graph

132 Commits

Author SHA1 Message Date
James Almer
c14f8125a8 Merge commit '1a7bf48eed806beea7e835b31b06aa6bc94da5da'
* commit '1a7bf48eed806beea7e835b31b06aa6bc94da5da':
  makedef: Extend the script for use with mingw tools as well

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 11:31:22 -03:00
James Almer
24f1685f6e Merge commit '44aa9105c535471ca9e23796d7ca29b341f47636'
* commit '44aa9105c535471ca9e23796d7ca29b341f47636':
  makedef: Fold as much text transformations as possible into the initial dump

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 11:30:32 -03:00
James Almer
ce52e430b2 compat/w32dlfcn: add missing config.h include
Fixes warnings about undefined HAVE_WINRT

Signed-off-by: James Almer <jamrial@gmail.com>
2017-11-07 16:50:26 -03:00
Martin Storsjö
1a7bf48eed makedef: Extend the script for use with mingw tools as well
This is invoked by setting the NM and AR variables to the names of
those specific tools. The ARCH variable also needs to be provided,
to choose the symbol prefix (nm doesn't provide any option that
dumps the architecture easily).

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-08-31 14:22:18 +03:00
Martin Storsjö
44aa9105c5 makedef: Fold as much text transformations as possible into the initial dump
This avoids redoing them for each expression in the list.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-08-31 14:22:15 +03:00
Ricardo Constantino
7fbc082577 compat/cuda/ptx2c: strip CR from each line
Windows nvcc + cl.exe produce a .ctx file with CR+LF newlines which
need to be stripped to work with gcc.

Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2017-08-30 11:20:34 +02:00
Matt Oliver
a3833bee94 win32_dlfcn: Support WinRT/UWP.
This only enables dlls that are packaged with the application to be
loaded. Due to the limitations of WinRT/UWP it is not allowed to load
external/system dlls so this cannot be used as a complete replacement
for normal win32 dll loading.

Signed-off-by: Matt Oliver <protogonoi@gmail.com>
2017-07-30 14:30:43 +10:00
Timo Rothenpieler
f890a6d712 compat/cuda: make cuvidGetDecoderCaps optional 2017-06-01 12:39:06 +02:00
Timo Rothenpieler
88896c4619 compat/cuda/ptx2c: remove bashism and harden against arbitrary input 2017-05-15 18:54:38 +02:00
Timo Rothenpieler
f1ab71b046 build: add support for building .cu files via nvcc
Original work by Yogender Gupta <ygupta@nvidia.com>
2017-05-15 11:46:50 +02:00
Timo Rothenpieler
f15129a44b compat/cuda: fix cast warnings on windows 2017-05-09 18:38:30 +02:00
Timo Rothenpieler
17f63d98e6 compat/cuda: update cuvid/nvdec headers to Video Codec SDK 8.0.14
This raises the required minimum NVIDIA display driver versions:
NVIDIA Linux display driver 378.13 or newer
NVIDIA Windows display driver 378.66 or newer
2017-05-09 18:38:30 +02:00
Timo Rothenpieler
78518b72cf compat/nvenc: bump nvEncodeAPI.h to Video Codec SDK 8.0.14
This raises the required minimum NVIDIA display driver versions:
NVIDIA Linux display driver 378.13 or newer
NVIDIA Windows display driver 378.66 or newer
2017-05-09 18:38:30 +02:00
Carl Eugen Hoyos
3624d45ddb compat/strtod: Add missing const qualifiers.
Fixes many warnings:
initialization discards 'const' qualifier from pointer target type
2017-05-04 23:17:20 +02:00
Aaron Levinson
bceb3d0f86 Support building C++ files with MSVC
Made appropriate changes to be able to successfully
build C++ files using a Visual C++ build on Windows.

Based on an earlier patch by Kyle Schwarz.

Comments:

-- compat/w32pthreads.h: Made appropriate changes to w32pthreads.h to
   get it to build when it is being included in a C++ file and built
   with Visual C++.  This is mostly a copy of Kyle Schwarz's patch as
   described above.

-- configure:
a) Now calling set_ccvars CXX to cause the various CXX_ variables to
   be setup properly.  For example, with MSVC (Microsoft Visual C++),
   this causes CXX_O to be set to -Fo$@ instead of using the default
   value.  The default value does not work with Visual C++.  This
   change will also have the impact of correcting CXX_O (and possibly
   CXX_C) for other compilers, although this is really only relevant
   for the Intel compiler, in addition to MSVC.
b) Now using cl for the C++ compiler for the MSVC toolchain.  This is
   currently only relevant for building the
   Blackmagic/Decklink-related files under avdevice.

Signed-off-by: Hendrik Leppkes <h.leppkes@gmail.com>
2017-04-13 23:57:31 +02:00
James Almer
eab5d29810 Merge commit '6a93b596c5c3af31b843d63013a7985ffeea354d'
* commit '6a93b596c5c3af31b843d63013a7985ffeea354d':
  compat/atomics: add typecasts in atomic_compare_exchange_strong()

Merged-by: James Almer <jamrial@gmail.com>
2017-04-13 18:27:20 -03:00
Clément Bœsch
210678d3c5 Merge commit '3794062ab1a13442b06f6d76c54dce51ffa54697'
* commit '3794062ab1a13442b06f6d76c54dce51ffa54697':
  Remove Plan 9 support

Merged-by: Clément Bœsch <u@pkh.me>
2017-04-09 14:52:00 +02:00
James Almer
b30cd14b57 Merge commit 'bd9cd04626a98a752c5771d057a6b86779359904'
* commit 'bd9cd04626a98a752c5771d057a6b86779359904':
  w32pthreads: Fix function pointer casts

Merged-by: James Almer <jamrial@gmail.com>
2017-04-04 15:59:56 -03:00
Hendrik Leppkes
9ac1e88436 stdatomic/win32: only include the lean windows headers to avoid conflicts 2017-04-04 09:33:23 +02:00
James Almer
7942907878 compat/atomics: fix atomic_fetch_xor 2017-04-02 00:57:17 -03:00
James Almer
824d4062a1 compat/atomics/gcc: use __typeof__ instead of typeof
The typeof keyword is apparently not available when using the -std=c99 option.

Fixes the use of C11 atomic functions with old GCC.

Reviewed-by: Muhammad Faiz <mfcc64@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2017-03-18 12:13:46 -03:00
Timo Rothenpieler
b27be563a8 compat/cuda: fix ulong size on cygwin 2017-03-01 12:08:34 +01:00
Wan-Teh Chang
6a93b596c5 compat/atomics: add typecasts in atomic_compare_exchange_strong()
The Solaris and Windows emulations of atomic_compare_exchange_strong()
need typecasts to avoid compiler warnings, because the functions they
call expect a void* pointer but an intptr_t integer is passed.

Note that the emulations of atomic_compare_exchange_strong() (except
the gcc version) only work for atomic_intptr_t because of the type of
the second argument (|expected|). See
http://en.cppreference.com/w/c/atomic:

_Bool atomic_compare_exchange_strong( volatile A* obj,
                                      C* expected, C desired );

The types of the first argument and second argument are different
(|A| and |C|, respectively). |C| is the non-atomic type corresponding
to |A|. In the emulations of atomic_compare_exchange_strong(), |C| is
intptr_t. This implies |A| can only be sig_intptr_t.

Signed-off-by: Wan-Teh Chang <wtc@google.com>
2016-12-08 15:53:58 -05:00
Diego Biurrun
3794062ab1 Remove Plan 9 support
Supporting the system was a nice joke for the 9 release, but it has
run its course. Nowadays Plan 9 receives no testing and has no
practical usefulness.
2016-12-03 09:15:01 +01:00
James Almer
f88c8e0dc3 compat/atomics: rename header guards
Fixes fate-source.

Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 20:08:54 -03:00
Anton Khirnov
41e891e89e Add a compat dummy stdatomic.h used when threading is disabled
Adapted from the code by Rémi Denis-Courmont from VLC

This merges libav commit eb34d40354.

Signed-off-by: Wan-Teh Chang <wtc@google.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 16:25:18 -03:00
Anton Khirnov
74b5f10862 Add a compat stdatomic.h implementation based on pthreads
Adapted from the code by Rémi Denis-Courmont from VLC

This merges libav commit f9a6a80e06.

Signed-off-by: Wan-Teh Chang <wtc@google.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 16:25:18 -03:00
Anton Khirnov
70faadc826 Add a compat stdatomic.h implementation based on suncc atomics
Adapted from the code by Rémi Denis-Courmont from VLC

This merges libav commit bb81ed4765.

Signed-off-by: Wan-Teh Chang <wtc@google.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 16:25:18 -03:00
Anton Khirnov
c91e72ed52 Add a compat stdatomic.h implementation based on windows atomics
Adapted from the code by Rémi Denis-Courmont from VLC

This merges libav commit c2755864af.

Signed-off-by: Wan-Teh Chang <wtc@google.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 16:25:17 -03:00
Anton Khirnov
3359eede8f Add a compat stdatomic.h implementation based on GCC atomics
Adapted from the code by Rémi Denis-Courmont from VLC

This merges libav commit 4e928ef340.

Signed-off-by: Wan-Teh Chang <wtc@google.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 16:25:17 -03:00
Diego Biurrun
bd9cd04626 w32pthreads: Fix function pointer casts
This eliminates a handful of warnings at every inclusion of the header.
2016-11-24 16:14:33 +01:00
Philip Langdale
81147b5596 avcodec/cuvid: Add support for P010/P016 as an output surface format
The nvidia 375.xx driver introduces support for P016 output surfaces,
for 10bit and 12bit HEVC content (it's also the first driver to support
hardware decoding of 12bit content).

The cuvid api, as far as I can tell, only declares one output format
that they appear to refer to as P016 in the driver strings. Of course,
10bit content in P016 is identical to P010, and it is useful for
compatibility purposes to declare the format to be P010 to work with
other components that only know how to consume P010 (and to avoid
triggering swscale conversions that are lossy when they shouldn't be).

For simplicity, this change does not maintain the previous ability
to output dithered NV12 for 10/12 bit input video - the user will need
to update their driver to decode such videos.
2016-11-22 10:09:30 -08:00
Timo Rothenpieler
d9ad18f3b4 avcodec/cuvid: use dynamically loaded CUDA/CUVID
And remove the now obsolete compat headers.
2016-11-22 10:34:27 +01:00
Timo Rothenpieler
5c02d2827b compat/cuda: add dynamic loader 2016-11-22 10:34:27 +01:00
Matt Oliver
85553b42f9 compat/w32dlfcn.h: Add safe win32 dlopen/dlclose/dlsym functions.
Signed-off-by: Matt Oliver <protogonoi@gmail.com>
2016-11-05 18:08:32 +11:00
Anton Khirnov
eb34d40354 Add a compat dummy stdatomic.h used when threading is disabled
Adapted from the code by Rémi Denis-Courmont from VLC
2016-10-02 18:57:56 +02:00
Anton Khirnov
f9a6a80e06 Add a compat stdatomic.h implementation based on pthreads
Adapted from the code by Rémi Denis-Courmont from VLC
2016-10-02 18:56:52 +02:00
Anton Khirnov
bb81ed4765 Add a compat stdatomic.h implementation based on suncc atomics
Adapted from the code by Rémi Denis-Courmont from VLC
2016-10-02 18:55:41 +02:00
Anton Khirnov
c2755864af Add a compat stdatomic.h implementation based on windows atomics
Adapted from the code by Rémi Denis-Courmont from VLC
2016-10-02 18:54:28 +02:00
Anton Khirnov
4e928ef340 Add a compat stdatomic.h implementation based on GCC atomics
Adapted from the code by Rémi Denis-Courmont from VLC
2016-10-02 18:52:08 +02:00
Timo Rothenpieler
7904859fd8 compat/cuda: convert to unix line endings 2016-09-23 11:43:00 +02:00
Philip Langdale
843aff3cf7 cuvid: Use bundled headers
We need to remove the dynlink fanciness and replace it with normal
function prototypes and update the include paths and configure logic.

We don't need to explicitly check for PICPARMS now - they're going
to be there.
2016-09-22 18:38:51 -07:00
Philip Langdale
f59e10b0f4 cuvid: Add MIT licenced nvcuid headers from Video SDK 7.0
For unknown reasons, the only accurately descriptive version of
cuviddec.h is in the Video SDK - the one in CUDA 7.5 lacks vp8
PICPARAMS and the vp9 struct definition is inaccurate. The CUDA 8 RC
includes an ancient version of this file from many many years go.

However, the one in the Video SDK is modified to work through a
dynamic link mechanism which we don't really want to use, so the
next change will modify the files to just declare functions in
the normal way.

I've split the changes so it's clear to see what changed between
the original files and ones that work for us.
2016-09-22 18:38:36 -07:00
Timo Rothenpieler
325e56479f avcodec/nvenc: include nvEncodeAPI v7 SDK header
As Nvidia has put the most recent Video Codec SDK behind a double
registration wall, of which one needs manual approval of a lenghty
application, bundling this header saves everyone trying to use NVENC
from that headache.

The header is still MIT licensed and thus fine to bundle with ffmpeg.

Not bundling this header would get ffmpeg stuck at SDK v6, which is
still freely available, holding back future development of the NVENC
encoder.
2016-08-28 16:47:54 +02:00
Stephen Hutchinson
f84cff8565 compat/avisynth: update AviSynth+ header
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-08-17 18:08:29 +02:00
Derek Buitenhuis
dc0152548f Merge commit '6bb99757b780144d9fa27cdce09d3621e1a0ed43'
* commit '6bb99757b780144d9fa27cdce09d3621e1a0ed43':
  jack: Support OSX

Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-05-08 23:02:33 +01:00
Josh de Kock
6bb99757b7 jack: Support OSX
Previously, with JACK installed, the configure script would enable the
JACK indev; this broke on OS X due to an incomplete pthreads
implementation. Add some simple macros to map libdispatch to pthreads
on OS X.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2016-03-31 18:03:21 +02:00
KO Myung-Hun
b8bc6b14a5 compat/os2threads: split long lines
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-14 19:17:36 +01:00
KO Myung-Hun
6bf5e7d3e7 compat/os2threads: support the return value of joined thread
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-14 19:17:36 +01:00
KO Myung-Hun
22a4046d66 compat/os2threads: Improve pthread_cond_xxx() functions
1. Manipulate waiting count in pthread_cond_wait()
2. Use builtin atomic functions to manipulate waiting count

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-02-14 19:17:36 +01:00