Unified · Split
| @@ -845,18 +845,18 @@ static int qsv_d3d11_update_config(void *ctx, mfxHDL handle, mfxConfig cfg) · 844 unmodified lines | |||
| 845 | if (SUCCEEDED(hr)) { | 845 | if (SUCCEEDED(hr)) { |
| 846 | hr = IDXGIDevice_GetAdapter(pDXGIDevice, &pDXGIAdapter); | 846 | hr = IDXGIDevice_GetAdapter(pDXGIDevice, &pDXGIAdapter); |
| 847 | if (FAILED(hr)) { | 847 | if (FAILED(hr)) { |
| 848 | av_log(ctx, AV_LOG_ERROR, "Error IDXGIDevice_GetAdapter %d\n", hr); | 848 | av_log(ctx, AV_LOG_ERROR, "Error IDXGIDevice_GetAdapter %#lx\n", hr); |
| 849 | IDXGIDevice_Release(pDXGIDevice); | 849 | IDXGIDevice_Release(pDXGIDevice); |
| 850 | return ret; | 850 | return ret; |
| 851 | } | 851 | } |
| 852 | 852 | ||
| 853 | hr = IDXGIAdapter_GetDesc(pDXGIAdapter, &adapterDesc); | 853 | hr = IDXGIAdapter_GetDesc(pDXGIAdapter, &adapterDesc); |
| 854 | if (FAILED(hr)) { | 854 | if (FAILED(hr)) { |
| 855 | av_log(ctx, AV_LOG_ERROR, "Error IDXGIAdapter_GetDesc %d\n", hr); | 855 | av_log(ctx, AV_LOG_ERROR, "Error IDXGIAdapter_GetDesc %#lx\n", hr); |
| 856 | goto fail; | 856 | goto fail; |
| 857 | } | 857 | } |
| 858 | } else { | 858 | } else { |
| 859 | av_log(ctx, AV_LOG_ERROR, "Error ID3D11Device_QueryInterface %d\n", hr); | 859 | av_log(ctx, AV_LOG_ERROR, "Error ID3D11Device_QueryInterface %#lx\n", hr); |
| 860 | return ret; | 860 | return ret; |
| 861 | } | 861 | } |
| 862 | 862 | ||
| @@ -917,47 +917,47 @@ static int qsv_d3d9_update_config(void *ctx, mfxHDL handle, mfxConfig cfg) · 54 unmodified lines | |||
| 917 | 917 | ||
| 918 | hr = IDirect3DDeviceManager9_OpenDeviceHandle(devmgr, &device_handle); | 918 | hr = IDirect3DDeviceManager9_OpenDeviceHandle(devmgr, &device_handle); |
| 919 | if (FAILED(hr)) { | 919 | if (FAILED(hr)) { |
| 920 | av_log(ctx, AV_LOG_ERROR, "Error OpenDeviceHandle %d\n", hr); | 920 | av_log(ctx, AV_LOG_ERROR, "Error OpenDeviceHandle %#lx\n", hr); |
| 921 | goto fail; | 921 | goto fail; |
| 922 | } | 922 | } |
| 923 | 923 | ||
| 924 | hr = IDirect3DDeviceManager9_LockDevice(devmgr, device_handle, &device, TRUE); | 924 | hr = IDirect3DDeviceManager9_LockDevice(devmgr, device_handle, &device, TRUE); |
| 925 | if (FAILED(hr)) { | 925 | if (FAILED(hr)) { |
| 926 | av_log(ctx, AV_LOG_ERROR, "Error LockDevice %d\n", hr); | 926 | av_log(ctx, AV_LOG_ERROR, "Error LockDevice %#lx\n", hr); |
| 927 | IDirect3DDeviceManager9_CloseDeviceHandle(devmgr, device_handle); | 927 | IDirect3DDeviceManager9_CloseDeviceHandle(devmgr, device_handle); |
| 928 | goto fail; | 928 | goto fail; |
| 929 | } | 929 | } |
| 930 | hr = IDirect3DDevice9_QueryInterface(device, &IID_IDirect3DDevice9Ex, (void **)&device_ex); | 930 | hr = IDirect3DDevice9_QueryInterface(device, &IID_IDirect3DDevice9Ex, (void **)&device_ex); |
| 931 | IDirect3DDevice9_Release(device); | 931 | IDirect3DDevice9_Release(device); |
| 932 | if (FAILED(hr)) { | 932 | if (FAILED(hr)) { |
| 933 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9_QueryInterface %d\n", hr); | 933 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9_QueryInterface %#lx\n", hr); |
| 934 | goto unlock; | 934 | goto unlock; |
| 935 | } | 935 | } |
| 936 | 936 | ||
| 937 | hr = IDirect3DDevice9Ex_GetCreationParameters(device_ex, ¶ms); | 937 | hr = IDirect3DDevice9Ex_GetCreationParameters(device_ex, ¶ms); |
| 938 | if (FAILED(hr)) { | 938 | if (FAILED(hr)) { |
| 939 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9_GetCreationParameters %d\n", hr); | 939 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9_GetCreationParameters %#lx\n", hr); |
| 940 | IDirect3DDevice9Ex_Release(device_ex); | 940 | IDirect3DDevice9Ex_Release(device_ex); |
| 941 | goto unlock; | 941 | goto unlock; |
| 942 | } | 942 | } |
| 943 | 943 | ||
| 944 | hr = IDirect3DDevice9Ex_GetDirect3D(device_ex, &d3d9); | 944 | hr = IDirect3DDevice9Ex_GetDirect3D(device_ex, &d3d9); |
| 945 | if (FAILED(hr)) { | 945 | if (FAILED(hr)) { |
| 946 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9Ex_GetDirect3D %d\n", hr); | 946 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9Ex_GetDirect3D %#lx\n", hr); |
| 947 | IDirect3DDevice9Ex_Release(device_ex); | 947 | IDirect3DDevice9Ex_Release(device_ex); |
| 948 | goto unlock; | 948 | goto unlock; |
| 949 | } | 949 | } |
| 950 | hr = IDirect3D9_QueryInterface(d3d9, &IID_IDirect3D9Ex, (void **)&d3d9ex); | 950 | hr = IDirect3D9_QueryInterface(d3d9, &IID_IDirect3D9Ex, (void **)&d3d9ex); |
| 951 | IDirect3D9_Release(d3d9); | 951 | IDirect3D9_Release(d3d9); |
| 952 | if (FAILED(hr)) { | 952 | if (FAILED(hr)) { |
| 953 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3D9_QueryInterface3D %d\n", hr); | 953 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3D9_QueryInterface3D %#lx\n", hr); |
| 954 | IDirect3DDevice9Ex_Release(device_ex); | 954 | IDirect3DDevice9Ex_Release(device_ex); |
| 955 | goto unlock; | 955 | goto unlock; |
| 956 | } | 956 | } |
| 957 | 957 | ||
| 958 | hr = IDirect3D9Ex_GetAdapterLUID(d3d9ex, params.AdapterOrdinal, &luid); | 958 | hr = IDirect3D9Ex_GetAdapterLUID(d3d9ex, params.AdapterOrdinal, &luid); |
| 959 | if (FAILED(hr)) { | 959 | if (FAILED(hr)) { |
| 960 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9Ex_GetAdapterLUID %d\n", hr); | 960 | av_log(ctx, AV_LOG_ERROR, "Error IDirect3DDevice9Ex_GetAdapterLUID %#lx\n", hr); |
| 961 | goto release; | 961 | goto release; |
| 962 | } | 962 | } |
| 963 | 963 | ||