1 | /*
|
---|
2 | * Copyright (C) 2002 Lionel Ulmer
|
---|
3 | * Copyright (C) 2004 Alexandre Julliard
|
---|
4 | *
|
---|
5 | * This library is free software; you can redistribute it and/or
|
---|
6 | * modify it under the terms of the GNU Lesser General Public
|
---|
7 | * License as published by the Free Software Foundation; either
|
---|
8 | * version 2.1 of the License, or (at your option) any later version.
|
---|
9 | *
|
---|
10 | * This library is distributed in the hope that it will be useful,
|
---|
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
13 | * Lesser General Public License for more details.
|
---|
14 | *
|
---|
15 | * You should have received a copy of the GNU Lesser General Public
|
---|
16 | * License along with this library; if not, write to the Free Software
|
---|
17 | * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
---|
18 | */
|
---|
19 |
|
---|
20 | /*
|
---|
21 | * Sun LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
|
---|
22 | * other than GPL or LGPL is available it will apply instead, Sun elects to use only
|
---|
23 | * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
|
---|
24 | * a choice of LGPL license versions is made available with the language indicating
|
---|
25 | * that LGPLv2 or any later version may be used, or where a choice of which version
|
---|
26 | * of the LGPL is applied is otherwise unspecified.
|
---|
27 | */
|
---|
28 |
|
---|
29 | import "oaidl.idl";
|
---|
30 |
|
---|
31 | interface IMediaControl;
|
---|
32 | interface IBasicAudio;
|
---|
33 | interface IBasicVideo;
|
---|
34 | interface IVideoWindow;
|
---|
35 | interface IMediaEvent;
|
---|
36 | interface IMediaEventEx;
|
---|
37 | interface IMediaPosition;
|
---|
38 |
|
---|
39 | typedef LONG OAFilterState;
|
---|
40 | typedef LONG_PTR OAHWND;
|
---|
41 | typedef LONG_PTR OAEVENT;
|
---|
42 |
|
---|
43 | cpp_quote("#ifndef REFTIME_DEFINED")
|
---|
44 | cpp_quote("#define REFTIME_DEFINED")
|
---|
45 | typedef DOUBLE REFTIME;
|
---|
46 | cpp_quote("#endif")
|
---|
47 |
|
---|
48 | /*****************************************************************************
|
---|
49 | * IMediaControl interface
|
---|
50 | */
|
---|
51 | [
|
---|
52 | object,
|
---|
53 | uuid(56a868b1-0ad4-11ce-b03a-0020af0ba770),
|
---|
54 | pointer_default(unique)
|
---|
55 | ]
|
---|
56 | interface IMediaControl : IDispatch
|
---|
57 | {
|
---|
58 | HRESULT Run();
|
---|
59 | HRESULT Pause();
|
---|
60 | HRESULT Stop();
|
---|
61 | HRESULT GetState( [in] LONG msTimeout, [out] OAFilterState *pfs );
|
---|
62 | HRESULT RenderFile( [in] BSTR strFilename );
|
---|
63 | HRESULT AddSourceFilter( [in] BSTR strFilename, [out] IDispatch **ppUnk );
|
---|
64 | [propget] HRESULT FilterCollection( [out] IDispatch **ppUnk );
|
---|
65 | [propget] HRESULT RegFilterCollection( [out] IDispatch **ppUnk );
|
---|
66 | HRESULT StopWhenReady();
|
---|
67 | }
|
---|
68 |
|
---|
69 |
|
---|
70 | /*****************************************************************************
|
---|
71 | * IBasicAudio interface
|
---|
72 | */
|
---|
73 | [
|
---|
74 | object,
|
---|
75 | uuid(56a868b3-0ad4-11ce-b03a-0020af0ba770),
|
---|
76 | pointer_default(unique)
|
---|
77 | ]
|
---|
78 | interface IBasicAudio : IDispatch
|
---|
79 | {
|
---|
80 | [propput] HRESULT Volume( [in] LONG lVolume );
|
---|
81 | [propget] HRESULT Volume( [out] LONG *plVolume );
|
---|
82 | [propput] HRESULT Balance( [in] LONG lBalance );
|
---|
83 | [propget] HRESULT Balance( [out] LONG *plBalance );
|
---|
84 | }
|
---|
85 |
|
---|
86 |
|
---|
87 | /*****************************************************************************
|
---|
88 | * IVideoWindow interface
|
---|
89 | */
|
---|
90 | [
|
---|
91 | object,
|
---|
92 | uuid(56a868b4-0ad4-11ce-b03a-0020af0ba770),
|
---|
93 | pointer_default(unique)
|
---|
94 | ]
|
---|
95 | interface IVideoWindow : IDispatch
|
---|
96 | {
|
---|
97 | [propput] HRESULT Caption( [in] BSTR strCaption );
|
---|
98 | [propget] HRESULT Caption( [out] BSTR *strCaption );
|
---|
99 | [propput] HRESULT WindowStyle( [in] LONG WindowStyle );
|
---|
100 | [propget] HRESULT WindowStyle( [out] LONG *WindowStyle );
|
---|
101 | [propput] HRESULT WindowStyleEx( [in] LONG WindowStyleEx );
|
---|
102 | [propget] HRESULT WindowStyleEx( [out] LONG *WindowStyleEx );
|
---|
103 | [propput] HRESULT AutoShow( [in] LONG AutoShow );
|
---|
104 | [propget] HRESULT AutoShow( [out] LONG *AutoShow );
|
---|
105 | [propput] HRESULT WindowState( [in] LONG WindowState );
|
---|
106 | [propget] HRESULT WindowState( [out] LONG *WindowState );
|
---|
107 | [propput] HRESULT BackgroundPalette( [in] LONG BackgroundPalette );
|
---|
108 | [propget] HRESULT BackgroundPalette( [out] LONG *pBackgroundPalette );
|
---|
109 | [propput] HRESULT Visible( [in] LONG Visible );
|
---|
110 | [propget] HRESULT Visible( [out] LONG *pVisible );
|
---|
111 | [propput] HRESULT Left( [in] LONG Left );
|
---|
112 | [propget] HRESULT Left( [out] LONG *pLeft );
|
---|
113 | [propput] HRESULT Width( [in] LONG Width );
|
---|
114 | [propget] HRESULT Width( [out] LONG *pWidth );
|
---|
115 | [propput] HRESULT Top( [in] LONG Top );
|
---|
116 | [propget] HRESULT Top( [out] LONG *pTop );
|
---|
117 | [propput] HRESULT Height( [in] LONG Height );
|
---|
118 | [propget] HRESULT Height( [out] LONG *pHeight );
|
---|
119 | [propput] HRESULT Owner( [in] OAHWND Owner );
|
---|
120 | [propget] HRESULT Owner( [out] OAHWND *Owner );
|
---|
121 | [propput] HRESULT MessageDrain( [in] OAHWND Drain );
|
---|
122 | [propget] HRESULT MessageDrain( [out] OAHWND *Drain );
|
---|
123 | [propget] HRESULT BorderColor( [out] LONG *Color );
|
---|
124 | [propput] HRESULT BorderColor( [in] LONG Color );
|
---|
125 | [propget] HRESULT FullScreenMode( [out] LONG *FullScreenMode );
|
---|
126 | [propput] HRESULT FullScreenMode( [in] LONG FullScreenMode );
|
---|
127 | HRESULT SetWindowForeground( [in] LONG Focus );
|
---|
128 | HRESULT NotifyOwnerMessage( [in] OAHWND hwnd, [in] LONG uMsg, [in] LONG_PTR wParam, [in] LONG_PTR lParam );
|
---|
129 | HRESULT SetWindowPosition( [in] LONG Left, [in] LONG Top, [in] LONG Width, [in] LONG Height );
|
---|
130 | HRESULT GetWindowPosition( [out] LONG *pLeft, [out] LONG *pTop, [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
131 | HRESULT GetMinIdealImageSize( [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
132 | HRESULT GetMaxIdealImageSize( [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
133 | HRESULT GetRestorePosition( [out] LONG *pLeft, [out] LONG *pTop, [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
134 | HRESULT HideCursor( [in] LONG HideCursor );
|
---|
135 | HRESULT IsCursorHidden( [out] LONG *CursorHidden );
|
---|
136 | }
|
---|
137 |
|
---|
138 |
|
---|
139 | /*****************************************************************************
|
---|
140 | * IBasicVideo interface
|
---|
141 | */
|
---|
142 | [
|
---|
143 | object,
|
---|
144 | uuid(56a868b5-0ad4-11ce-b03a-0020af0ba770),
|
---|
145 | pointer_default(unique)
|
---|
146 | ]
|
---|
147 | interface IBasicVideo : IDispatch
|
---|
148 | {
|
---|
149 | [propget] HRESULT AvgTimePerFrame( [out] REFTIME *pAvgTimePerFrame );
|
---|
150 | [propget] HRESULT BitRate( [out] LONG *pBitRate );
|
---|
151 | [propget] HRESULT BitErrorRate( [out] LONG *pBitErrorRate );
|
---|
152 | [propget] HRESULT VideoWidth( [out] LONG *pVideoWidth );
|
---|
153 | [propget] HRESULT VideoHeight( [out] LONG *pVideoHeight );
|
---|
154 | [propput] HRESULT SourceLeft( [in] LONG SourceLeft );
|
---|
155 | [propget] HRESULT SourceLeft( [out] LONG *pSourceLeft );
|
---|
156 | [propput] HRESULT SourceWidth( [in] LONG SourceWidth );
|
---|
157 | [propget] HRESULT SourceWidth( [out] LONG *pSourceWidth );
|
---|
158 | [propput] HRESULT SourceTop( [in] LONG SourceTop );
|
---|
159 | [propget] HRESULT SourceTop( [out] LONG *pSourceTop );
|
---|
160 | [propput] HRESULT SourceHeight( [in] LONG SourceHeight );
|
---|
161 | [propget] HRESULT SourceHeight( [out] LONG *pSourceHeight );
|
---|
162 | [propput] HRESULT DestinationLeft( [in] LONG DestinationLeft );
|
---|
163 | [propget] HRESULT DestinationLeft( [out] LONG *pDestinationLeft );
|
---|
164 | [propput] HRESULT DestinationWidth( [in] LONG DestinationWidth );
|
---|
165 | [propget] HRESULT DestinationWidth( [out] LONG *pDestinationWidth );
|
---|
166 | [propput] HRESULT DestinationTop( [in] LONG DestinationTop );
|
---|
167 | [propget] HRESULT DestinationTop( [out] LONG *pDestinationTop );
|
---|
168 | [propput] HRESULT DestinationHeight( [in] LONG DestinationHeight );
|
---|
169 | [propget] HRESULT DestinationHeight( [out] LONG *pDestinationHeight );
|
---|
170 | HRESULT SetSourcePosition( [in] LONG Left, [in] LONG Top, [in] LONG Width, [in] LONG Height );
|
---|
171 | HRESULT GetSourcePosition( [out] LONG *pLeft, [out] LONG *pTop, [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
172 | HRESULT SetDefaultSourcePosition();
|
---|
173 | HRESULT SetDestinationPosition( [in] LONG Left, [in] LONG Top, [in] LONG Width, [in] LONG Height );
|
---|
174 | HRESULT GetDestinationPosition( [out] LONG *pLeft, [out] LONG *pTop, [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
175 | HRESULT SetDefaultDestinationPosition();
|
---|
176 | HRESULT GetVideoSize( [out] LONG *pWidth, [out] LONG *pHeight );
|
---|
177 | HRESULT GetVideoPaletteEntries( [in] LONG StartIndex,
|
---|
178 | [in] LONG Entries,
|
---|
179 | [out] LONG *pRetrieved,
|
---|
180 | [out, size_is(Entries), length_is(*pRetrieved)] LONG *pPalette );
|
---|
181 | HRESULT GetCurrentImage( [in, out] LONG *pBufferSize,
|
---|
182 | [out, size_is(*pBufferSize), length_is(*pBufferSize)] LONG *pDIBImage );
|
---|
183 | HRESULT IsUsingDefaultSource();
|
---|
184 | HRESULT IsUsingDefaultDestination();
|
---|
185 | }
|
---|
186 |
|
---|
187 | [
|
---|
188 | uuid(329bb360-f6ea-11d1-9038-00a0c9697298),
|
---|
189 | helpstring("IBasicVideo2"),
|
---|
190 | odl
|
---|
191 | ]
|
---|
192 |
|
---|
193 | interface IBasicVideo2 : IBasicVideo
|
---|
194 | {
|
---|
195 | HRESULT GetPreferredAspectRatio([out] LONG *plAspectX, [out] LONG *plAspectY);
|
---|
196 | }
|
---|
197 |
|
---|
198 |
|
---|
199 | /*****************************************************************************
|
---|
200 | * IMediaEvent interface
|
---|
201 | */
|
---|
202 | [
|
---|
203 | object,
|
---|
204 | uuid(56a868b6-0ad4-11ce-b03a-0020af0ba770),
|
---|
205 | pointer_default(unique)
|
---|
206 | ]
|
---|
207 | interface IMediaEvent : IDispatch
|
---|
208 | {
|
---|
209 | HRESULT GetEventHandle( [out] OAEVENT *hEvent );
|
---|
210 | HRESULT GetEvent( [out] LONG *lEventCode, [out] LONG_PTR *lParam1, [out] LONG_PTR *lParam2, [in] LONG msTimeout );
|
---|
211 | HRESULT WaitForCompletion( [in] LONG msTimeout, [out] LONG *pEvCode );
|
---|
212 | HRESULT CancelDefaultHandling( [in] LONG lEvCode );
|
---|
213 | HRESULT RestoreDefaultHandling( [in] LONG lEvCode );
|
---|
214 | HRESULT FreeEventParams( [in] LONG lEvCode, [in] LONG_PTR lParam1, [in] LONG_PTR lParam2 );
|
---|
215 | }
|
---|
216 |
|
---|
217 |
|
---|
218 | /*****************************************************************************
|
---|
219 | * IMediaEventEx interface
|
---|
220 | */
|
---|
221 | [
|
---|
222 | object,
|
---|
223 | uuid(56a868c0-0ad4-11ce-b03a-0020af0ba770),
|
---|
224 | pointer_default(unique)
|
---|
225 | ]
|
---|
226 | interface IMediaEventEx : IMediaEvent
|
---|
227 | {
|
---|
228 | HRESULT SetNotifyWindow( [in] OAHWND hwnd, [in] LONG lMsg, [in] LONG_PTR lInstanceData );
|
---|
229 | HRESULT SetNotifyFlags( [in] LONG lNoNotifyFlags );
|
---|
230 | HRESULT GetNotifyFlags( [out] LONG *lplNoNotifyFlags );
|
---|
231 | }
|
---|
232 |
|
---|
233 |
|
---|
234 | /*****************************************************************************
|
---|
235 | * IMediaPosition interface
|
---|
236 | */
|
---|
237 | [
|
---|
238 | object,
|
---|
239 | uuid(56a868b2-0ad4-11ce-b03a-0020af0ba770),
|
---|
240 | pointer_default(unique)
|
---|
241 | ]
|
---|
242 | interface IMediaPosition : IDispatch
|
---|
243 | {
|
---|
244 | HRESULT get_Duration( [out] REFTIME *plength );
|
---|
245 | HRESULT put_CurrentPosition( [in] REFTIME llTime );
|
---|
246 | HRESULT get_CurrentPosition( [out] REFTIME *pllTime );
|
---|
247 | HRESULT get_StopTime( [out] REFTIME *pllTime );
|
---|
248 | HRESULT put_StopTime( [in] REFTIME llTime );
|
---|
249 | HRESULT get_PrerollTime( [out] REFTIME *pllTime );
|
---|
250 | HRESULT put_PrerollTime( [in] REFTIME llTime );
|
---|
251 | HRESULT put_Rate( [in] double dRate );
|
---|
252 | HRESULT get_Rate( [out] double *pdRate );
|
---|
253 | HRESULT CanSeekForward( [out] LONG *pCanSeekForward );
|
---|
254 | HRESULT CanSeekBackward( [out] LONG *pCanSeekBackward );
|
---|
255 | }
|
---|