@@ -321,6 +321,7 @@ External library support:
--disable-sdl2 disable sdl2 [autodetect]
--disable-securetransport disable Secure Transport, needed for TLS support
on OSX if openssl and gnutls are not used [autodetect]
+ --disable-uuid disable uuid [autodetect]
--enable-vapoursynth enable VapourSynth demuxer [no]
--enable-vulkan enable Vulkan code [no]
--disable-xlib disable xlib [autodetect]
@@ -1747,6 +1748,7 @@ EXTERNAL_AUTODETECT_LIBRARY_LIST="
sdl2
securetransport
sndio
+ uuid
xlib
zlib
"
@@ -2964,6 +2966,7 @@ vaapi_x11_deps="xlib_x11"
videotoolbox_hwaccel_deps="videotoolbox pthreads"
videotoolbox_hwaccel_extralibs="-framework QuartzCore"
vulkan_deps_any="libdl LoadLibrary"
+vulkan_suggest="uuid"
xvmc_deps="X11_extensions_XvMClib_h"
av1_d3d11va_hwaccel_deps="d3d11va DXVA_PicParams_AV1"
@@ -3454,8 +3457,8 @@ decklink_indev_extralibs="-lstdc++"
decklink_outdev_deps="decklink threads"
decklink_outdev_suggest="libklvanc"
decklink_outdev_extralibs="-lstdc++"
-dshow_indev_deps="IBaseFilter"
-dshow_indev_extralibs="-lpsapi -lole32 -lstrmiids -luuid -loleaut32 -lshlwapi"
+dshow_indev_deps="IBaseFilter uuid"
+dshow_indev_extralibs="-lpsapi -lole32 -lstrmiids -loleaut32 -lshlwapi"
fbdev_indev_deps="linux_fb_h"
fbdev_outdev_deps="linux_fb_h"
gdigrab_indev_deps="CreateDIBSection"
@@ -3743,7 +3746,7 @@ avfilter_deps="avutil"
avfilter_suggest="libm"
avformat_deps="avcodec avutil"
avformat_suggest="libm network zlib"
-avutil_suggest="clock_gettime ffnvcodec libm libdrm libmfx opencl user32 vaapi vulkan videotoolbox corefoundation corevideo coremedia bcrypt"
+avutil_suggest="clock_gettime ffnvcodec libm libdrm libmfx uuid opencl user32 vaapi vulkan videotoolbox corefoundation corevideo coremedia bcrypt"
postproc_deps="avutil gpl"
postproc_suggest="libm"
swresample_deps="avutil"
@@ -6826,6 +6829,10 @@ enabled vdpau &&
enabled vdpau &&
check_lib vdpau_x11 "vdpau/vdpau.h vdpau/vdpau_x11.h" vdp_device_create_x11 -lvdpau -lX11
+enabled uuid &&
+ check_pkg_config uuid uuid "uuid/uuid.h" uuid_parse ||
+ check_lib uuid "uuid/uuid.h" uuid_parse -luuid
+
enabled crystalhd && check_lib crystalhd "stdint.h libcrystalhd/libcrystalhd_if.h" DtsCrystalHDVersion -lcrystalhd
if enabled vulkan; then
@@ -1184,8 +1184,10 @@ extension.
@item vulkan
If @var{device} is an integer, it selects the device by its index in a
-system-dependent list of devices. If @var{device} is any other string, it
-selects the first device with a name containing that string as a substring.
+system-dependent list of devices. If @var{device} is a UUID, the device
+will be selected by checking for matching UUIDs. If @var{device} is any other
+string, it selects the first device with a name containing that string as a
+substring.
The following options are recognized:
@table @option
@@ -38,6 +38,10 @@
#include <dlfcn.h>
#endif
+#if CONFIG_UUID
+#include <uuid/uuid.h>
+#endif
+
#if CONFIG_LIBDRM
#include <xf86drm.h>
#include <drm_fourcc.h>
@@ -1367,7 +1371,11 @@ static int vulkan_device_create(AVHWDeviceContext *ctx, const char *device,
dev_select.index = strtol(device, &end, 10);
if (end == device) {
dev_select.index = 0;
- dev_select.name = device;
+#if CONFIG_UUID
+ if (!uuid_parse(device, dev_select.uuid))
+ dev_select.has_uuid = 1;
+#endif
+ dev_select.name = device;
}
}