[vlc-commits] Direct3D: reject too old drivers and let them fallback to DirectDraw
Jean-Baptiste Kempf
git at videolan.org
Fri Mar 23 17:57:41 CET 2012
vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Mar 23 17:04:31 2012 +0100| [544af798a1ec033321a51125c2c71769cc7b7873] | committer: Jean-Baptiste Kempf
Direct3D: reject too old drivers and let them fallback to DirectDraw
They would not work with IDirect3DDevice9::StretchRect
See:
http://forum.videolan.org/viewtopic.php?f=14&t=99498
http://forum.videolan.org/viewtopic.php?f=14&t=99235
http://forum.videolan.org/viewtopic.php?f=14&t=98882
http://forum.videolan.org/viewtopic.php?f=14&t=98514
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=544af798a1ec033321a51125c2c71769cc7b7873
---
modules/video_output/msw/direct3d.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/modules/video_output/msw/direct3d.c b/modules/video_output/msw/direct3d.c
index ec605c2..9f40065 100644
--- a/modules/video_output/msw/direct3d.c
+++ b/modules/video_output/msw/direct3d.c
@@ -510,6 +510,10 @@ static int Direct3DCreate(vout_display_t *vd)
}
/* TODO: need to test device capabilities and select the right render function */
+ if (!(sys->d3dcaps.DevCaps2 & D3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES)) {
+ msg_Err(vd, "Device does not support stretching from textures.");
+ return VLC_EGENERIC;
+ }
return VLC_SUCCESS;
}
More information about the vlc-commits
mailing list