[vlc-commits] direct3d9: check the format support on the selected adapter
Steve Lhomme
git at videolan.org
Wed Mar 4 16:06:39 CET 2020
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Mon Mar 2 16:23:10 2020 +0100| [3cf1de4649507cf5db23a6f32ed3335ee59f1aa9] | committer: Steve Lhomme
direct3d9: check the format support on the selected adapter
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3cf1de4649507cf5db23a6f32ed3335ee59f1aa9
---
modules/video_output/win32/direct3d9.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/modules/video_output/win32/direct3d9.c b/modules/video_output/win32/direct3d9.c
index 079e6f2798..02a82dd7a9 100644
--- a/modules/video_output/win32/direct3d9.c
+++ b/modules/video_output/win32/direct3d9.c
@@ -810,7 +810,7 @@ static int Direct3D9CreateResources(vout_display_t *vd, const video_format_t *fm
for (int i = 0; i < 2; i++) {
D3DFORMAT dfmt = i == 0 ? D3DFMT_A8B8G8R8 : D3DFMT_A8R8G8B8;
if (SUCCEEDED(IDirect3D9_CheckDeviceFormat(sys->d3d9_device->hd3d.obj,
- D3DADAPTER_DEFAULT,
+ sys->d3d9_device->d3ddev.adapterId,
D3DDEVTYPE_HAL,
sys->d3d9_device->d3ddev.BufferFormat,
D3DUSAGE_DYNAMIC,
@@ -1309,7 +1309,7 @@ static int Direct3D9CheckConversion(vout_display_t *vd, D3DFORMAT src)
HRESULT hr;
/* test whether device can create a surface of that format */
- hr = IDirect3D9_CheckDeviceFormat(d3dobj, D3DADAPTER_DEFAULT,
+ hr = IDirect3D9_CheckDeviceFormat(d3dobj, sys->d3d9_device->d3ddev.adapterId,
D3DDEVTYPE_HAL, dst, 0,
D3DRTYPE_SURFACE, src);
if (SUCCEEDED(hr)) {
@@ -1317,7 +1317,7 @@ static int Direct3D9CheckConversion(vout_display_t *vd, D3DFORMAT src)
** from that format to target format
*/
hr = IDirect3D9_CheckDeviceFormatConversion(d3dobj,
- D3DADAPTER_DEFAULT,
+ sys->d3d9_device->d3ddev.adapterId,
D3DDEVTYPE_HAL,
src, dst);
}
More information about the vlc-commits
mailing list