Add pgs color type setting
[xy_vsfilter.git] / include / realmedia / rmacomm.h
blobc9f2ed1205a75ddc2886906d0f291663aec4b2c2
1 /****************************************************************************
2 *
3 * $Id: rmacomm.h 7 2003-05-30 02:18:02Z gabest $
5 * Copyright (C) 1995-1999 RealNetworks, Inc. All rights reserved.
6 *
7 * http://www.real.com/devzone
9 * This program contains proprietary
10 * information of Progressive Networks, Inc, and is licensed
11 * subject to restrictions on use and distribution.
14 * RealMedia Architecture Common Utility interfaces
18 #ifndef _RMACOMM_H_
19 #define _RMACOMM_H_
21 #include "rmaengin.h" // For RMATimeval
24 * Forward declarations of some interfaces defined here-in.
27 typedef _INTERFACE IRMACommonClassFactory IRMACommonClassFactory;
28 typedef _INTERFACE IRMAStatistics IRMAStatistics;
29 typedef _INTERFACE IRMARegistryID IRMARegistryID;
30 typedef _INTERFACE IRMAServerFork IRMAServerFork;
31 typedef _INTERFACE IRMAServerControl IRMAServerControl;
32 typedef _INTERFACE IRMAReconfigServerResponse IRMAReconfigServerResponse;
33 typedef _INTERFACE IRMABuffer IRMABuffer;
34 typedef _INTERFACE IRMAWantServerReconfigNotification
35 IRMAWantServerReconfigNotification;
36 typedef _INTERFACE IRMAFastAlloc IRMAFastAlloc;
40 /****************************************************************************
42 * Interface:
44 * IRMACommonClassFactory
46 * Purpose:
48 * RMA interface that manages the creation of common RMA classes.
50 * IID_IRMACommonClassFactory:
52 * {00000000-0901-11d1-8B06-00A024406D59}
55 DEFINE_GUID(IID_IRMACommonClassFactory, 0x00000000, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
56 0xa0, 0x24, 0x40, 0x6d, 0x59);
58 #undef INTERFACE
59 #define INTERFACE IRMACommonClassFactory
61 DECLARE_INTERFACE_(IRMACommonClassFactory, IUnknown)
64 * IUnknown methods
66 STDMETHOD(QueryInterface) (THIS_
67 REFIID riid,
68 void** ppvObj) PURE;
70 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
72 STDMETHOD_(ULONG,Release) (THIS) PURE;
75 * IRMACommonClassFactory methods
78 /************************************************************************
79 * Method:
80 * IRMACommonClassFactory::CreateInstance
81 * Purpose:
82 * Creates instances of common objects supported by the system,
83 * like IRMABuffer, IRMAPacket, IRMAValues, etc.
85 * This method is similar to Window's CoCreateInstance() in its
86 * purpose, except that it only creates objects of a well known
87 * types.
89 * NOTE: Aggregation is never used. Therefore and outer unknown is
90 * not passed to this function, and you do not need to code for this
91 * situation.
93 STDMETHOD(CreateInstance) (THIS_
94 REFCLSID /*IN*/ rclsid,
95 void** /*OUT*/ ppUnknown) PURE;
97 /************************************************************************
98 * Method:
99 * IRMAController::CreateInstanceAggregatable
100 * Purpose:
101 * Creates instances of common objects that can be aggregated
102 * supported by the system, like IRMASiteWindowed
104 * This method is similar to Window's CoCreateInstance() in its
105 * purpose, except that it only creates objects of a well known
106 * types.
108 * NOTE 1: Unlike CreateInstance, this method will create internal
109 * objects that support Aggregation.
111 * NOTE 2: The output interface is always the non-delegating
112 * IUnknown.
114 STDMETHOD(CreateInstanceAggregatable)
115 (THIS_
116 REFCLSID /*IN*/ rclsid,
117 REF(IUnknown*) /*OUT*/ ppUnknown,
118 IUnknown* /*IN*/ pUnkOuter) PURE;
122 /****************************************************************************
124 * Interface:
126 * IRMAStatistics
128 * Purpose:
130 * This interface allows update of the client statistics.
132 * IID_IRMAStatistics:
134 * {00000001-0901-11d1-8B06-00A024406D59}
137 DEFINE_GUID(IID_IRMAStatistics, 0x00000001, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
138 0xa0, 0x24, 0x40, 0x6d, 0x59);
140 #undef INTERFACE
141 #define INTERFACE IRMAStatistics
143 DECLARE_INTERFACE_(IRMAStatistics, IUnknown)
146 * IUnknown methods
148 STDMETHOD(QueryInterface) (THIS_
149 REFIID riid,
150 void** ppvObj) PURE;
152 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
154 STDMETHOD_(ULONG,Release) (THIS) PURE;
157 * IRMAStatistics methods
160 /************************************************************************
161 * Method:
162 * IRMAStatistics::Init
163 * Purpose:
164 * Pass registry ID to the caller
167 STDMETHOD(InitializeStatistics) (THIS_
168 UINT32 /*IN*/ ulRegistryID) PURE;
170 /************************************************************************
171 * Method:
172 * IRMAStatistics::Update
173 * Purpose:
174 * Notify the client to update its statistics stored in the registry
177 STDMETHOD(UpdateStatistics) (THIS) PURE;
181 /****************************************************************************
183 * Interface:
185 * IRMARegistryID
187 * Purpose:
189 * This interface is implemented by IRMAPlayer, IRMAStreamSource,
190 * and IRMAStream. It allows the user to get the registry Base ID,
191 * for an object that you have a pointer to.
193 * IID_IRMARegistryID:
195 * {00000002-0901-11d1-8B06-00A024406D59}
198 DEFINE_GUID(IID_IRMARegistryID, 0x00000002, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
199 0xa0, 0x24, 0x40, 0x6d, 0x59);
201 #undef INTERFACE
202 #define INTERFACE IRMARegistryID
204 DECLARE_INTERFACE_(IRMARegistryID, IUnknown)
207 * IUnknown methods
209 STDMETHOD(QueryInterface) (THIS_
210 REFIID riid,
211 void** ppvObj) PURE;
213 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
215 STDMETHOD_(ULONG,Release) (THIS) PURE;
218 * IRMARegistryID methods
221 /************************************************************************
222 * Method:
223 * IRMARegistryID::GetID
224 * Purpose:
225 * Get the registry ID of the object.
228 STDMETHOD(GetID) (THIS_
229 REF(UINT32) /*OUT*/ ulRegistryID) PURE;
232 /****************************************************************************
234 * Interface:
236 * IRMAServerFork
238 * Purpose:
240 * This interface is implemented by the server context on Unix
241 * platforms. This interface allows your plugin to fork off a
242 * process. Note that the process that is forked off cannot use
243 * any RMA APIs. The fork() system call is prohibited from within
244 * a RMA plugin.
246 * IID_IRMAServerFork:
248 * {00000003-0901-11d1-8B06-00A024406D59}
251 DEFINE_GUID(IID_IRMAServerFork, 0x00000003, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
252 0xa0, 0x24, 0x40, 0x6d, 0x59);
254 #undef INTERFACE
255 #define INTERFACE IRMAServerFork
257 DECLARE_INTERFACE_(IRMAServerFork, IUnknown)
260 * IUnknown methods
262 STDMETHOD(QueryInterface) (THIS_
263 REFIID riid,
264 void** ppvObj) PURE;
266 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
268 STDMETHOD_(ULONG,Release) (THIS) PURE;
271 * IRMAServerFork methods
274 /************************************************************************
275 * Method:
276 * IRMAServerFork::Fork
277 * Purpose:
278 * Fork off a child process. The child process cannot use any RMA
279 * APIs. Upon successful completion, Fork returns 0 to the child
280 * process and the PID of the child to the parent. A return value
281 * of -1 indicates an error.
283 * Note: The child process should *NOT* Release any interfaces.
284 * The cleanup of the IRMAServerFork() interface and other
285 * RMA interfaces is done by the parent.
288 STDMETHOD_(INT32, Fork) (THIS) PURE;
293 * Interface:
295 * IRMAServerControl
297 * Purpose:
299 * This inteface provides access to the RealMedia server's controls
300 * for shutting down (for now).
302 * Note: This registry is not related to the Windows system registry.
304 * IID_IRMAServerControl:
306 * {00000004-0901-11d1-8B06-00A024406D59}
309 DEFINE_GUID(IID_IRMAServerControl, 0x00000004, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
310 0xa0, 0x24, 0x40, 0x6d, 0x59);
312 #define CLSID_IRMAServerControl IID_IRMAServerControl
314 #undef INTERFACE
315 #define INTERFACE IRMAServerControl
317 DECLARE_INTERFACE_(IRMAServerControl, IUnknown)
320 * IUnknown methods
322 STDMETHOD(QueryInterface) (THIS_
323 REFIID riid,
324 void** ppvObj) PURE;
326 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
328 STDMETHOD_(ULONG,Release) (THIS) PURE;
331 * IRMAServerControl methods
334 /************************************************************************
335 * Method:
336 * IRMAServerControl::ShutdownServer
337 * Purpose:
338 * Shutdown the server.
340 STDMETHOD(ShutdownServer) (THIS_
341 UINT32 status) PURE;
346 * Interface:
348 * IRMAServerControl2
350 * Purpose:
352 * Interface for extended server control methods.
355 * IID_IRMAServerControl2:
357 * {00000005-0901-11d1-8B06-00A024406D59}
360 DEFINE_GUID(IID_IRMAServerControl2, 0x00000005, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
361 0xa0, 0x24, 0x40, 0x6d, 0x59);
364 #undef INTERFACE
365 #define INTERFACE IRMAServerControl2
367 DECLARE_INTERFACE_(IRMAServerControl2, IUnknown)
370 * IUnknown methods
372 STDMETHOD(QueryInterface) (THIS_
373 REFIID riid,
374 void** ppvObj) PURE;
376 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
378 STDMETHOD_(ULONG,Release) (THIS) PURE;
381 * IRMAServerControl2 methods
384 /************************************************************************
385 * IRMAServerControl2::RestartServer
387 * Purpose:
389 * Completely shutdown the server, then restart. Mainly used to
390 * cause not hot setting config var changes to take effect.
392 STDMETHOD(RestartServer) (THIS) PURE;
394 /************************************************************************
395 * IRMAServerControl2::ReconfigServer
397 * Purpose:
399 * Used to cause the server to re-read in config from file or registry
400 * (however it was started) and attempt to use the values.
402 STDMETHOD(ReconfigServer) (THIS_ IRMAReconfigServerResponse* pResp) PURE;
408 * Interface:
410 * IRMAReconfigServerResponse
412 * Purpose:
414 * Response interface for IRMAServerControl2::ReconfigServer
417 * IID_IRMAReconfigServerResponse:
419 * {00000006-0901-11d1-8B06-00A024406D59}
422 DEFINE_GUID(IID_IRMAReconfigServerResponse, 0x00000006, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
423 0xa0, 0x24, 0x40, 0x6d, 0x59);
426 #undef INTERFACE
427 #define INTERFACE IRMAReconfigServerResponse
429 DECLARE_INTERFACE_(IRMAReconfigServerResponse, IUnknown)
432 * IUnknown methods
434 STDMETHOD(QueryInterface) (THIS_
435 REFIID riid,
436 void** ppvObj) PURE;
438 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
440 STDMETHOD_(ULONG,Release) (THIS) PURE;
442 /************************************************************************
443 * IRMAReconfigServerResponse::ReconfigServerDone
445 * Purpose:
447 * Notification that reconfiguring the server is done.
449 STDMETHOD(ReconfigServerDone) (THIS_
450 PN_RESULT res,
451 IRMABuffer** pInfo,
452 UINT32 ulNumInfo) PURE;
457 * Interface:
459 * IRMAServerReconfigNotification
461 * Purpose:
463 * Register with the server that you want notification when a reconfig
464 * request comes in and want/need to take part in the reconfiguration. This
465 * is used when you have configuration info outside the server config file
466 * which needs to be re-initialized.
469 * IID_IRMAServerReconfigNotification:
471 * {00000007-0901-11d1-8B06-00A024406D59}
474 DEFINE_GUID(IID_IRMAServerReconfigNotification, 0x00000007, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
475 0xa0, 0x24, 0x40, 0x6d, 0x59);
478 #undef INTERFACE
479 #define INTERFACE IRMAServerReconfigNotification
481 DECLARE_INTERFACE_(IRMAServerReconfigNotification, IUnknown)
484 * IUnknown methods
486 STDMETHOD(QueryInterface) (THIS_
487 REFIID riid,
488 void** ppvObj) PURE;
490 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
492 STDMETHOD_(ULONG,Release) (THIS) PURE;
494 /************************************************************************
495 * IRMAServerReconfigNotification::WantReconfigNotification
497 * Purpose:
499 * Tell the server that you want reconfig notification.
501 STDMETHOD(WantReconfigNotification) (THIS_
502 IRMAWantServerReconfigNotification* pResponse) PURE;
504 /************************************************************************
505 * IRMAServerReconfigNotification::CancelReconfigNotification
507 * Purpose:
509 * Tell the server that you no longer want reconfig notification.
511 STDMETHOD(CancelReconfigNotification) (THIS_
512 IRMAWantServerReconfigNotification* pResponse) PURE;
518 * Interface:
520 * IRMAWantServerReconfigNotification
522 * Purpose:
524 * Tell user that the server got a reconfig request and it is time to
525 * do your reconfiguration. NOTE: You should not need this if all of your
526 * configuration is stored in the config file; that is taken care of through
527 * IRMAActiveRegistry.
529 * IID_IRMAWantServerReconfigNotification:
531 * {00000008-0901-11d1-8B06-00A024406D59}
534 DEFINE_GUID(IID_IRMAWantServerReconfigNotification, 0x00000008, 0x901, 0x11d1, 0x8b, 0x6, 0x0,
535 0xa0, 0x24, 0x40, 0x6d, 0x59);
538 #undef INTERFACE
539 #define INTERFACE IRMAWantServerReconfigNotification
541 DECLARE_INTERFACE_(IRMAWantServerReconfigNotification, IUnknown)
544 * IUnknown methods
546 STDMETHOD(QueryInterface) (THIS_
547 REFIID riid,
548 void** ppvObj) PURE;
550 STDMETHOD_(ULONG,AddRef) (THIS) PURE;
552 STDMETHOD_(ULONG,Release) (THIS) PURE;
554 /************************************************************************
555 * IRMAWantServerReconfigNotification::ServerReconfig
557 * Purpose:
559 * Notify user that a server reconfig request had come in and it
560 * is now your turn to do external (not server config) reconfiguration.*
562 STDMETHOD(ServerReconfig) (THIS_
563 IRMAReconfigServerResponse* pResponse) PURE;
568 #endif /*_RMACOMM_H_*/