[vlc-commits] Direct3D: reject old drivers with insufficient capabilities.
Jean-Baptiste Kempf
git at videolan.org
Fri Mar 30 14:39:44 CEST 2012
vlc/vlc-2.0 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Fri Mar 30 13:37:33 2012 +0200| [df93af210c92f7eb9749b07d389fd15865f7eef0] | committer: Jean-Baptiste Kempf
Direct3D: reject old drivers with insufficient capabilities.
Close #6501 and #6469
This is not exactly a backport from trunk, since this is less
aggressive.
> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=df93af210c92f7eb9749b07d389fd15865f7eef0
---
modules/video_output/msw/direct3d.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/modules/video_output/msw/direct3d.c b/modules/video_output/msw/direct3d.c
index 9f40065..16c971d 100644
--- a/modules/video_output/msw/direct3d.c
+++ b/modules/video_output/msw/direct3d.c
@@ -510,7 +510,9 @@ 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)) {
+ if (!(sys->d3dcaps.DevCaps2 & D3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES) ||
+ !(sys->d3dcaps.TextureFilterCaps & (D3DPTFILTERCAPS_MAGFPOINT|D3DPTFILTERCAPS_MAGFLINEAR)) ||
+ !(sys->d3dcaps.TextureFilterCaps & (D3DPTFILTERCAPS_MINFPOINT|D3DPTFILTERCAPS_MINFLINEAR))) {
msg_Err(vd, "Device does not support stretching from textures.");
return VLC_EGENERIC;
}
More information about the vlc-commits
mailing list