Skip to content

Commit

Permalink
Add Steam Link support
Browse files Browse the repository at this point in the history
  • Loading branch information
garbear committed Mar 10, 2018
1 parent a9a7a20 commit 2a7ccdc
Show file tree
Hide file tree
Showing 53 changed files with 2,885 additions and 58 deletions.
19 changes: 18 additions & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1197,6 +1197,13 @@ if test "x$use_dbus" != "xno"; then
else
AC_MSG_NOTICE($dbus_disabled)
fi
#case "$host_vendor" != "apple"; determine availability of SDL or SDL2
PKG_CHECK_MODULES([SDL2], [sdl2],
[AC_DEFINE([HAVE_SDL_VERSION],[2],["SDL major version"])
AC_DEFINE([HAVE_SDL],[1],["Define to 1 if using sdl"])
INCLUDES="$INCLUDES $SDL2_CFLAGS"; LIBS="$LIBS $SDL2_LIBS"],
AC_MSG_RESULT("SDL enabled")
)
fi

XB_FIND_SONAME([ASS], [ass])
Expand Down Expand Up @@ -1225,6 +1232,16 @@ else
AC_MSG_RESULT($alsa_disabled)
fi

# Steam Link
AC_CHECK_HEADERS([SLVideo.h SLAudio.h], steamlink_found=yes,)
if test "$steamlink_found" = "yes"; then
USE_STEAMLINK=1
use_pulse=no
AC_DEFINE([HAS_STEAMLINK], [], [Define if we are compiling with the Steam Link SDK])
LIBS="$LIBS -lSLVideo -lSLAudio"
fi
AC_SUBST(USE_STEAMLINK)

# PulseAudio
if test "x$use_pulse" != "xno"; then
if test "$host_vendor" = "apple" ; then
Expand Down Expand Up @@ -1615,7 +1632,7 @@ fi

if test "${USE_STATIC_FFMPEG}" = "1"; then
# get the libdir for static linking
FFMPEG_LIBDIR=${pkg_cfg_prefix}$(PKG_CONFIG_SYSROOT_DIR="" ${PKG_CONFIG} --static --variable=libdir libavcodec)
FFMPEG_LIBDIR=$(${PKG_CONFIG} --static --variable=libdir libavcodec)
GNUTLS_ALL_LIBS=$(${PKG_CONFIG} --static --libs-only-l --silence-errors gnutls)

# check if static libs are available
Expand Down
1 change: 0 additions & 1 deletion system/addon-manifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
<addon>screensaver.xbmc.builtin.black</addon>
<addon>screensaver.xbmc.builtin.dim</addon>
<addon>script.module.pil</addon>
<addon>service.xbmc.versioncheck</addon>
<addon>skin.estuary</addon>
<addon>skin.estouchy</addon>
<addon>webinterface.default</addon>
Expand Down
1 change: 1 addition & 0 deletions tools/depends/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
/target/*/arm-linux-gnueabihf/*
/target/*/arm-linux-androideabi-*/*
/target/*/arm-linux-gnueabi/*
/target/*/armv7a-cros-linux-gnueabi/*
/target/*/macosx*.*_x86_64-target/
/target/*/macosx*.*_x86_64-target/*
/target/*/macosx*.*_i386-target/
Expand Down
72 changes: 36 additions & 36 deletions tools/depends/target/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -130,41 +130,41 @@ distclean::
for d in $(DEPENDS); do $(MAKE) -C $$d distclean; done

linux-system-libs-egl:
[ -f $(PREFIX)/lib/pkgconfig/egl.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/egl.pc $(PREFIX)/lib/pkgconfig/egl.pc
[ -f $(PREFIX)/lib/pkgconfig/damageproto.pc ] || ln -sf /usr/share/pkgconfig/damageproto.pc $(PREFIX)/lib/pkgconfig/damageproto.pc
[ -f $(PREFIX)/lib/pkgconfig/fixesproto.pc ] || ln -sf /usr/share/pkgconfig/fixesproto.pc $(PREFIX)/lib/pkgconfig/fixesproto.pc
[ -f $(PREFIX)/lib/pkgconfig/x11-xcb.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/x11-xcb.pc $(PREFIX)/lib/pkgconfig/x11-xcb.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-dri2.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-dri2.pc $(PREFIX)/lib/pkgconfig/xcb-dri2.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-dri3.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-dri3.pc $(PREFIX)/lib/pkgconfig/xcb-dri3.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-glx.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-glx.pc $(PREFIX)/lib/pkgconfig/xcb-glx.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-xfixes.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-xfixes.pc $(PREFIX)/lib/pkgconfig/xcb-xfixes.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-present.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-present.pc $(PREFIX)/lib/pkgconfig/xcb-present.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-randr.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-randr.pc $(PREFIX)/lib/pkgconfig/xcb-randr.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-render.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-render.pc $(PREFIX)/lib/pkgconfig/xcb-render.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-shape.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-shape.pc $(PREFIX)/lib/pkgconfig/xcb-shape.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb-sync.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-sync.pc $(PREFIX)/lib/pkgconfig/xcb-sync.pc
[ -f $(PREFIX)/lib/pkgconfig/xdamage.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xdamage.pc $(PREFIX)/lib/pkgconfig/xdamage.pc
[ -f $(PREFIX)/lib/pkgconfig/xf86vidmodeproto.pc ] || ln -sf /usr/share/pkgconfig/xf86vidmodeproto.pc $(PREFIX)/lib/pkgconfig/xf86vidmodeproto.pc
[ -f $(PREFIX)/lib/pkgconfig/xfixes.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xfixes.pc $(PREFIX)/lib/pkgconfig/xfixes.pc
[ -f $(PREFIX)/lib/pkgconfig/xshmfence.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xshmfence.pc $(PREFIX)/lib/pkgconfig/xshmfence.pc
[ -f $(PREFIX)/lib/pkgconfig/xxf86vm.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xxf86vm.pc $(PREFIX)/lib/pkgconfig/xxf86vm.pc
[ -L $(PREFIX)/lib/pkgconfig/egl.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/egl.pc $(PREFIX)/lib/pkgconfig/egl.pc
[ -L $(PREFIX)/lib/pkgconfig/damageproto.pc ] || ln -sf /usr/share/pkgconfig/damageproto.pc $(PREFIX)/lib/pkgconfig/damageproto.pc
[ -L $(PREFIX)/lib/pkgconfig/fixesproto.pc ] || ln -sf /usr/share/pkgconfig/fixesproto.pc $(PREFIX)/lib/pkgconfig/fixesproto.pc
[ -L $(PREFIX)/lib/pkgconfig/x11-xcb.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/x11-xcb.pc $(PREFIX)/lib/pkgconfig/x11-xcb.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-dri2.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-dri2.pc $(PREFIX)/lib/pkgconfig/xcb-dri2.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-dri3.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-dri3.pc $(PREFIX)/lib/pkgconfig/xcb-dri3.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-glx.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-glx.pc $(PREFIX)/lib/pkgconfig/xcb-glx.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-xfixes.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-xfixes.pc $(PREFIX)/lib/pkgconfig/xcb-xfixes.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-present.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-present.pc $(PREFIX)/lib/pkgconfig/xcb-present.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-randr.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-randr.pc $(PREFIX)/lib/pkgconfig/xcb-randr.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-render.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-render.pc $(PREFIX)/lib/pkgconfig/xcb-render.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-shape.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-shape.pc $(PREFIX)/lib/pkgconfig/xcb-shape.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb-sync.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb-sync.pc $(PREFIX)/lib/pkgconfig/xcb-sync.pc
[ -L $(PREFIX)/lib/pkgconfig/xdamage.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xdamage.pc $(PREFIX)/lib/pkgconfig/xdamage.pc
[ -L $(PREFIX)/lib/pkgconfig/xf86vidmodeproto.pc ] || ln -sf /usr/share/pkgconfig/xf86vidmodeproto.pc $(PREFIX)/lib/pkgconfig/xf86vidmodeproto.pc
[ -L $(PREFIX)/lib/pkgconfig/xfixes.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xfixes.pc $(PREFIX)/lib/pkgconfig/xfixes.pc
[ -L $(PREFIX)/lib/pkgconfig/xshmfence.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xshmfence.pc $(PREFIX)/lib/pkgconfig/xshmfence.pc
[ -L $(PREFIX)/lib/pkgconfig/xxf86vm.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xxf86vm.pc $(PREFIX)/lib/pkgconfig/xxf86vm.pc

linux-system-libs: linux-system-libs-egl
[ -f $(PREFIX)/lib/pkgconfig/x11.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/x11.pc $(PREFIX)/lib/pkgconfig/x11.pc
[ -f $(PREFIX)/lib/pkgconfig/xproto.pc ] || ln -sf /usr/share/pkgconfig/xproto.pc $(PREFIX)/lib/pkgconfig/xproto.pc
[ -f $(PREFIX)/lib/pkgconfig/kbproto.pc ] || ln -sf /usr/share/pkgconfig/kbproto.pc $(PREFIX)/lib/pkgconfig/kbproto.pc
[ -f $(PREFIX)/lib/pkgconfig/xcb.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb.pc $(PREFIX)/lib/pkgconfig/xcb.pc
[ -f $(PREFIX)/lib/pkgconfig/pthread-stubs.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/pthread-stubs.pc $(PREFIX)/lib/pkgconfig/pthread-stubs.pc
[ -f $(PREFIX)/lib/pkgconfig/xau.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xau.pc $(PREFIX)/lib/pkgconfig/xau.pc
[ -f $(PREFIX)/lib/pkgconfig/xdmcp.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xdmcp.pc $(PREFIX)/lib/pkgconfig/xdmcp.pc
[ -f $(PREFIX)/lib/pkgconfig/xext.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xext.pc $(PREFIX)/lib/pkgconfig/xext.pc
[ -f $(PREFIX)/lib/pkgconfig/xextproto.pc ] || ln -sf /usr/share/pkgconfig/xextproto.pc $(PREFIX)/lib/pkgconfig/xextproto.pc
[ -f $(PREFIX)/lib/pkgconfig/xrandr.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xrandr.pc $(PREFIX)/lib/pkgconfig/xrandr.pc
[ -f $(PREFIX)/lib/pkgconfig/xrender.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xrender.pc $(PREFIX)/lib/pkgconfig/xrender.pc
[ -f $(PREFIX)/lib/pkgconfig/randrproto.pc ] || ln -sf /usr/share/pkgconfig/randrproto.pc $(PREFIX)/lib/pkgconfig/randrproto.pc
[ -f $(PREFIX)/lib/pkgconfig/renderproto.pc ] || ln -sf /usr/share/pkgconfig/renderproto.pc $(PREFIX)/lib/pkgconfig/renderproto.pc
[ -f $(PREFIX)/lib/pkgconfig/xt.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xt.pc $(PREFIX)/lib/pkgconfig/xt.pc
[ -f $(PREFIX)/lib/pkgconfig/ice.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/ice.pc $(PREFIX)/lib/pkgconfig/ice.pc
[ -f $(PREFIX)/lib/pkgconfig/sm.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/sm.pc $(PREFIX)/lib/pkgconfig/sm.pc
[ -f $(PREFIX)/lib/pkgconfig/xmu.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xmu.pc $(PREFIX)/lib/pkgconfig/xmu.pc
[ -f $(PREFIX)/lib/pkgconfig/libdrm.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/libdrm.pc $(PREFIX)/lib/pkgconfig/libdrm.pc
[ -L $(PREFIX)/lib/pkgconfig/x11.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/x11.pc $(PREFIX)/lib/pkgconfig/x11.pc
[ -L $(PREFIX)/lib/pkgconfig/xproto.pc ] || ln -sf /usr/share/pkgconfig/xproto.pc $(PREFIX)/lib/pkgconfig/xproto.pc
[ -L $(PREFIX)/lib/pkgconfig/kbproto.pc ] || ln -sf /usr/share/pkgconfig/kbproto.pc $(PREFIX)/lib/pkgconfig/kbproto.pc
[ -L $(PREFIX)/lib/pkgconfig/xcb.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xcb.pc $(PREFIX)/lib/pkgconfig/xcb.pc
[ -L $(PREFIX)/lib/pkgconfig/pthread-stubs.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/pthread-stubs.pc $(PREFIX)/lib/pkgconfig/pthread-stubs.pc
[ -L $(PREFIX)/lib/pkgconfig/xau.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xau.pc $(PREFIX)/lib/pkgconfig/xau.pc
[ -L $(PREFIX)/lib/pkgconfig/xdmcp.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xdmcp.pc $(PREFIX)/lib/pkgconfig/xdmcp.pc
[ -L $(PREFIX)/lib/pkgconfig/xext.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xext.pc $(PREFIX)/lib/pkgconfig/xext.pc
[ -L $(PREFIX)/lib/pkgconfig/xextproto.pc ] || ln -sf /usr/share/pkgconfig/xextproto.pc $(PREFIX)/lib/pkgconfig/xextproto.pc
[ -L $(PREFIX)/lib/pkgconfig/xrandr.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xrandr.pc $(PREFIX)/lib/pkgconfig/xrandr.pc
[ -L $(PREFIX)/lib/pkgconfig/xrender.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xrender.pc $(PREFIX)/lib/pkgconfig/xrender.pc
[ -L $(PREFIX)/lib/pkgconfig/randrproto.pc ] || ln -sf /usr/share/pkgconfig/randrproto.pc $(PREFIX)/lib/pkgconfig/randrproto.pc
[ -L $(PREFIX)/lib/pkgconfig/renderproto.pc ] || ln -sf /usr/share/pkgconfig/renderproto.pc $(PREFIX)/lib/pkgconfig/renderproto.pc
[ -L $(PREFIX)/lib/pkgconfig/xt.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xt.pc $(PREFIX)/lib/pkgconfig/xt.pc
[ -L $(PREFIX)/lib/pkgconfig/ice.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/ice.pc $(PREFIX)/lib/pkgconfig/ice.pc
[ -L $(PREFIX)/lib/pkgconfig/sm.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/sm.pc $(PREFIX)/lib/pkgconfig/sm.pc
[ -L $(PREFIX)/lib/pkgconfig/xmu.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/xmu.pc $(PREFIX)/lib/pkgconfig/xmu.pc
[ -L $(PREFIX)/lib/pkgconfig/libdrm.pc ] || ln -sf /usr/lib/$(HOST)/pkgconfig/libdrm.pc $(PREFIX)/lib/pkgconfig/libdrm.pc
2 changes: 1 addition & 1 deletion tools/depends/target/ffmpeg/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ APPLY_PATCHES=no

# configuration settings
ffmpg_config = --prefix=$(PREFIX) --extra-version="kodi-$(VERSION)"
ffmpg_config += --cc=$(CC) --cxx=$(CXX) --ar=$(AR) --ranlib=$(RANLIB)
ffmpg_config += --cc="$(CC)" --cxx="$(CXX)" --ar=$(AR) --ranlib=$(RANLIB)
ffmpg_config += --disable-devices --disable-doc
ffmpg_config += --disable-ffplay --disable-ffmpeg --disable-sdl
ffmpg_config += --disable-ffprobe --disable-ffserver
Expand Down
2 changes: 1 addition & 1 deletion tools/depends/target/libsdl2/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ SOURCE=$(LIBNAME)-$(VERSION)
ARCHIVE=$(SOURCE).tar.gz

# configuration settings
CONFIGURE=./configure --prefix=$(PREFIX) --disable-video-directfb
CONFIGURE=./configure --prefix=$(PREFIX) --disable-video-directfb --without-x --disable-video-x11
ifneq ($(OS),linux)
CONFIGURE += --without-x --disable-video-x11
endif
Expand Down
2 changes: 1 addition & 1 deletion tools/depends/target/openssl/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ $(TARBALLS_LOCATION)/$(ARCHIVE):
$(PLATFORM): $(TARBALLS_LOCATION)/$(ARCHIVE) $(DEPS)
rm -rf $(PLATFORM); mkdir -p $(PLATFORM)
cd $(PLATFORM); $(ARCHIVE_TOOL) $(ARCHIVE_TOOL_FLAGS) $(TARBALLS_LOCATION)/$(ARCHIVE)
cd $(PLATFORM); AR="$(AR)" CFLAGS="$(CFLAGS)" CC=$(CC) RANLIB=$(RANLIB) $(CONFIGURE)
cd $(PLATFORM); AR="$(AR)" CFLAGS="$(CFLAGS)" CC="$(CC)" RANLIB=$(RANLIB) $(CONFIGURE)
if test "$(OS)" = "osx"; then \
sed -ie "s|CC= /usr/bin/gcc-4.2|CC= $(CC)|" "$(PLATFORM)/Makefile"; \
sed -ie "s|CFLAG= |CFLAG=$(CFLAGS) |" "$(PLATFORM)/Makefile"; \
Expand Down
2 changes: 1 addition & 1 deletion tools/depends/target/zlib/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ VERSION=1.2.7
SOURCE=$(LIBNAME)-$(VERSION)
ARCHIVE=$(SOURCE).tar.gz
# configuration settings
CONFIGURE= CC="$(CC)" CFLAGS="$(CFLAGS)" ./configure --prefix=$(PREFIX) --static
CONFIGURE= CC="$(CC)" CFLAGS="$(CFLAGS) -fPIC" ./configure --prefix=$(PREFIX) --static

LIBDYLIB=$(PLATFORM)/$(LIBNAME).a

Expand Down
2 changes: 1 addition & 1 deletion xbmc/Application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2238,7 +2238,7 @@ bool CApplication::OnAction(const CAction &action)
m_pPlayer->SetPlaySpeed(1);
return true;
}
if (!m_pPlayer->IsPaused())
if (!m_pPlayer->IsPaused() && m_pPlayer->CanFFRW())
{
if (action.GetID() == ACTION_PLAYER_FORWARD || action.GetID() == ACTION_PLAYER_REWIND)
{
Expand Down
6 changes: 6 additions & 0 deletions xbmc/ApplicationPlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,12 @@ bool CApplicationPlayer::CanPause()
return (player && player->CanPause());
}

bool CApplicationPlayer::CanFFRW()
{
std::shared_ptr<IPlayer> player = GetInternal();
return (player && player->CanFFRW());
}

bool CApplicationPlayer::IsRecording() const
{
std::shared_ptr<IPlayer> player = GetInternal();
Expand Down
1 change: 1 addition & 0 deletions xbmc/ApplicationPlayer.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ class CApplicationPlayer
bool CanPause();
bool CanRecord();
bool CanSeek();
bool CanFFRW();
void DoAudioWork();
void GetAudioCapabilities(std::vector<int> &audioCaps);
int GetAudioStream();
Expand Down
25 changes: 25 additions & 0 deletions xbmc/cores/AudioEngine/AESinkFactory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@
#if defined(HAS_PULSEAUDIO)
#include "Sinks/AESinkPULSE.h"
#endif
#if defined(HAS_STEAMLINK)
#include "Sinks/AESinkSteamLink.h"
#endif
#else
#pragma message("NOTICE: No audio sink for target platform. Audio output will not be available.")
#endif
Expand Down Expand Up @@ -83,6 +86,9 @@ void CAESinkFactory::ParseDevice(std::string &device, std::string &driver)
#if defined(HAS_PULSEAUDIO)
driver == "PULSE" ||
#endif
#if defined(HAS_STEAMLINK)
driver == "STEAMLINK" ||
#endif
#endif
driver == "PROFILER" ||
driver == "NULL")
Expand Down Expand Up @@ -133,6 +139,10 @@ IAESink *CAESinkFactory::TrySink(std::string &driver, std::string &device, AEAud
if (driver == "OSS")
sink = new CAESinkOSS();
#endif
#if defined(HAS_STEAMLINK)
if (driver == "STEAMLINK")
sink = new STEAMLINK::CAESinkSteamLink();
#endif
#endif
}

Expand Down Expand Up @@ -250,6 +260,10 @@ void CAESinkFactory::EnumerateEx(AESinkInfoList &list, bool force)
if (envSink == "OSS")
CAESinkOSS::EnumerateDevicesEx(info.m_deviceInfoList, force);
#endif
#if defined(HAS_STEAMLINK)
if (envSink == "STEAMLINK")
STEAMLINK::CAESinkSteamLink::EnumerateDevicesEx(info.m_deviceInfoList, force);
#endif

if(!info.m_deviceInfoList.empty())
{
Expand Down Expand Up @@ -290,6 +304,17 @@ void CAESinkFactory::EnumerateEx(AESinkInfoList &list, bool force)
list.push_back(info);
#endif

#if defined(HAS_STEAMLINK)
info.m_deviceInfoList.clear();
info.m_sinkName = "STEAMLINK";
STEAMLINK::CAESinkSteamLink::EnumerateDevicesEx(info.m_deviceInfoList, force);
if(!info.m_deviceInfoList.empty())
{
list.push_back(info);
return;
}
#endif

#endif

}
5 changes: 5 additions & 0 deletions xbmc/cores/AudioEngine/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,11 @@ SRCS += Sinks/AESinkOSS.cpp
ifeq (@USE_PULSE@,1)
SRCS += Sinks/AESinkPULSE.cpp
endif
ifeq (@USE_STEAMLINK@,1)
SRCS += Sinks/AESinkSteamLink.cpp
SRCS += Sinks/AESinkSteamLinkStream.cpp
SRCS += Sinks/AESinkSteamLinkTranslator.cpp
endif
endif

SRCS += Engines/ActiveAE/AudioDSPAddons/ActiveAEDSP.cpp
Expand Down
Loading

0 comments on commit 2a7ccdc

Please sign in to comment.