Closed twelho closed 1 month ago
Thanks for the input. VPL dispatcher searches for runtime libraries in a set of known paths plus additional locations specified with environment variables, as listed above. More info is here in the programing guide. The install location for VPL dispatcher itself (this repository) is not included as a default search path, since the runtime libraries which it loads are built from different repositories and may not be installed to the same path. However, this is something we will consider adding with the next update of VPL API.
Hi @twelho This is issue is now resolved in our latest release. https://github.com/intel/libvpl/releases/tag/v2.11.0
Specifically, if -D ENABLE_LIBDIR_IN_RUNTIME_SEARCH=ON
is added during cmake configuration, then CMAKE_INSTALL_FULL_LIBDIR
will be added to the runtime library search locations.
Currently, oneVPL relies on a fixed list of paths and some environment variables for locating its libraries. This caused an issue in OBS Studio, where the install prefix used in the Flatpak build (Linux/x86_64) is not being searched for libraries. See https://github.com/obsproject/obs-studio/pull/10047 for details.
In summary, this results in
MFX_ERR_NOT_FOUND
being returned fromMFXCreateSession
, implemented onlibvpl
's side in mfx_dispatcher_vpl.cpp. Internally,CreateSession
fails in mfx_dispatcher_vpl_loader.cpp due tom_implInfoList
being empty. That list is populated byQueryLibraryCaps
, which in turn requiresm_libInfoList
to be populated. This happens inBuildListOfCandidateLibs
, which ultimately checks the following paths for the libraries, in from highest to lowest priority:ONEVPL_PRIORITY_PATH
environment variableLD_LIBRARY_PATH
environment variable/usr/lib/x86_64-linux-gnu
/lib
/usr/lib
/lib64
/usr/lib64
ONEVPL_SEARCH_PATH
environment variable/opt/intel/mediasdk/lib
/opt/intel/mediasdk/lib64
As argued for in https://github.com/obsproject/obs-studio/pull/10047, this list should unconditionally contain the install prefix, which in this case is
/app/lib
. Setting, for example,ONEVPL_SEARCH_PATH=/app/lib
is considered a workaround, not a solution.