[vlc-commits] direct3d11: check the right flag combination
Steve Lhomme
git at videolan.org
Thu May 28 17:30:06 CEST 2015
vlc | branch: master | Steve Lhomme <robux4 at gmail.com> | Wed May 27 15:05:57 2015 +0200| [49e1ba40f26efb5224cf3a615d3f0fe2c3511d5c] | committer: Jean-Baptiste Kempf
direct3d11: check the right flag combination
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=49e1ba40f26efb5224cf3a615d3f0fe2c3511d5c
---
modules/video_output/msw/direct3d11.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/modules/video_output/msw/direct3d11.c b/modules/video_output/msw/direct3d11.c
index 48e5f03..f61e27f 100644
--- a/modules/video_output/msw/direct3d11.c
+++ b/modules/video_output/msw/direct3d11.c
@@ -870,7 +870,7 @@ static int Direct3D11Open(vout_display_t *vd, video_format_t *fmt)
if( SUCCEEDED( ID3D11Device_CheckFormatSupport(sys->d3ddevice,
d3d_formats[i].formatTexture,
&i_formatSupport)) &&
- ( i_formatSupport & i_quadSupportFlags ))
+ ( i_formatSupport & i_quadSupportFlags ) == i_quadSupportFlags )
{
msg_Dbg(vd, "Using pixel format %s", d3d_formats[i].name );
sys->vlcFormat = d3d_formats[i].fourcc;
@@ -890,7 +890,7 @@ static int Direct3D11Open(vout_display_t *vd, video_format_t *fmt)
if( SUCCEEDED( ID3D11Device_CheckFormatSupport(sys->d3ddevice,
d3d_formats[i].formatTexture,
&i_formatSupport)) &&
- ( i_formatSupport & i_quadSupportFlags ))
+ ( i_formatSupport & i_quadSupportFlags ) == i_quadSupportFlags )
{
msg_Dbg(vd, "Using pixel format %s", d3d_formats[i].name );
sys->vlcFormat = d3d_formats[i].fourcc;
@@ -912,14 +912,14 @@ static int Direct3D11Open(vout_display_t *vd, video_format_t *fmt)
if( SUCCEEDED( ID3D11Device_CheckFormatSupport(sys->d3ddevice,
DXGI_FORMAT_R8G8B8A8_UNORM,
&i_formatSupport)) &&
- ( i_formatSupport & i_quadSupportFlags )) {
+ ( i_formatSupport & i_quadSupportFlags ) == i_quadSupportFlags) {
sys->d3dregion_format = DXGI_FORMAT_R8G8B8A8_UNORM;
sys->pSubpictureChromas[0] = VLC_CODEC_RGBA;
sys->pSubpictureChromas[1] = 0;
} else if( SUCCEEDED( ID3D11Device_CheckFormatSupport(sys->d3ddevice,
DXGI_FORMAT_B8G8R8A8_UNORM,
&i_formatSupport)) &&
- ( i_formatSupport & i_quadSupportFlags )) {
+ ( i_formatSupport & i_quadSupportFlags ) == i_quadSupportFlags) {
sys->d3dregion_format = DXGI_FORMAT_B8G8R8A8_UNORM;
sys->pSubpictureChromas[0] = VLC_CODEC_BGRA;
sys->pSubpictureChromas[1] = 0;
More information about the vlc-commits
mailing list