Commit Graph

4972 Commits

Author SHA1 Message Date
James Almer
4af050c46e configure: remove superfluous cuvid and nvdec checks
Both are autodetected, and their dependency on cuda is checked
elsewhere.

Fixes ticket #6849.

Reviewed-by: Philip Langdale <philipl@overt.org>
Signed-off-by: James Almer <jamrial@gmail.com>
2017-11-25 12:43:09 -03:00
Mark Thompson
3650cb2dfa lavu,lavfi,ffmpeg: Remove experimental OpenCL API
This was added in early 2013 and abandoned several months later; as far as
I can tell, there are no external users.  Future OpenCL use will be via
hwcontext, which requires neither special OpenCL-only API nor global state
in libavutil.

All internal users are also deleted - this is just the unsharp filter
(replaced by unsharp_opencl, which is more flexible) and the deshake filter
(no replacement).
2017-11-22 23:20:39 +00:00
Mark Thompson
7faa8d8b03 lavfi: Add OpenCL unsharp mask filter
Intended to replace existing opencl mode of the unsharp filter.
Supports many more pixel formats and works without immediate upload
and download of frame data.  The options are compatible with the
existing filter.
2017-11-22 23:18:35 +00:00
Mark Thompson
9204b2deea lavfi: Add OpenCL overlay filter
Input and output formats must be the same, the overlay format must be
the same as the input except possibly with an additional alpha component.
2017-11-22 23:18:02 +00:00
Mark Thompson
7faae6e745 hwcontext_opencl: DRM to OpenCL mapping for ARM
Using cl_arm_import_memory.  Unfortunately, despite this not being a
standard extension, the function clImportMemoryARM() is not accessible
via clGetExtensionFunctionAddressForPlatform().  This means that it has
to be linked directly to the ARM OpenCL binary, so making a portable
binary is not possible as it is with all other mapping extensions.
2017-11-22 23:02:33 +00:00
Mark Thompson
f06754e4f3 hwcontext_opencl: D3D11 to OpenCL mapping
Using cl_khr_d3d11_sharing and cl_intel_d3d11_nv12_media_sharing.
2017-11-22 23:02:33 +00:00
Mark Thompson
9e7cda1b1e hwcontext_opencl: DXVA2 to OpenCL mapping
Using cl_khr_dx9_media_sharing.
2017-11-22 23:02:33 +00:00
Mark Thompson
403cde8e85 hwcontext_opencl: QSV to OpenCL mapping for Intel Media SDK
Uses the cl_intel_va_api_media_sharing extension, which supports only
NV12 surfaces and only mapping from QSV to OpenCL.
2017-11-22 23:02:33 +00:00
Mark Thompson
eb3e9f469a hwcontext_opencl: VAAPI to OpenCL mapping for Intel i965+beignet
Supports all surface formats in common between the two.
2017-11-22 23:02:33 +00:00
Mark Thompson
b25d8ef0a7 lavu: OpenCL hwcontext implementation 2017-11-22 23:02:29 +00:00
James Zern
b765a04550 configure: require libvpx-1.4.0 for vp[89] support
this will simplify libvpxenc/dec.c and ensure more stable versions of
the codecs are present.

Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: James Zern <jzern@google.com>
2017-11-20 16:02:21 -08:00
Philip Langdale
6b77a10e43 avcodec: Implement mpeg4 nvdec hwaccel
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.
2017-11-20 07:21:41 -08:00
Philip Langdale
8bca292c30 avcodec: Implement mpeg1 nvdec hwaccel
Once I remembered that there's a separate decoder type for mpeg1,
even though params struct is shared with mpeg2, everything worked.
2017-11-20 07:03:26 -08:00
James Almer
c9cd990dcc Merge commit '3152058bf1dca318898550efacf0286f4836cae6'
* commit '3152058bf1dca318898550efacf0286f4836cae6':
  libavcodec: Don't use dllexport, only dllimport when building DLLs

Merged-by: James Almer <jamrial@gmail.com>
2017-11-19 18:26:45 -03:00
James Almer
c6f7eb8663 configure: fix module dependencies on zlib
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>
2017-11-19 18:14:48 -03:00
Martin Storsjö
3152058bf1 libavcodec: Don't use dllexport, only dllimport when building DLLs
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>
2017-11-19 22:01:38 +02:00
James Darnley
0b7cd29d47 configure: add audio_frame_queue dependency for aptx codec 2017-11-19 14:54:34 +01:00
Philip Langdale
7c9f739d86 avcodec: Implement mpeg2 nvdec hwaccel
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.
2017-11-18 08:13:50 -08:00
Timo Rothenpieler
4fb20d4e3a configure: call flatten_extralibs in a subshell
By putting the call in a subshell, the problem of it spilling
cleanup-decision from a previous library to other libraries is avoided.

For example, it could have already cleaned up cuda_extralibs in a
previous library that depended on cuda. Then when it gets to avutil, it
will never pick up the dependency of avutil to cuda, which depends on
libdl, which in turn results in a missing -ldl extralib, resulting in
link failures in certain configurations.
2017-11-16 17:39:39 +01:00
James Almer
edef07569c Merge commit 'bad7ce1d82f0b7da55086b8c6124eff0d35a1b1a'
* commit 'bad7ce1d82f0b7da55086b8c6124eff0d35a1b1a':
  makedef: Pass EXTERN_PREFIX from configure to makedef

Merged-by: James Almer <jamrial@gmail.com>
2017-11-16 13:12:59 -03:00
James Almer
1146a7a363 Merge commit 'd070b9b703a542429a13db9623109ae20474c775'
* commit 'd070b9b703a542429a13db9623109ae20474c775':
  configure: Coalesce some arch configuration and PIC handling

Merged-by: James Almer <jamrial@gmail.com>
2017-11-16 13:11:52 -03:00
James Almer
b449af20d5 Merge commit '9e48de3cc86c732d9cebd496d6f0a2b7e7732754'
* commit '9e48de3cc86c732d9cebd496d6f0a2b7e7732754':
  configure: Miscellaneous minor changes

Merged-by: James Almer <jamrial@gmail.com>
2017-11-16 13:11:24 -03:00
Martin Storsjö
bad7ce1d82 makedef: Pass EXTERN_PREFIX from configure to makedef
This avoids having to use either "dumpbin -headers" to find out
the current architecture, or pass $ARCH from configure to deduce it.

When configuring with --disable-asm, ARCH is equal to "c", which doesn't
give any indication of what symbol prefix is to be used.

Signed-off-by: Martin Storsjö <martin@martin.st>
2017-11-16 16:54:08 +02:00
Diego Biurrun
d070b9b703 configure: Coalesce some arch configuration and PIC handling 2017-11-15 13:29:41 +01:00
Diego Biurrun
9e48de3cc8 configure: Miscellaneous minor changes
- Move a variable closer to where it is used
- Add an explanatory comment
- Simplify a crosscompile check
- Minor SHFLAGS simplification
- Coalesce some threads tests
2017-11-15 13:29:41 +01:00
Philip Langdale
912ceba61b avcodec: Implement vc1 nvdec hwaccel
This hwaccel is interesting because it also works for wmv3/9 content,
which is not supported by the nvidia parser used by cuviddec.
2017-11-14 19:40:01 -08:00
Aman Gupta
e7a5249ab1 avcodec/videotoolboxenc: add hevc_videotoolbox encoder
Signed-off-by: Aman Gupta <aman@tmm1.net>
Reviewed-by: Rodger Combs <rodger.combs@gmail.com>
2017-11-13 14:28:14 -08:00
Timo Rothenpieler
578addcff6 configure: factorize nvdec dependencies 2017-11-13 22:10:37 +01:00
Timo Rothenpieler
681c638fab configure: fix cuda dependency on nvdec 2017-11-13 22:10:37 +01:00
Timo Rothenpieler
f3f73f0893 avcodec: implement vp9 nvdec hwaccel 2017-11-13 20:33:10 +01:00
James Almer
d9ff1e4c8b configure: fix writing library dependencies to config.sh
Signed-off-by: James Almer <jamrial@gmail.com>
2017-11-12 23:04:17 -03:00
James Almer
b72ac6dbb8 configure: fix writing library dependencies to config.sh
Signed-off-by: James Almer <jamrial@gmail.com>
2017-11-12 23:02:31 -03:00
Aman Gupta
fd18d310ec lavf/tls_securetransport: build on iOS
This works as expected on iOS, except for the ca_file feature which
is disabled because SecItemImport is not available.

Signed-off-by: Aman Gupta <aman@tmm1.net>
2017-11-12 14:37:12 -08:00
James Almer
ccf7bca1c9 Merge commit '17b6c7efb471e8ff1b8a7271f6531ba1d52bf69c'
* commit '17b6c7efb471e8ff1b8a7271f6531ba1d52bf69c':
  build: Add missing config.sh dependency for pkg-config files

Merged-by: James Almer <jamrial@gmail.com>
2017-11-12 01:02:02 -03:00
James Almer
792802f5f9 Merge commit '8e0febe28effe7f427e45190eab37110126161ea'
* commit '8e0febe28effe7f427e45190eab37110126161ea':
  configure: Use right variable and right value for AIX ar flags

Merged-by: James Almer <jamrial@gmail.com>
2017-11-12 00:51:21 -03:00
James Almer
221d813599 Merge commit '2cf3c0ab0d84b5cdb379059f8570809a13a306b9'
* commit '2cf3c0ab0d84b5cdb379059f8570809a13a306b9':
  Revert "configure: Detect AIX ar command instead of hardcoding it in the OS section"

Merged-by: James Almer <jamrial@gmail.com>
2017-11-12 00:43:08 -03:00
James Almer
e55781954f Merge commit '192fe52e42f64a493c47cad1461b20fe1149dbea'
* commit '192fe52e42f64a493c47cad1461b20fe1149dbea':
  configure: Miscellaneous minor changes to config file handling

Merged-by: James Almer <jamrial@gmail.com>
2017-11-12 00:39:41 -03:00
James Almer
e0f84c303d Merge commit '61a17423d3711cb34a18b44e1ec2510c2f70a56c'
* commit '61a17423d3711cb34a18b44e1ec2510c2f70a56c':
  configure: Miscellaneous small changes to helper functions

Merged-by: James Almer <jamrial@gmail.com>
2017-11-12 00:38:09 -03:00
James Almer
5b5365fe9d Merge commit '67c72f08a4707c18a67a4734660e3a23cc9488b6'
* commit '67c72f08a4707c18a67a4734660e3a23cc9488b6':
  configure: Stop using dlltool to create an import library

Merged-by: James Almer <jamrial@gmail.com>
2017-11-12 00:20:34 -03:00
James Almer
82fc222f67 Merge commit '9dc79b2943d99f256a3279f09580b27a95fb9aa8'
* commit '9dc79b2943d99f256a3279f09580b27a95fb9aa8':
  configure: Drop support for legacy PGI compiler

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 23:43:36 -03:00
James Almer
12f4e2ba02 Merge commit '0af8a72174108b9bb482f1073a1e9a3bc258af51'
* commit '0af8a72174108b9bb482f1073a1e9a3bc258af51':
  build: Drop support for legacy TI ARM compiler

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 23:41:35 -03:00
James Almer
3749d0defc Merge commit '68649bfed30a35dc3e45ea240541b2774b2f282b'
* commit '68649bfed30a35dc3e45ea240541b2774b2f282b':
  configure: Group system feature variables and system libraries together

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 23:21:55 -03:00
James Almer
d168ff70ea Merge commit '62be1caf161c1241a9e148f347850cfe092588dc'
* commit '62be1caf161c1241a9e148f347850cfe092588dc':
  configure: Bail out early if neither static nor shared libs are built

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 23:11:44 -03:00
James Almer
3e9fd83592 Merge commit 'c6496de33456f20144b994ac38f308f2de333608'
* commit 'c6496de33456f20144b994ac38f308f2de333608':
  configure: Move enabling libc_type into probe_libc() function

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 23:09:21 -03:00
James Almer
fb94e7b39a Revert "Merge commit '8e97a8c69162afce47abea96c8c0914f3550e212'"
This reverts commit 1a4315f24d, reversing
changes made to 869401cefc.

At least one distro (Arch) ships gsm.h inside the gsm/ folder
2017-11-11 18:04:22 -03:00
James Almer
5fd3e6c3a6 Merge commit '41df62fd674bd0c67f7b6952381d235a393245d6'
* commit '41df62fd674bd0c67f7b6952381d235a393245d6':
  configure: Set the default assembler to armasm64 for MSVC for arm64

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 17:48:11 -03:00
James Almer
1338cc1ac2 Merge commit '40d5df67d2c4e1f0dd1e902435567eb5edad6a9a'
* commit '40d5df67d2c4e1f0dd1e902435567eb5edad6a9a':
  configure: Add a comment about why we don't try to enable pic on arm on target_os=win32

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 16:58:15 -03:00
James Almer
ce726e7757 Merge commit '0ca66409911e9fba940424be8bdfa54e056b0a4b'
* commit '0ca66409911e9fba940424be8bdfa54e056b0a4b':
  configure: Don't add -fPIC to asflags when targeting windows

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 16:56:59 -03:00
James Almer
7e3d6f10f0 Merge commit 'f951837ce58e8588b175fb53a76fd453a81528ec'
* commit 'f951837ce58e8588b175fb53a76fd453a81528ec':
  configure: Don't add -fPIC to cflags for target_os=win32

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 16:55:43 -03:00
James Almer
3f27200954 Merge commit '7ac092d05de487d088bc96ab4a7bd6207fbfa98c'
* commit '7ac092d05de487d088bc96ab4a7bd6207fbfa98c':
  build: CryptGenRandom --> wincrypt, it is a better name

Merged-by: James Almer <jamrial@gmail.com>
2017-11-11 16:53:19 -03:00