lavu/hwcontext_qsv: Make sure hardware vendor is Intel for qsv on d3d11va

When multiple hardwares are available, the default one might not be
Intel Hardware. We can use option vendor_id to choose the required
vendor.

Tested-by: Artem Galin <artem.galin@intel.com>
Signed-off-by: Haihao Xiang <haihao.xiang@intel.com>
This commit is contained in:
Haihao Xiang 2023-11-28 12:42:27 +08:00
parent e5f8b5313e
commit f89cff96d0
1 changed files with 6 additions and 0 deletions

View File

@ -2200,6 +2200,12 @@ static int qsv_device_create(AVHWDeviceContext *ctx, const char *device,
#endif #endif
#if CONFIG_D3D11VA #if CONFIG_D3D11VA
case AV_HWDEVICE_TYPE_D3D11VA: case AV_HWDEVICE_TYPE_D3D11VA:
{
// Make sure the hardware vendor is Intel when multiple devices are
// available, it will be ignored if user specifies the child device
// explicitly
av_dict_set(&child_device_opts, "vendor_id", "0x8086", 0);
}
break; break;
#endif #endif
#if CONFIG_DXVA2 #if CONFIG_DXVA2