[PATCH 1/2] Fixed color problem with win32 by changing to 4cc =
Paul Fernquist
fernqui at hotmail.com
Fri Jun 26 06:03:59 CEST 2009
submitted to DirectX=0A=
=0A=
---=0A=
modules/video_output/msw/directx.c | 36 =
+++---------------------------------=0A=
1 files changed, 3 insertions(+), 33 deletions(-)=0A=
=0A=
diff --git a/modules/video_output/msw/directx.c =
b/modules/video_output/msw/directx.c=0A=
index 9494de9..1137029 100644=0A=
--- a/modules/video_output/msw/directx.c=0A=
+++ b/modules/video_output/msw/directx.c=0A=
@@ -352,22 +352,8 @@ static int Init( vout_thread_t *p_vout )=0A=
* video decoder to decode directly into direct buffers as they are=0A=
* created into video memory and video memory is _really_ slow */=0A=
=0A=
- /* Choose the chroma we will try first. */=0A=
- switch( p_vout->render.i_chroma )=0A=
- {=0A=
- case VLC_CODEC_YUYV:=0A=
- p_vout->output.i_chroma =3D VLC_CODEC_YUYV;=0A=
- break;=0A=
- case VLC_CODEC_UYVY:=0A=
- p_vout->output.i_chroma =3D VLC_CODEC_UYVY;=0A=
- break;=0A=
- case VLC_CODEC_YVYU:=0A=
- p_vout->output.i_chroma =3D VLC_CODEC_YVYU;=0A=
- break;=0A=
- default:=0A=
- p_vout->output.i_chroma =3D VLC_CODEC_YV12;=0A=
- break;=0A=
- }=0A=
+ /* win32 has used UYVY since Windows 98 It should be safe to use*/=0A=
+ p_vout->output.i_chroma =3D VLC_CODEC_UYVY;=0A=
=0A=
NewPictureVec( p_vout, p_vout->p_picture, MAX_DIRECTBUFFERS );=0A=
=0A=
@@ -375,23 +361,7 @@ static int Init( vout_thread_t *p_vout )=0A=
=0A=
if( !I_OUTPUTPICTURES )=0A=
{=0A=
- /* hmmm, it didn't work! Let's try commonly supported chromas */=0A=
- if( p_vout->output.i_chroma !=3D VLC_CODEC_I420 )=0A=
- {=0A=
- p_vout->output.i_chroma =3D VLC_CODEC_YV12;=0A=
- NewPictureVec( p_vout, p_vout->p_picture, MAX_DIRECTBUFFERS =
);=0A=
- }=0A=
- if( !I_OUTPUTPICTURES )=0A=
- {=0A=
- /* hmmm, it still didn't work! Let's try another one */=0A=
- p_vout->output.i_chroma =3D VLC_CODEC_YUYV;=0A=
- NewPictureVec( p_vout, p_vout->p_picture, MAX_DIRECTBUFFERS =
);=0A=
- }=0A=
- }=0A=
-=0A=
- if( !I_OUTPUTPICTURES )=0A=
- {=0A=
- /* If it still didn't work then don't try to use an overlay */=0A=
+ /* If it didn't work then don't try to use an overlay */=0A=
p_vout->output.i_chroma =3D i_chroma_backup;=0A=
p_vout->p_sys->b_using_overlay =3D 0;=0A=
msg_Warn( p_vout, "Could not initialize directx overlay" ) ;=0A=
-- =0A=
1.6.1.2=0A=
=0A=
------=_NextPart_000_0000_01C9F628.8E596DC0--
More information about the vlc-devel
mailing list