Commit 58a2a973 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont Committed by Jean-Paul Saman

vdpau: VDPAU hardware decoding with avcodec

This requires bleeding-edge libavcodec.
(cherry picked from commit ae1e8b4ac3167981f7f46c83afeaa9423330fc18)

Conflicts:
	modules/codec/Modules.am
	po/POTFILES.in
parent bb466df9
...@@ -3132,6 +3132,44 @@ AM_CONDITIONAL([HAVE_XCB], [test "${have_xcb}" = "yes"]) ...@@ -3132,6 +3132,44 @@ AM_CONDITIONAL([HAVE_XCB], [test "${have_xcb}" = "yes"])
AM_CONDITIONAL([HAVE_VAAPI_XCB], [test "${have_vaapi_xcb}" = "yes"]) AM_CONDITIONAL([HAVE_VAAPI_XCB], [test "${have_vaapi_xcb}" = "yes"])
AM_CONDITIONAL([HAVE_VAAPI_GLX], [test "${have_vaapi_glx}" = "yes"]) AM_CONDITIONAL([HAVE_VAAPI_GLX], [test "${have_vaapi_glx}" = "yes"])
dnl
dnl VDPAU needs X11 and avcodec
dnl
AC_ARG_ENABLE(vdpau,
[AS_HELP_STRING([--enable-vdpau],
[VDPAU hardware decoder support (default auto)])])
have_vdpau="no"
AS_IF([test "${enable_vdpau}" != "no"], [
PKG_CHECK_MODULES([VDPAU], [vdpau], [
have_vdpau="yes"
AC_MSG_NOTICE([VDPAU acceleration activated])
], [
AS_IF([test -n "${enable_vdpau}"], [
AC_MSG_ERROR([${VDPAU_PKG_ERRORS}.])
])
])
AS_IF([test "${no_x}" = "yes"], [
AC_MSG_ERROR([VDPAU requires Xlib (X11).])
])
])
dnl AM_CONDITIONAL([HAVE_VDPAU], [test "${have_vdpau}" = "yes"])
have_avcodec_vdpau="no"
AS_IF([test "${have_vdpau}" = "yes"], [
PKG_CHECK_EXISTS([libavutil >= 0.52.4 libavcodec >= 54.36.0], [
have_avcodec_vdpau="yes"
], [
AS_IF([test -n "${enable_vdpau}"], [
AC_MSG_ERROR([libavutil >= 0.52.4 and libavcodec >= 54.36.0 are required for VDPAU decoding.])
], [
AC_MSG_WARN([libavutil >= 0.52.4 and libavcodec >= 54.36.0 are required for VDPAU decoding.])
])
])
])
AM_CONDITIONAL([HAVE_AVCODEC_VDPAU], [test "${have_avcodec_vdpau}" = "yes"])
dnl dnl
dnl SDL module dnl SDL module
dnl dnl
......
...@@ -357,6 +357,7 @@ $Id$ ...@@ -357,6 +357,7 @@ $Id$
* vc1: VC-1 Video demuxer * vc1: VC-1 Video demuxer
* vcd: input module for accessing Video CDs * vcd: input module for accessing Video CDs
* vcdx: input module for accessing Video CDs with navigation & stills * vcdx: input module for accessing Video CDs with navigation & stills
* vdpau: VDPAU hardware-accelerated decoding
* vdummy: dummy video display * vdummy: dummy video display
* visual: visualisation system * visual: visualisation system
* vmem: memory video driver * vmem: memory video driver
......
...@@ -85,3 +85,14 @@ libdxva2_plugin_la_LIBADD = $(AM_LIBADD) -lole32 -lshlwapi -luuid ...@@ -85,3 +85,14 @@ libdxva2_plugin_la_LIBADD = $(AM_LIBADD) -lole32 -lshlwapi -luuid
if HAVE_AVCODEC_DXVA2 if HAVE_AVCODEC_DXVA2
libvlc_LTLIBRARIES += libdxva2_plugin.la libvlc_LTLIBRARIES += libdxva2_plugin.la
endif endif
# VDPAU
libvdpau_plugin_la_SOURCES = vdpau.c
libvdpau_plugin_la_CFLAGS = $(AM_CFLAGS) $(VDPAU_CFLAGS) \
$(X_CFLAGS) $(CFLAGS_avcodec)
libvdpau_plugin_la_LIBADD = $(AM_LIBADD) $(VDPAU_LIBS) \
$(X_LIBS) $(X_PRE_LIBS) -lX11 $(LIBS_avcodec)
libvdpau_plugin_la_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_avcodec)
if HAVE_AVCODEC_VDPAU
libvlc_LTLIBRARIES += libvdpau_plugin.la
endif
This diff is collapsed.
...@@ -354,6 +354,8 @@ modules/codec/avcodec/chroma.c ...@@ -354,6 +354,8 @@ modules/codec/avcodec/chroma.c
modules/codec/avcodec/deinterlace.c modules/codec/avcodec/deinterlace.c
modules/codec/avcodec/encoder.c modules/codec/avcodec/encoder.c
modules/codec/avcodec/fourcc.c modules/codec/avcodec/fourcc.c
modules/codec/avcodec/vaapi.c
modules/codec/avcodec/vdpau.c
modules/codec/avcodec/video.c modules/codec/avcodec/video.c
modules/codec/cc.c modules/codec/cc.c
modules/codec/cc.h modules/codec/cc.h
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment