static void InitBuffers ( vout_thread_t * );
-#ifdef MODULE_NAME_IS_wingapi
-# define GXOpenDisplay p_vout->p_sys->GXOpenDisplay
-# define GXCloseDisplay p_vout->p_sys->GXCloseDisplay
-# define GXBeginDraw p_vout->p_sys->GXBeginDraw
-# define GXEndDraw p_vout->p_sys->GXEndDraw
-# define GXGetDisplayProperties p_vout->p_sys->GXGetDisplayProperties
-# define GXSuspend p_vout->p_sys->GXSuspend
-# define GXResume p_vout->p_sys->GXResume
-#endif
+
#define DX_POSITION_CHANGE 0x1000
/*****************************************************************************
* Module descriptor
*****************************************************************************/
-vlc_module_begin();
- set_category( CAT_VIDEO );
- set_subcategory( SUBCAT_VIDEO_VOUT );
+vlc_module_begin ()
+ set_category( CAT_VIDEO )
+ set_subcategory( SUBCAT_VIDEO_VOUT )
#ifdef MODULE_NAME_IS_wingapi
- set_shortname( "Windows GAPI" );
- set_description( N_("Windows GAPI video output") );
- set_capability( "video output", 20 );
+ set_shortname( "Windows GAPI" )
+ set_description( N_("Windows GAPI video output") )
+ set_capability( "video output", 20 )
#else
- set_shortname( "Windows GDI" );
- set_description( N_("Windows GDI video output") );
- set_capability( "video output", 10 );
+ set_shortname( "Windows GDI" )
+ set_description( N_("Windows GDI video output") )
+ set_capability( "video output", 10 )
#endif
- set_callbacks( OpenVideo, CloseVideo );
-vlc_module_end();
+ set_callbacks( OpenVideo, CloseVideo )
+vlc_module_end ()
/*****************************************************************************
* OpenVideo: activate GDI video thread output method
p_vout->p_sys->p_event =
vlc_object_create( p_vout, sizeof(event_thread_t) );
p_vout->p_sys->p_event->p_vout = p_vout;
- if( vlc_thread_create( p_vout->p_sys->p_event, "VLC Vout Events Thread",
- EventThread, 0, 1 ) )
+ p_vout->p_sys->p_event->ready = CreateEvent( NULL, TRUE, FALSE, NULL );
+ if( vlc_thread_create( p_vout->p_sys->p_event, "Vout Events Thread",
+ EventThread, 0, false ) )
{
msg_Err( p_vout, "cannot create Vout EventThread" );
+ CloseHandle( p_vout->p_sys->p_event->ready );
vlc_object_release( p_vout->p_sys->p_event );
p_vout->p_sys->p_event = NULL;
goto error;
}
+ WaitForSingleObject( p_vout->p_sys->p_event->ready, INFINITE )
+ CloseHandle( p_vout->p_sys->p_event->ready );
if( p_vout->p_sys->p_event->b_error )
{
if( p_vout->b_fullscreen )
{
- Win32ToggleFullscreen( p_vout );
msg_Dbg( p_vout, "Quitting fullscreen" );
+ Win32ToggleFullscreen( p_vout );
+ /* Force fullscreen in the core for the next video */
+ var_SetBool( p_vout, "fullscreen", true );
}
if( p_vout->p_sys->p_event )