1 /*****************************************************************************
2 * vout_directx.h: Windows DirectX video output header file
3 *****************************************************************************
4 * Copyright (C) 1998, 1999, 2000 VideoLAN
5 * $Id: vout_directx.h,v 1.7 2002/06/01 12:31:58 sam Exp $
7 * Authors: Gildas Bazin <gbazin@netcourrier.com>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
22 *****************************************************************************/
24 /*****************************************************************************
25 * vout_sys_t: video output DirectX method descriptor
26 *****************************************************************************
27 * This structure is part of the video output thread descriptor.
28 * It describes the DirectX specific properties of an output thread.
29 *****************************************************************************/
33 LPDIRECTDRAW2 p_ddobject; /* DirectDraw object */
34 LPDIRECTDRAWSURFACE3 p_display; /* Display device */
35 LPDIRECTDRAWSURFACE3 p_current_surface; /* surface currently displayed */
36 LPDIRECTDRAWCLIPPER p_clipper; /* clipper used for blitting */
37 HINSTANCE hddraw_dll; /* handle of the opened ddraw dll */
38 HBRUSH hbrush; /* window backgound brush (color) */
39 HWND hwnd; /* Handle of the main window */
41 vlc_bool_t b_using_overlay; /* Are we using an overlay surface */
42 vlc_bool_t b_use_sysmem; /* Should we use system memory for surfaces */
43 vlc_bool_t b_hw_yuv; /* Should we use hardware YUV->RGB conversions */
45 /* size of the display */
49 /* Window position and size */
55 /* Coordinates of src and dest images (used when blitting to display) */
57 RECT rect_src_clipped;
59 RECT rect_dest_clipped;
61 /* DDraw capabilities */
62 int b_caps_overlay_clipping;
64 int i_rgb_colorkey; /* colorkey in RGB used by the overlay */
65 int i_colorkey; /* colorkey used by the overlay */
67 volatile u16 i_changes; /* changes made to the video display */
70 volatile vlc_bool_t b_cursor_hidden;
71 volatile mtime_t i_lastmoved;
73 vlc_thread_t event_thread_id; /* event thread */
74 vlc_mutex_t event_thread_lock; /* lock for the event thread */
75 vlc_cond_t event_thread_wait;
77 volatile int i_event_thread_status; /* DirectXEventThread status */
78 volatile vlc_bool_t b_event_thread_die; /* flag to kill the event thread */
81 /*****************************************************************************
82 * picture_sys_t: direct buffer method descriptor
83 *****************************************************************************
84 * This structure is part of the picture descriptor, it describes the
85 * DirectX specific properties of a direct buffer.
86 *****************************************************************************/
89 LPDIRECTDRAWSURFACE3 p_surface;
91 LPDIRECTDRAWSURFACE3 p_front_surface;
94 /*****************************************************************************
95 * Prototypes from vout_directx.c
96 *****************************************************************************/
98 /*****************************************************************************
99 * Prototypes from vout_events.c
100 *****************************************************************************/
101 void DirectXEventThread ( vout_thread_t *p_vout );
102 void DirectXUpdateOverlay( vout_thread_t *p_vout );
104 /*****************************************************************************
106 *****************************************************************************/
107 #define WM_VLC_HIDE_MOUSE WM_APP