Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

333 lines
12 KiB

  1. //*****************************************************************************
  2. //
  3. // Microsoft Windows Media
  4. // Copyright (C) Microsoft Corporation. All rights reserved.
  5. //
  6. // FileName: wmsdatapath.idl
  7. //
  8. // Abstract:
  9. //
  10. //*****************************************************************************
  11. cpp_quote("//*****************************************************************************")
  12. cpp_quote("//")
  13. cpp_quote("// Microsoft Windows Media")
  14. cpp_quote("// Copyright (C) Microsoft Corporation. All rights reserved.")
  15. cpp_quote("//")
  16. cpp_quote("// Automatically generated by Midl from wmsdatapath.idl" )
  17. cpp_quote("//")
  18. cpp_quote("// DO NOT EDIT THIS FILE.")
  19. cpp_quote("//")
  20. cpp_quote("//*****************************************************************************")
  21. import "objidl.idl";
  22. import "nsscore.idl";
  23. import "DataContainer.idl";
  24. import "StreamDescription.idl";
  25. import "WMSPacket.idl";
  26. interface IWMSPacketStreamer;
  27. interface IWMSPacketStreamerCallback;
  28. interface IWMSPushSource;
  29. interface IWMSPushSourceCallback;
  30. interface IWMSPushSink;
  31. interface IWMSPacketStreamDataContainer;
  32. cpp_quote( "EXTERN_GUID( IID_IWMSPacketStreamer, 0x72527A81,0x1119,0x11d2,0x9E,0xEE,0x00,0x60,0x97,0xD2,0xD7,0xCF );" )
  33. cpp_quote( "EXTERN_GUID( IID_IWMSPacketStreamerCallback, 0x72527A82,0x1119,0x11d2,0x9E,0xEE,0x00,0x60,0x97,0xD2,0xD7,0xCF );" )
  34. cpp_quote( "EXTERN_GUID( IID_IWMSPushSource, 0x0B840593,0x115C,0x11d2,0x9E,0xEE,0x00,0x60,0x97,0xD2,0xD7,0xCF );" )
  35. cpp_quote( "EXTERN_GUID( IID_IWMSPushSourceCallback, 0xead035e4, 0xbe4a, 0x4a7a, 0xbc, 0x19, 0x5b, 0xb, 0x9e, 0x9, 0xd7, 0x4c );" )
  36. cpp_quote( "EXTERN_GUID( IID_IWMSPushSink, 0x0B840594,0x115C,0x11d2,0x9E,0xEE,0x00,0x60,0x97,0xD2,0xD7,0xCF );" )
  37. cpp_quote( "EXTERN_GUID( IID_IWMSPacketStreamDataContainer, 0xb1b6039, 0x572c, 0x11d2, 0x9e, 0xff, 0x0, 0x60, 0x97, 0xd2, 0xd7, 0xcf );" )
  38. ///////////////////////////////////////////////////////////////////////////////
  39. // These are the options for a seek and play command that are passed in
  40. // the command context to the play command.
  41. typedef [public] enum WMS_SEEK_AND_PLAY_TYPE
  42. {
  43. WMSPlayFromCurrentPosition,
  44. WMSSeekToIFrameAndPlay,
  45. WMSSeekToPositionAndPlay,
  46. } WMS_SEEK_AND_PLAY_TYPE;
  47. // These are the flags passed to a seek command.
  48. cpp_quote("#define WMS_SEEK_TO_IFRAME 0x0001")
  49. //////////////////////////////////////////////////////////////////////////////
  50. //
  51. // GENERIC PACKET STREAMER
  52. //
  53. //////////////////////////////////////////////////////////////////////////////
  54. [
  55. object,
  56. pointer_default(unique),
  57. uuid(72527A81-1119-11d2-9EEE-006097D2D7CF),
  58. version(9.0),
  59. helpstring("Contains methods for retrieving information on streams being sent down a data path and for controlling the streams being sent down a data path.")
  60. ]
  61. interface IWMSPacketStreamer : IUnknown
  62. {
  63. // This is called every time a source changes. This is called once
  64. // for a simple movie file, and called every time a server-side
  65. // playlist changes its output.
  66. [helpstring("Retrieves header information on streams that are being sent down the data path.")] HRESULT
  67. GetStreamInfo(
  68. [in] IWMSPacketStreamerCallback *pCallback,
  69. [in] QWORD qwContext
  70. );
  71. // A parser will be smart about waiting until the next
  72. // iframe before sending data from a newly selected stream.
  73. [helpstring("Specifies the streams that are sent down the data path.")] HRESULT
  74. SelectStream(
  75. [in] IWMSCommandContext *pCommand,
  76. [in] IWMSStreamSwitchDescriptionList *pStreamSwitchDescList,
  77. [in] IWMSPacketStreamerCallback *pCallback,
  78. [in] QWORD qwContext
  79. );
  80. // This affects all selected streams. It returns the min seek
  81. // point of all selected streams.
  82. // When the parser seeks to a point, it returns all frames
  83. // after and including the first iframe of the stream. This
  84. // lets us ignore pframes that are after the common seek point
  85. // but before the next iframe.
  86. [helpstring("Seeks to a specific offset in a multimedia stream.")] HRESULT
  87. Seek(
  88. [in] IWMSCommandContext *pCommand,
  89. [in] DWORD dwOffsetType,
  90. [in] QWORD qwOffset,
  91. [in] DWORD dwFlags,
  92. [in] IWMSPacketStreamerCallback *pCallback,
  93. [in] QWORD qwContext
  94. );
  95. [helpstring("Reserved for future use.")] HRESULT
  96. ChangeStreamFormat(
  97. [in] IWMSCommandContext *pCommand,
  98. [in] IWMSPacketStreamerCallback *pCallback,
  99. [in] QWORD qwContext
  100. );
  101. [helpstring("Reserved for future use.")] HRESULT
  102. Interrupt(
  103. [in] IWMSCommandContext *pCommand,
  104. [in] DWORD dwOptions,
  105. [in] IWMSPacketStreamerCallback *pCallback,
  106. [in] QWORD qwContext
  107. );
  108. // Extended Commands
  109. [helpstring("Passes extended commands defined by a plug-in up the data path.")] HRESULT
  110. DoExtendedCommand(
  111. [in] LPWSTR szCommandName,
  112. [in] IWMSCommandContext *pCommand,
  113. [in] IWMSPacketStreamerCallback *pCallback,
  114. [in] QWORD qwContext
  115. );
  116. // This releases internal references, possibly breaking
  117. // cyclic references.
  118. [helpstring("Called by the server when the data path is being shut down.")] HRESULT
  119. Shutdown();
  120. };
  121. //////////////////////////////////////////////////////////////////////////////
  122. //////////////////////////////////////////////////////////////////////////////
  123. [
  124. object,
  125. pointer_default(unique),
  126. uuid(72527A82-1119-11d2-9EEE-006097D2D7CF),
  127. version(9.0),
  128. helpstring("Contains methods that enable a plug-in to respond to IWMSPacketStreamer method calls.")
  129. ]
  130. interface IWMSPacketStreamerCallback : IUnknown
  131. {
  132. [helpstring("Called by the plug-in to respond to the IWMSPacketStreamer::GetStreamInfo method call.")] HRESULT
  133. OnGetStreamInfo(
  134. [in] HRESULT hr,
  135. [in] IWMSStreamHeaderList *pHeaderList,
  136. [in] IWMSContentDescriptionList *pContentDescription,
  137. [in] QWORD qwContext
  138. );
  139. [helpstring("Called by the plug-in to respond to the IWMSPacketStreamer::Seek method call.")] HRESULT
  140. OnSeek(
  141. [in] HRESULT hr,
  142. [in] QWORD qwActualPosition,
  143. [in] QWORD qwContext
  144. );
  145. [helpstring("Called by the plug-in to respond to the IWMSPacketStreamer::SelectStream method call.")] HRESULT
  146. OnSelectStream(
  147. [in] HRESULT hr,
  148. [in] QWORD qwContext
  149. );
  150. [helpstring("Reserved for future use.")] HRESULT
  151. OnChangeStreamFormat(
  152. [in] HRESULT hr,
  153. [in] QWORD qwContext
  154. );
  155. [helpstring("Reserved for future use.")] HRESULT
  156. OnInterrupt(
  157. [in] HRESULT hr,
  158. [in] QWORD qwContext
  159. );
  160. [helpstring("Called by the plug-in to respond to the IWMSPacketStreamer::DoExtendedCommand method call.")] HRESULT
  161. OnDoExtendedCommand(
  162. [in] HRESULT hr,
  163. [in] QWORD qwContext
  164. );
  165. };
  166. //////////////////////////////////////////////////////////////////////////////
  167. //
  168. // PACKET STREAM DATA CONTAINER
  169. //
  170. // Each live source will implement a storage system that allocates data
  171. // containers. Those data containers will implement IWMSPacketStreamer
  172. // and IWMSPacketStreamDataContainer in addition to IWMSDataContainer.
  173. //////////////////////////////////////////////////////////////////////////////
  174. //////////////////////////////////////////////////////////////////////////////
  175. [
  176. object,
  177. pointer_default(unique),
  178. uuid(0B1B6039-572C-11d2-9EFF-006097D2D7CF),
  179. version(9.0),
  180. helpstring("Contains methods to notify the server of stream signals and to determine the maximum packet size used by a data container.")
  181. ]
  182. interface IWMSPacketStreamDataContainer : IUnknown
  183. {
  184. [helpstring("Called by the server to indicate that it should be notified of stream signals.")] HRESULT
  185. SetStreamSignalHandler(
  186. [in] IWMSStreamSignalHandler *pStreamSignalHandler
  187. );
  188. [helpstring("Retrieves the maximum packet size, in bytes, that is used by the data container.")] HRESULT
  189. GetMaxPacketSize( [out] DWORD *pdwMaxPacketSize );
  190. }
  191. //////////////////////////////////////////////////////////////////////////////
  192. //
  193. // PACKET PUSH INTERFACES
  194. //
  195. //////////////////////////////////////////////////////////////////////////////
  196. //////////////////////////////////////////////////////////////////////////////
  197. [
  198. object,
  199. pointer_default(unique),
  200. uuid(0B840593-115C-11d2-9EEE-006097D2D7CF),
  201. version(9.0),
  202. helpstring("Contains methods that control the flow of data through a data path.")
  203. ]
  204. interface IWMSPushSource : IUnknown
  205. {
  206. [helpstring("Reserved for future use.")] HRESULT
  207. ConnectSink( [in] IWMSPushSink *pDataOutput );
  208. [helpstring("Reserved for future use.")] HRESULT
  209. DisconnectSink();
  210. // Call start each time you change the rate (ie, play to
  211. // fast-forward). A negative rate is rewind.
  212. [helpstring("Starts the flow of packets down a data path.")] HRESULT
  213. StartPushing(
  214. [in] IWMSCommandContext *pCommand,
  215. [in] double dblRate,
  216. [in] IWMSPushSourceCallback *pCallback,
  217. [in] QWORD qwContext
  218. );
  219. [helpstring("Stops the flow of packets down a data path.")] HRESULT
  220. StopPushing(
  221. [in] IWMSCommandContext *pCommand,
  222. [in] IWMSPushSourceCallback *pCallback,
  223. [in] QWORD qwContext
  224. );
  225. // This may or may not be implemented differently than StopPushing.
  226. [helpstring("Pauses the flow of packets down a data path.")] HRESULT
  227. PausePushing(
  228. [in] IWMSCommandContext *pCommand,
  229. [in] IWMSPushSourceCallback *pCallback,
  230. [in] QWORD qwContext
  231. );
  232. [helpstring("Passes UDP resend requests up the data path.")] HRESULT
  233. ResendPacket(
  234. [in] IWMSCommandContext *pCommand,
  235. [in] DWORD dwPacketNum,
  236. [in] DWORD dwStreamNum
  237. );
  238. };
  239. //////////////////////////////////////////////////////////////////////////////
  240. [
  241. object,
  242. pointer_default(unique),
  243. uuid(EAD035E4-BE4A-4a7a-BC19-5B0B9E09D74C),
  244. version(9.0),
  245. helpstring("Contains methods that enable a plug-in to respond to IWMSPushSource method calls.")
  246. ]
  247. interface IWMSPushSourceCallback : IUnknown
  248. {
  249. [helpstring("Called by the plug-in to respond to the IWMSPushSource::StartPushing method call.")] HRESULT
  250. OnStartPushing(
  251. [in] HRESULT hr,
  252. [in] QWORD qwContext
  253. );
  254. [helpstring("Called by the plug-in to respond to the IWMSPushSource::StopPushing method call.")] HRESULT
  255. OnStopPushing(
  256. [in] HRESULT hr,
  257. [in] QWORD qwContext
  258. );
  259. [helpstring("Called by the plug-in to respond to the IWMSPushSource::PausePushing method call.")] HRESULT
  260. OnPausePushing(
  261. [in] HRESULT hr,
  262. [in] QWORD qwContext
  263. );
  264. };
  265. //////////////////////////////////////////////////////////////////////////////
  266. [
  267. object,
  268. pointer_default(unique),
  269. uuid(0B840594-115C-11d2-9EEE-006097D2D7CF),
  270. version(9.0),
  271. helpstring("Contains a method to request that a data path component process a packet list.")
  272. ]
  273. interface IWMSPushSink : IUnknown
  274. {
  275. [helpstring("Reserved for future use.")] HRESULT
  276. ConnectSource( [in] IWMSPushSource *pDataInput );
  277. [helpstring("Reserved for future use.")] HRESULT
  278. DisconnectSource();
  279. // The main method for moving data through the server.
  280. [helpstring("Requests that a data path component process a packet list.")] HRESULT
  281. ProcessPackets( [in] IWMSPacketList *pPacketList );
  282. };