Forgot cleanup the code. in Main_setDisplayMode.
[reactos.git] / reactos / lib / ddraw / main / videoport.c
1 /* $Id$
2 *
3 * COPYRIGHT: See COPYING in the top level directory
4 * PROJECT: ReactOS
5 * FILE: lib/ddraw/main/videoport.c
6 * PURPOSE: IDirectDrawVideoPort, DDVideoPortContainer and IDirectDrawVideoPortNotify Implementation
7 * PROGRAMMER: Maarten Bosma
8 *
9 */
10
11 #include "rosdraw.h"
12
13
14 /************* IDirectDrawVideoPort *************/
15
16 HRESULT WINAPI
17 Main_DirectDrawVideoPort_QueryInterface (LPDIRECTDRAWVIDEOPORT iface, REFIID riid, LPVOID* ppvObj)
18 {
19 return E_NOINTERFACE;
20 }
21
22 ULONG WINAPI
23 Main_DirectDrawVideoPort_AddRef (LPDIRECTDRAWVIDEOPORT iface)
24 {
25 return 1;
26 }
27
28 ULONG WINAPI
29 Main_DirectDrawVideoPort_Release (LPDIRECTDRAWVIDEOPORT iface)
30 {
31 return 0;
32 }
33
34 HRESULT WINAPI
35 Main_DirectDrawVideoPort_Flip (LPDIRECTDRAWVIDEOPORT iface, LPDIRECTDRAWSURFACE lpDDSurface, DWORD dwFlags)
36 {
37 DX_STUB;
38 }
39
40 HRESULT WINAPI
41 Main_DirectDrawVideoPort_GetBandwidthInfo (LPDIRECTDRAWVIDEOPORT iface, LPDDPIXELFORMAT lpddpfFormat, DWORD dwWidth,
42 DWORD dwHeight, DWORD dwFlags, LPDDVIDEOPORTBANDWIDTH lpBandwidth)
43 {
44 DX_STUB;
45 }
46
47 HRESULT WINAPI
48 Main_DirectDrawVideoPort_GetColorControls (LPDIRECTDRAWVIDEOPORT iface, LPDDCOLORCONTROL lpColorControl)
49 {
50 DX_STUB;
51 }
52
53 HRESULT WINAPI Main_DirectDrawVideoPort_GetInputFormats (LPDIRECTDRAWVIDEOPORT iface, LPDWORD lpNumFormats,
54 LPDDPIXELFORMAT lpFormats, DWORD dwFlags)
55 {
56 DX_STUB;
57 }
58
59 HRESULT WINAPI Main_DirectDrawVideoPort_GetOutputFormats (LPDIRECTDRAWVIDEOPORT iface, LPDDPIXELFORMAT lpInputFormat,
60 LPDWORD lpNumFormats, LPDDPIXELFORMAT lpFormats, DWORD dwFlags)
61 {
62 DX_STUB;
63 }
64
65 HRESULT WINAPI Main_DirectDrawVideoPort_GetFieldPolarity (LPDIRECTDRAWVIDEOPORT iface, LPBOOL lpbFieldPolarity)
66 {
67 DX_STUB;
68 }
69
70 HRESULT WINAPI Main_DirectDrawVideoPort_GetVideoLine (LPDIRECTDRAWVIDEOPORT This, LPDWORD lpdwLine)
71 {
72 DX_STUB;
73 }
74
75 HRESULT WINAPI Main_DirectDrawVideoPort_GetVideoSignalStatus (LPDIRECTDRAWVIDEOPORT iface, LPDWORD lpdwStatus)
76 {
77 DX_STUB;
78 }
79
80 HRESULT WINAPI Main_DirectDrawVideoPort_SetColorControls (LPDIRECTDRAWVIDEOPORT iface, LPDDCOLORCONTROL lpColorControl)
81 {
82 DX_STUB;
83 }
84
85 HRESULT WINAPI Main_DirectDrawVideoPort_SetTargetSurface (LPDIRECTDRAWVIDEOPORT iface, LPDIRECTDRAWSURFACE lpDDSurface,
86 DWORD dwFlags)
87 {
88 DX_STUB;
89 }
90
91 HRESULT WINAPI Main_DirectDrawVideoPort_StartVideo (LPDIRECTDRAWVIDEOPORT iface, LPDDVIDEOPORTINFO dwFlags)
92 {
93 DX_STUB;
94 }
95
96 HRESULT WINAPI Main_DirectDrawVideoPort_StopVideo (LPDIRECTDRAWVIDEOPORT iface)
97 {
98 DX_STUB;
99 }
100
101 HRESULT WINAPI Main_DirectDrawVideoPort_UpdateVideo (LPDIRECTDRAWVIDEOPORT iface, LPDDVIDEOPORTINFO dwFlags)
102 {
103 DX_STUB;
104 }
105
106 HRESULT WINAPI Main_DirectDrawVideoPort_WaitForSync (LPDIRECTDRAWVIDEOPORT iface, DWORD dwFlags, DWORD dwLine,
107 DWORD dwTimeout)
108 {
109 DX_STUB;
110 }
111
112 /************* IDDVideoPortContainer *************/
113
114 HRESULT WINAPI Main_DDVideoPortContainer_QueryInterface (LPDDVIDEOPORTCONTAINER iface, REFIID riid, LPVOID* ppvObj)
115 {
116 return E_NOINTERFACE;
117 }
118
119 ULONG WINAPI Main_DDVideoPortContainer_AddRef (LPDDVIDEOPORTCONTAINER iface)
120 {
121 return 1;
122 }
123
124 ULONG WINAPI Main_DDVideoPortContainer_Release (LPDDVIDEOPORTCONTAINER iface)
125 {
126 return 0;
127 }
128
129 HRESULT WINAPI Main_DDVideoPortContainer_CreateVideoPort (LPDDVIDEOPORTCONTAINER iface, DWORD dwFlags, LPDDVIDEOPORTDESC pPortDesc,
130 LPDIRECTDRAWVIDEOPORT* DDVideoPort, IUnknown* pUnkOuter)
131 {
132 DX_STUB;
133 }
134
135 HRESULT WINAPI Main_DDVideoPortContainer_EnumVideoPorts (LPDDVIDEOPORTCONTAINER iface, DWORD dwFlags, LPDDVIDEOPORTCAPS pCaps, LPVOID pContext,
136 LPDDENUMVIDEOCALLBACK pEnumVideoCallback)
137 {
138 DX_STUB;
139 }
140
141 HRESULT WINAPI Main_DDVideoPortContainer_GetVideoPortConnectInfo (LPDDVIDEOPORTCONTAINER iface, DWORD PortId, DWORD* pNumEntries,
142 LPDDVIDEOPORTCONNECT pConnectInfo)
143 {
144 DX_STUB;
145 }
146
147 HRESULT WINAPI Main_DDVideoPortContainer_QueryVideoPortStatus (LPDDVIDEOPORTCONTAINER iface, DWORD PortId, LPDDVIDEOPORTSTATUS pStatus)
148 {
149 DX_STUB;
150 }
151
152 /************* IDirectDrawVideoPortNotify *************/
153
154 HRESULT WINAPI Main_DDVideoPortNotify_QueryInterface (LPDIRECTDRAWVIDEOPORTNOTIFY iface, REFIID riid, LPVOID* ppvObj)
155 {
156 return E_NOINTERFACE;
157 }
158
159 ULONG WINAPI Main_DDVideoPortNotify_AddRef (LPDIRECTDRAWVIDEOPORTNOTIFY iface)
160 {
161 return 1;
162 }
163
164 ULONG WINAPI Main_DDVideoPortNotify_Release (LPDIRECTDRAWVIDEOPORTNOTIFY iface)
165 {
166 return 0;
167 }
168
169 HRESULT WINAPI Main_DDVideoPortNotify_AcquireNotification (LPDIRECTDRAWVIDEOPORTNOTIFY iface, HANDLE* h, LPDDVIDEOPORTNOTIFY pVideoPortNotify)
170 {
171 DX_STUB;
172 }
173
174 HRESULT WINAPI Main_DDVideoPortNotify_ReleaseNotification (LPDIRECTDRAWVIDEOPORTNOTIFY iface, HANDLE h)
175 {
176 DX_STUB;
177 }
178
179 IDirectDrawVideoPortVtbl DirectDrawVideoPort_Vtable =
180 {
181 Main_DirectDrawVideoPort_QueryInterface,
182 Main_DirectDrawVideoPort_AddRef,
183 Main_DirectDrawVideoPort_Release,
184 Main_DirectDrawVideoPort_Flip,
185 Main_DirectDrawVideoPort_GetBandwidthInfo,
186 Main_DirectDrawVideoPort_GetColorControls,
187 Main_DirectDrawVideoPort_GetInputFormats,
188 Main_DirectDrawVideoPort_GetOutputFormats,
189 Main_DirectDrawVideoPort_GetFieldPolarity,
190 Main_DirectDrawVideoPort_GetVideoLine,
191 Main_DirectDrawVideoPort_GetVideoSignalStatus,
192 Main_DirectDrawVideoPort_SetColorControls,
193 Main_DirectDrawVideoPort_SetTargetSurface,
194 Main_DirectDrawVideoPort_StartVideo,
195 Main_DirectDrawVideoPort_StopVideo,
196 Main_DirectDrawVideoPort_UpdateVideo,
197 Main_DirectDrawVideoPort_WaitForSync
198 };
199
200 IDDVideoPortContainerVtbl DDVideoPortContainer_Vtable =
201 {
202 Main_DDVideoPortContainer_QueryInterface,
203 Main_DDVideoPortContainer_AddRef,
204 Main_DDVideoPortContainer_Release,
205 Main_DDVideoPortContainer_CreateVideoPort,
206 Main_DDVideoPortContainer_EnumVideoPorts,
207 Main_DDVideoPortContainer_GetVideoPortConnectInfo,
208 Main_DDVideoPortContainer_QueryVideoPortStatus
209 };
210
211 IDirectDrawVideoPortNotifyVtbl DDVideoPortNotify_Vtable =
212 {
213 Main_DDVideoPortNotify_QueryInterface,
214 Main_DDVideoPortNotify_AddRef,
215 Main_DDVideoPortNotify_Release,
216 Main_DDVideoPortNotify_AcquireNotification,
217 Main_DDVideoPortNotify_ReleaseNotification
218 };