Counter Strike : Global Offensive Source Code
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.

5159 lines
226 KiB

  1. /*++
  2. Copyright (c) Microsoft Corporation. All rights reserved.
  3. Module Name:
  4. ksmedia.h
  5. Abstract:
  6. WDM-CSA Multimedia Definitions.
  7. --*/
  8. #if !defined(_KS_)
  9. #error KS.H must be included before KSMEDIA.H
  10. #endif // !defined(_KS_)
  11. #if !defined(_KSMEDIA_)
  12. #define _KSMEDIA_
  13. typedef struct {
  14. KSPROPERTY Property;
  15. KSMULTIPLE_ITEM MultipleItem;
  16. } KSMULTIPLE_DATA_PROP, *PKSMULTIPLE_DATA_PROP;
  17. #define STATIC_KSMEDIUMSETID_MidiBus \
  18. 0x05908040L, 0x3246, 0x11D0, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  19. DEFINE_GUIDSTRUCT("05908040-3246-11D0-A5D6-28DB04C10000", KSMEDIUMSETID_MidiBus);
  20. #define KSMEDIUMSETID_MidiBus DEFINE_GUIDNAMED(KSMEDIUMSETID_MidiBus)
  21. #define STATIC_KSMEDIUMSETID_VPBus \
  22. 0xA18C15ECL, 0xCE43, 0x11D0, 0xAB, 0xE7, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  23. DEFINE_GUIDSTRUCT("A18C15EC-CE43-11D0-ABE7-00A0C9223196", KSMEDIUMSETID_VPBus);
  24. #define KSMEDIUMSETID_VPBus DEFINE_GUIDNAMED(KSMEDIUMSETID_VPBus)
  25. #define STATIC_KSINTERFACESETID_Media \
  26. 0x3A13EB40L, 0x30A7, 0x11D0, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  27. DEFINE_GUIDSTRUCT("3A13EB40-30A7-11D0-A5D6-28DB04C10000", KSINTERFACESETID_Media);
  28. #define KSINTERFACESETID_Media DEFINE_GUIDNAMED(KSINTERFACESETID_Media)
  29. typedef enum {
  30. KSINTERFACE_MEDIA_MUSIC,
  31. KSINTERFACE_MEDIA_WAVE_BUFFERED,
  32. KSINTERFACE_MEDIA_WAVE_QUEUED
  33. } KSINTERFACE_MEDIA;
  34. #if !defined(INIT_USBAUDIO_MID)
  35. // {4e1cecd2-1679-463b-a72f-a5bf64c86eba}
  36. #define INIT_USBAUDIO_MID(guid, id)\
  37. {\
  38. (guid)->Data1 = 0x4e1cecd2 + (USHORT)(id);\
  39. (guid)->Data2 = 0x1679;\
  40. (guid)->Data3 = 0x463b;\
  41. (guid)->Data4[0] = 0xa7;\
  42. (guid)->Data4[1] = 0x2f;\
  43. (guid)->Data4[2] = 0xa5;\
  44. (guid)->Data4[3] = 0xbf;\
  45. (guid)->Data4[4] = 0x64;\
  46. (guid)->Data4[5] = 0xc8;\
  47. (guid)->Data4[6] = 0x6e;\
  48. (guid)->Data4[7] = 0xba;\
  49. }
  50. #define EXTRACT_USBAUDIO_MID(guid)\
  51. (USHORT)((guid)->Data1 - 0x4e1cecd2)
  52. #define DEFINE_USBAUDIO_MID_GUID(id)\
  53. 0x4e1cecd2+(USHORT)(id), 0x1679, 0x463b, 0xa7, 0x2f, 0xa5, 0xbf, 0x64, 0xc8, 0x6e, 0xba
  54. #define IS_COMPATIBLE_USBAUDIO_MID(guid)\
  55. (((guid)->Data1 >= 0x4e1cecd2) &&\
  56. ((guid)->Data1 < 0x4e1cecd2 + 0xffff) &&\
  57. ((guid)->Data2 == 0x1679) &&\
  58. ((guid)->Data3 == 0x463b) &&\
  59. ((guid)->Data4[0] == 0xa7) &&\
  60. ((guid)->Data4[1] == 0x2f) &&\
  61. ((guid)->Data4[2] == 0xa5) &&\
  62. ((guid)->Data4[3] == 0xbf) &&\
  63. ((guid)->Data4[4] == 0x64) &&\
  64. ((guid)->Data4[5] == 0xc8) &&\
  65. ((guid)->Data4[6] == 0x6e) &&\
  66. ((guid)->Data4[7] == 0xba))
  67. #endif // !defined(INIT_USBAUDIO_MID)
  68. #if !defined(INIT_USBAUDIO_PID)
  69. // {abcc5a5e-c263-463b-a72f-a5bf64c86eba}
  70. #define INIT_USBAUDIO_PID(guid, id)\
  71. {\
  72. (guid)->Data1 = 0xabcc5a5e + (USHORT)(id);\
  73. (guid)->Data2 = 0xc263;\
  74. (guid)->Data3 = 0x463b;\
  75. (guid)->Data4[0] = 0xa7;\
  76. (guid)->Data4[1] = 0x2f;\
  77. (guid)->Data4[2] = 0xa5;\
  78. (guid)->Data4[3] = 0xbf;\
  79. (guid)->Data4[4] = 0x64;\
  80. (guid)->Data4[5] = 0xc8;\
  81. (guid)->Data4[6] = 0x6e;\
  82. (guid)->Data4[7] = 0xba;\
  83. }
  84. #define EXTRACT_USBAUDIO_PID(guid)\
  85. (USHORT)((guid)->Data1 - 0xabcc5a5e)
  86. #define DEFINE_USBAUDIO_PID_GUID(id)\
  87. 0xabcc5a5e+(USHORT)(id), 0xc263, 0x463b, 0xa7, 0x2f, 0xa5, 0xbf, 0x64, 0xc8, 0x6e, 0xba
  88. #define IS_COMPATIBLE_USBAUDIO_PID(guid)\
  89. (((guid)->Data1 >= 0xabcc5a5e) &&\
  90. ((guid)->Data1 < 0xabcc5a5e + 0xffff) &&\
  91. ((guid)->Data2 == 0xc263) &&\
  92. ((guid)->Data3 == 0x463b) &&\
  93. ((guid)->Data4[0] == 0xa7) &&\
  94. ((guid)->Data4[1] == 0x2f) &&\
  95. ((guid)->Data4[2] == 0xa5) &&\
  96. ((guid)->Data4[3] == 0xbf) &&\
  97. ((guid)->Data4[4] == 0x64) &&\
  98. ((guid)->Data4[5] == 0xc8) &&\
  99. ((guid)->Data4[6] == 0x6e) &&\
  100. ((guid)->Data4[7] == 0xba))
  101. #endif // !defined(INIT_USBAUDIO_PID)
  102. #if !defined(INIT_USBAUDIO_PRODUCT_NAME)
  103. // {FC575048-2E08-463B-A72F-A5BF64C86EBA}
  104. #define INIT_USBAUDIO_PRODUCT_NAME(guid, vid, pid, strIndex)\
  105. {\
  106. (guid)->Data1 = 0XFC575048 + (USHORT)(vid);\
  107. (guid)->Data2 = 0x2E08 + (USHORT)(pid);\
  108. (guid)->Data3 = 0x463B + (USHORT)(strIndex);\
  109. (guid)->Data4[0] = 0xA7;\
  110. (guid)->Data4[1] = 0x2F;\
  111. (guid)->Data4[2] = 0xA5;\
  112. (guid)->Data4[3] = 0xBF;\
  113. (guid)->Data4[4] = 0x64;\
  114. (guid)->Data4[5] = 0xC8;\
  115. (guid)->Data4[6] = 0x6E;\
  116. (guid)->Data4[7] = 0xBA;\
  117. }
  118. #define DEFINE_USBAUDIO_PRODUCT_NAME(vid, pid, strIndex)\
  119. 0xFC575048+(USHORT)(vid), 0x2E08+(USHORT)(pid), 0x463B+(USHORT)(strIndex), 0xA7, 0x2F, 0xA5, 0xBF, 0x64, 0xC8, 0x6E, 0xBA
  120. #endif // !defined(INIT_USBAUDIO_PRODUCT_NAME)
  121. // USB Component ID
  122. #define STATIC_KSCOMPONENTID_USBAUDIO \
  123. 0x8F1275F0, 0x26E9, 0x4264, 0xBA, 0x4D, 0x39, 0xFF, 0xF0, 0x1D, 0x94, 0xAA
  124. DEFINE_GUIDSTRUCT("8F1275F0-26E9-4264-BA4D-39FFF01D94AA", KSCOMPONENTID_USBAUDIO);
  125. #define KSCOMPONENTID_USBAUDIO DEFINE_GUIDNAMED(KSCOMPONENTID_USBAUDIO)
  126. // USB Terminals
  127. #define INIT_USB_TERMINAL(guid, id)\
  128. {\
  129. (guid)->Data1 = 0xDFF219E0 + (USHORT)(id);\
  130. (guid)->Data2 = 0xF70F;\
  131. (guid)->Data3 = 0x11D0;\
  132. (guid)->Data4[0] = 0xb9;\
  133. (guid)->Data4[1] = 0x17;\
  134. (guid)->Data4[2] = 0x00;\
  135. (guid)->Data4[3] = 0xa0;\
  136. (guid)->Data4[4] = 0xc9;\
  137. (guid)->Data4[5] = 0x22;\
  138. (guid)->Data4[6] = 0x31;\
  139. (guid)->Data4[7] = 0x96;\
  140. }
  141. #define EXTRACT_USB_TERMINAL(guid)\
  142. (USHORT)((guid)->Data1 - 0xDFF219E0)
  143. #define DEFINE_USB_TERMINAL_GUID(id)\
  144. 0xDFF219E0+(USHORT)(id), 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  145. #define STATIC_KSNODETYPE_MICROPHONE\
  146. DEFINE_USB_TERMINAL_GUID(0x0201)
  147. DEFINE_GUIDSTRUCT("DFF21BE1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_MICROPHONE);
  148. #define KSNODETYPE_MICROPHONE DEFINE_GUIDNAMED(KSNODETYPE_MICROPHONE)
  149. #define STATIC_KSNODETYPE_DESKTOP_MICROPHONE\
  150. DEFINE_USB_TERMINAL_GUID(0x0202)
  151. DEFINE_GUIDSTRUCT("DFF21BE2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DESKTOP_MICROPHONE);
  152. #define KSNODETYPE_DESKTOP_MICROPHONE DEFINE_GUIDNAMED(KSNODETYPE_DESKTOP_MICROPHONE)
  153. #define STATIC_KSNODETYPE_PERSONAL_MICROPHONE\
  154. DEFINE_USB_TERMINAL_GUID(0x0203)
  155. DEFINE_GUIDSTRUCT("DFF21BE3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_PERSONAL_MICROPHONE);
  156. #define KSNODETYPE_PERSONAL_MICROPHONE DEFINE_GUIDNAMED(KSNODETYPE_PERSONAL_MICROPHONE)
  157. #define STATIC_KSNODETYPE_OMNI_DIRECTIONAL_MICROPHONE\
  158. DEFINE_USB_TERMINAL_GUID(0x0204)
  159. DEFINE_GUIDSTRUCT("DFF21BE4-F70F-11D0-B917-00A0C9223196", KSNODETYPE_OMNI_DIRECTIONAL_MICROPHONE);
  160. #define KSNODETYPE_OMNI_DIRECTIONAL_MICROPHONE DEFINE_GUIDNAMED(KSNODETYPE_OMNI_DIRECTIONAL_MICROPHONE)
  161. #define STATIC_KSNODETYPE_MICROPHONE_ARRAY\
  162. DEFINE_USB_TERMINAL_GUID(0x0205)
  163. DEFINE_GUIDSTRUCT("DFF21BE5-F70F-11D0-B917-00A0C9223196", KSNODETYPE_MICROPHONE_ARRAY);
  164. #define KSNODETYPE_MICROPHONE_ARRAY DEFINE_GUIDNAMED(KSNODETYPE_MICROPHONE_ARRAY)
  165. #define STATIC_KSNODETYPE_PROCESSING_MICROPHONE_ARRAY\
  166. DEFINE_USB_TERMINAL_GUID(0x0206)
  167. DEFINE_GUIDSTRUCT("DFF21BE6-F70F-11D0-B917-00A0C9223196", KSNODETYPE_PROCESSING_MICROPHONE_ARRAY);
  168. #define KSNODETYPE_PROCESSING_MICROPHONE_ARRAY DEFINE_GUIDNAMED(KSNODETYPE_PROCESSING_MICROPHONE_ARRAY)
  169. #define STATIC_KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR \
  170. 0x830a44f2, 0xa32d, 0x476b, 0xbe, 0x97, 0x42, 0x84, 0x56, 0x73, 0xb3, 0x5a
  171. DEFINE_GUIDSTRUCT("830a44f2-a32d-476b-be97-42845673b35a", KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR);
  172. #define KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR DEFINE_GUIDNAMED(KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR)
  173. #define STATIC_KSNODETYPE_SPEAKER\
  174. DEFINE_USB_TERMINAL_GUID(0x0301)
  175. DEFINE_GUIDSTRUCT("DFF21CE1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_SPEAKER);
  176. #define KSNODETYPE_SPEAKER DEFINE_GUIDNAMED(KSNODETYPE_SPEAKER)
  177. #define STATIC_KSNODETYPE_HEADPHONES\
  178. DEFINE_USB_TERMINAL_GUID(0x0302)
  179. DEFINE_GUIDSTRUCT("DFF21CE2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_HEADPHONES);
  180. #define KSNODETYPE_HEADPHONES DEFINE_GUIDNAMED(KSNODETYPE_HEADPHONES)
  181. #define STATIC_KSNODETYPE_HEAD_MOUNTED_DISPLAY_AUDIO\
  182. DEFINE_USB_TERMINAL_GUID(0x0303)
  183. DEFINE_GUIDSTRUCT("DFF21CE3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_HEAD_MOUNTED_DISPLAY_AUDIO);
  184. #define KSNODETYPE_HEAD_MOUNTED_DISPLAY_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_HEAD_MOUNTED_DISPLAY_AUDIO)
  185. #define STATIC_KSNODETYPE_DESKTOP_SPEAKER\
  186. DEFINE_USB_TERMINAL_GUID(0x0304)
  187. DEFINE_GUIDSTRUCT("DFF21CE4-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DESKTOP_SPEAKER);
  188. #define KSNODETYPE_DESKTOP_SPEAKER DEFINE_GUIDNAMED(KSNODETYPE_DESKTOP_SPEAKER)
  189. #define STATIC_KSNODETYPE_ROOM_SPEAKER\
  190. DEFINE_USB_TERMINAL_GUID(0x0305)
  191. DEFINE_GUIDSTRUCT("DFF21CE5-F70F-11D0-B917-00A0C9223196", KSNODETYPE_ROOM_SPEAKER);
  192. #define KSNODETYPE_ROOM_SPEAKER DEFINE_GUIDNAMED(KSNODETYPE_ROOM_SPEAKER)
  193. #define STATIC_KSNODETYPE_COMMUNICATION_SPEAKER\
  194. DEFINE_USB_TERMINAL_GUID(0x0306)
  195. DEFINE_GUIDSTRUCT("DFF21CE6-F70F-11D0-B917-00A0C9223196", KSNODETYPE_COMMUNICATION_SPEAKER);
  196. #define KSNODETYPE_COMMUNICATION_SPEAKER DEFINE_GUIDNAMED(KSNODETYPE_COMMUNICATION_SPEAKER)
  197. #define STATIC_KSNODETYPE_LOW_FREQUENCY_EFFECTS_SPEAKER\
  198. DEFINE_USB_TERMINAL_GUID(0x0307)
  199. DEFINE_GUIDSTRUCT("DFF21CE7-F70F-11D0-B917-00A0C9223196", KSNODETYPE_LOW_FREQUENCY_EFFECTS_SPEAKER);
  200. #define KSNODETYPE_LOW_FREQUENCY_EFFECTS_SPEAKER DEFINE_GUIDNAMED(KSNODETYPE_LOW_FREQUENCY_EFFECTS_SPEAKER)
  201. #define STATIC_KSNODETYPE_HANDSET\
  202. DEFINE_USB_TERMINAL_GUID(0x0401)
  203. DEFINE_GUIDSTRUCT("DFF21DE1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_HANDSET);
  204. #define KSNODETYPE_HANDSET DEFINE_GUIDNAMED(KSNODETYPE_HANDSET)
  205. #define STATIC_KSNODETYPE_HEADSET\
  206. DEFINE_USB_TERMINAL_GUID(0x0402)
  207. DEFINE_GUIDSTRUCT("DFF21DE2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_HEADSET);
  208. #define KSNODETYPE_HEADSET DEFINE_GUIDNAMED(KSNODETYPE_HEADSET)
  209. #define STATIC_KSNODETYPE_SPEAKERPHONE_NO_ECHO_REDUCTION\
  210. DEFINE_USB_TERMINAL_GUID(0x0403)
  211. DEFINE_GUIDSTRUCT("DFF21DE3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_SPEAKERPHONE_NO_ECHO_REDUCTION);
  212. #define KSNODETYPE_SPEAKERPHONE_NO_ECHO_REDUCTION DEFINE_GUIDNAMED(KSNODETYPE_SPEAKERPHONE_NO_ECHO_REDUCTION)
  213. #define STATIC_KSNODETYPE_ECHO_SUPPRESSING_SPEAKERPHONE\
  214. DEFINE_USB_TERMINAL_GUID(0x0404)
  215. DEFINE_GUIDSTRUCT("DFF21DE4-F70F-11D0-B917-00A0C9223196", KSNODETYPE_ECHO_SUPPRESSING_SPEAKERPHONE);
  216. #define KSNODETYPE_ECHO_SUPPRESSING_SPEAKERPHONE DEFINE_GUIDNAMED(KSNODETYPE_ECHO_SUPPRESSING_SPEAKERPHONE)
  217. #define STATIC_KSNODETYPE_ECHO_CANCELING_SPEAKERPHONE\
  218. DEFINE_USB_TERMINAL_GUID(0x0405)
  219. DEFINE_GUIDSTRUCT("DFF21DE5-F70F-11D0-B917-00A0C9223196", KSNODETYPE_ECHO_CANCELING_SPEAKERPHONE);
  220. #define KSNODETYPE_ECHO_CANCELING_SPEAKERPHONE DEFINE_GUIDNAMED(KSNODETYPE_ECHO_CANCELING_SPEAKERPHONE)
  221. #define STATIC_KSNODETYPE_PHONE_LINE\
  222. DEFINE_USB_TERMINAL_GUID(0x0501)
  223. DEFINE_GUIDSTRUCT("DFF21EE1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_PHONE_LINE);
  224. #define KSNODETYPE_PHONE_LINE DEFINE_GUIDNAMED(KSNODETYPE_PHONE_LINE)
  225. #define STATIC_KSNODETYPE_TELEPHONE\
  226. DEFINE_USB_TERMINAL_GUID(0x0502)
  227. DEFINE_GUIDSTRUCT("DFF21EE2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_TELEPHONE);
  228. #define KSNODETYPE_TELEPHONE DEFINE_GUIDNAMED(KSNODETYPE_TELEPHONE)
  229. #define STATIC_KSNODETYPE_DOWN_LINE_PHONE\
  230. DEFINE_USB_TERMINAL_GUID(0x0503)
  231. DEFINE_GUIDSTRUCT("DFF21EE3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DOWN_LINE_PHONE);
  232. #define KSNODETYPE_DOWN_LINE_PHONE DEFINE_GUIDNAMED(KSNODETYPE_DOWN_LINE_PHONE)
  233. #define STATIC_KSNODETYPE_ANALOG_CONNECTOR\
  234. DEFINE_USB_TERMINAL_GUID(0x601)
  235. DEFINE_GUIDSTRUCT("DFF21FE1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_ANALOG_CONNECTOR);
  236. #define KSNODETYPE_ANALOG_CONNECTOR DEFINE_GUIDNAMED(KSNODETYPE_ANALOG_CONNECTOR)
  237. #define STATIC_KSNODETYPE_DIGITAL_AUDIO_INTERFACE\
  238. DEFINE_USB_TERMINAL_GUID(0x0602)
  239. DEFINE_GUIDSTRUCT("DFF21FE2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DIGITAL_AUDIO_INTERFACE);
  240. #define KSNODETYPE_DIGITAL_AUDIO_INTERFACE DEFINE_GUIDNAMED(KSNODETYPE_DIGITAL_AUDIO_INTERFACE)
  241. #define STATIC_KSNODETYPE_LINE_CONNECTOR\
  242. DEFINE_USB_TERMINAL_GUID(0x0603)
  243. DEFINE_GUIDSTRUCT("DFF21FE3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_LINE_CONNECTOR);
  244. #define KSNODETYPE_LINE_CONNECTOR DEFINE_GUIDNAMED(KSNODETYPE_LINE_CONNECTOR)
  245. #define STATIC_KSNODETYPE_LEGACY_AUDIO_CONNECTOR\
  246. DEFINE_USB_TERMINAL_GUID(0x0604)
  247. DEFINE_GUIDSTRUCT("DFF21FE4-F70F-11D0-B917-00A0C9223196", KSNODETYPE_LEGACY_AUDIO_CONNECTOR);
  248. #define KSNODETYPE_LEGACY_AUDIO_CONNECTOR DEFINE_GUIDNAMED(KSNODETYPE_LEGACY_AUDIO_CONNECTOR)
  249. #define STATIC_KSNODETYPE_SPDIF_INTERFACE\
  250. DEFINE_USB_TERMINAL_GUID(0x0605)
  251. DEFINE_GUIDSTRUCT("DFF21FE5-F70F-11D0-B917-00A0C9223196", KSNODETYPE_SPDIF_INTERFACE);
  252. #define KSNODETYPE_SPDIF_INTERFACE DEFINE_GUIDNAMED(KSNODETYPE_SPDIF_INTERFACE)
  253. #define STATIC_KSNODETYPE_1394_DA_STREAM\
  254. DEFINE_USB_TERMINAL_GUID(0x0606)
  255. DEFINE_GUIDSTRUCT("DFF21FE6-F70F-11D0-B917-00A0C9223196", KSNODETYPE_1394_DA_STREAM);
  256. #define KSNODETYPE_1394_DA_STREAM DEFINE_GUIDNAMED(KSNODETYPE_1394_DA_STREAM)
  257. #define STATIC_KSNODETYPE_1394_DV_STREAM_SOUNDTRACK\
  258. DEFINE_USB_TERMINAL_GUID(0x0607)
  259. DEFINE_GUIDSTRUCT("DFF21FE7-F70F-11D0-B917-00A0C9223196", KSNODETYPE_1394_DV_STREAM_SOUNDTRACK);
  260. #define KSNODETYPE_1394_DV_STREAM_SOUNDTRACK DEFINE_GUIDNAMED(KSNODETYPE_1394_DV_STREAM_SOUNDTRACK)
  261. #define STATIC_KSNODETYPE_LEVEL_CALIBRATION_NOISE_SOURCE\
  262. DEFINE_USB_TERMINAL_GUID(0x0701)
  263. DEFINE_GUIDSTRUCT("DFF220E1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_LEVEL_CALIBRATION_NOISE_SOURCE);
  264. #define KSNODETYPE_LEVEL_CALIBRATION_NOISE_SOURCE DEFINE_GUIDNAMED(KSNODETYPE_LEVEL_CALIBRATION_NOISE_SOURCE)
  265. #define STATIC_KSNODETYPE_EQUALIZATION_NOISE\
  266. DEFINE_USB_TERMINAL_GUID(0x0702)
  267. DEFINE_GUIDSTRUCT("DFF220E2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_EQUALIZATION_NOISE);
  268. #define KSNODETYPE_EQUALIZATION_NOISE DEFINE_GUIDNAMED(KSNODETYPE_EQUALIZATION_NOISE)
  269. #define STATIC_KSNODETYPE_CD_PLAYER\
  270. DEFINE_USB_TERMINAL_GUID(0x0703)
  271. DEFINE_GUIDSTRUCT("DFF220E3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_CD_PLAYER);
  272. #define KSNODETYPE_CD_PLAYER DEFINE_GUIDNAMED(KSNODETYPE_CD_PLAYER)
  273. #define STATIC_KSNODETYPE_DAT_IO_DIGITAL_AUDIO_TAPE\
  274. DEFINE_USB_TERMINAL_GUID(0x0704)
  275. DEFINE_GUIDSTRUCT("DFF220E4-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DAT_IO_DIGITAL_AUDIO_TAPE);
  276. #define KSNODETYPE_DAT_IO_DIGITAL_AUDIO_TAPE DEFINE_GUIDNAMED(KSNODETYPE_DAT_IO_DIGITAL_AUDIO_TAPE)
  277. #define STATIC_KSNODETYPE_DCC_IO_DIGITAL_COMPACT_CASSETTE\
  278. DEFINE_USB_TERMINAL_GUID(0x0705)
  279. DEFINE_GUIDSTRUCT("DFF220E5-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DCC_IO_DIGITAL_COMPACT_CASSETTE);
  280. #define KSNODETYPE_DCC_IO_DIGITAL_COMPACT_CASSETTE DEFINE_GUIDNAMED(KSNODETYPE_DCC_IO_DIGITAL_COMPACT_CASSETTE)
  281. #define STATIC_KSNODETYPE_MINIDISK\
  282. DEFINE_USB_TERMINAL_GUID(0x0706)
  283. DEFINE_GUIDSTRUCT("DFF220E6-F70F-11D0-B917-00A0C9223196", KSNODETYPE_MINIDISK);
  284. #define KSNODETYPE_MINIDISK DEFINE_GUIDNAMED(KSNODETYPE_MINIDISK)
  285. #define STATIC_KSNODETYPE_ANALOG_TAPE\
  286. DEFINE_USB_TERMINAL_GUID(0x0707)
  287. DEFINE_GUIDSTRUCT("DFF220E7-F70F-11D0-B917-00A0C9223196", KSNODETYPE_ANALOG_TAPE);
  288. #define KSNODETYPE_ANALOG_TAPE DEFINE_GUIDNAMED(KSNODETYPE_ANALOG_TAPE)
  289. #define STATIC_KSNODETYPE_PHONOGRAPH\
  290. DEFINE_USB_TERMINAL_GUID(0x0708)
  291. DEFINE_GUIDSTRUCT("DFF220E8-F70F-11D0-B917-00A0C9223196", KSNODETYPE_PHONOGRAPH);
  292. #define KSNODETYPE_PHONOGRAPH DEFINE_GUIDNAMED(KSNODETYPE_PHONOGRAPH)
  293. #define STATIC_KSNODETYPE_VCR_AUDIO\
  294. DEFINE_USB_TERMINAL_GUID(0x0708)
  295. DEFINE_GUIDSTRUCT("DFF220E9-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VCR_AUDIO);
  296. #define KSNODETYPE_VCR_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_VCR_AUDIO)
  297. #define STATIC_KSNODETYPE_VIDEO_DISC_AUDIO\
  298. DEFINE_USB_TERMINAL_GUID(0x070A)
  299. DEFINE_GUIDSTRUCT("DFF220EA-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_DISC_AUDIO);
  300. #define KSNODETYPE_VIDEO_DISC_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_DISC_AUDIO)
  301. #define STATIC_KSNODETYPE_DVD_AUDIO\
  302. DEFINE_USB_TERMINAL_GUID(0x070B)
  303. DEFINE_GUIDSTRUCT("DFF220EB-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DVD_AUDIO);
  304. #define KSNODETYPE_DVD_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_DVD_AUDIO)
  305. #define STATIC_KSNODETYPE_TV_TUNER_AUDIO\
  306. DEFINE_USB_TERMINAL_GUID(0x070C)
  307. DEFINE_GUIDSTRUCT("DFF220EC-F70F-11D0-B917-00A0C9223196", KSNODETYPE_TV_TUNER_AUDIO);
  308. #define KSNODETYPE_TV_TUNER_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_TV_TUNER_AUDIO)
  309. #define STATIC_KSNODETYPE_SATELLITE_RECEIVER_AUDIO\
  310. DEFINE_USB_TERMINAL_GUID(0x070D)
  311. DEFINE_GUIDSTRUCT("DFF220ED-F70F-11D0-B917-00A0C9223196", KSNODETYPE_SATELLITE_RECEIVER_AUDIO);
  312. #define KSNODETYPE_SATELLITE_RECEIVER_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_SATELLITE_RECEIVER_AUDIO)
  313. #define STATIC_KSNODETYPE_CABLE_TUNER_AUDIO\
  314. DEFINE_USB_TERMINAL_GUID(0x070E)
  315. DEFINE_GUIDSTRUCT("DFF220EE-F70F-11D0-B917-00A0C9223196", KSNODETYPE_CABLE_TUNER_AUDIO);
  316. #define KSNODETYPE_CABLE_TUNER_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_CABLE_TUNER_AUDIO)
  317. #define STATIC_KSNODETYPE_DSS_AUDIO\
  318. DEFINE_USB_TERMINAL_GUID(0x070F)
  319. DEFINE_GUIDSTRUCT("DFF220EF-F70F-11D0-B917-00A0C9223196", KSNODETYPE_DSS_AUDIO);
  320. #define KSNODETYPE_DSS_AUDIO DEFINE_GUIDNAMED(KSNODETYPE_DSS_AUDIO)
  321. #define STATIC_KSNODETYPE_RADIO_RECEIVER\
  322. DEFINE_USB_TERMINAL_GUID(0x0710)
  323. DEFINE_GUIDSTRUCT("DFF220F0-F70F-11D0-B917-00A0C9223196", KSNODETYPE_RADIO_RECEIVER);
  324. #define KSNODETYPE_RADIO_RECEIVER DEFINE_GUIDNAMED(KSNODETYPE_RADIO_RECEIVER)
  325. #define STATIC_KSNODETYPE_RADIO_TRANSMITTER\
  326. DEFINE_USB_TERMINAL_GUID(0x0711)
  327. DEFINE_GUIDSTRUCT("DFF220F1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_RADIO_TRANSMITTER);
  328. #define KSNODETYPE_RADIO_TRANSMITTER DEFINE_GUIDNAMED(KSNODETYPE_RADIO_TRANSMITTER)
  329. #define STATIC_KSNODETYPE_MULTITRACK_RECORDER\
  330. DEFINE_USB_TERMINAL_GUID(0x0712)
  331. DEFINE_GUIDSTRUCT("DFF220F2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_MULTITRACK_RECORDER);
  332. #define KSNODETYPE_MULTITRACK_RECORDER DEFINE_GUIDNAMED(KSNODETYPE_MULTITRACK_RECORDER)
  333. #define STATIC_KSNODETYPE_SYNTHESIZER\
  334. DEFINE_USB_TERMINAL_GUID(0x0713)
  335. DEFINE_GUIDSTRUCT("DFF220F3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_SYNTHESIZER);
  336. #define KSNODETYPE_SYNTHESIZER DEFINE_GUIDNAMED(KSNODETYPE_SYNTHESIZER)
  337. // Microsoft's WDMAUD virtual swsynth pin name guid
  338. #define STATIC_KSNODETYPE_SWSYNTH\
  339. 0x423274A0L, 0x8B81, 0x11D1, 0xA0, 0x50, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  340. DEFINE_GUIDSTRUCT("423274A0-8B81-11D1-A050-0000F8004788", KSNODETYPE_SWSYNTH);
  341. #define KSNODETYPE_SWSYNTH DEFINE_GUIDNAMED(KSNODETYPE_SWSYNTH)
  342. // Microsoft's SWMIDI midi pin and node name guid
  343. #define STATIC_KSNODETYPE_SWMIDI\
  344. 0xCB9BEFA0L, 0xA251, 0x11D1, 0xA0, 0x50, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  345. DEFINE_GUIDSTRUCT("CB9BEFA0-A251-11D1-A050-0000F8004788", KSNODETYPE_SWMIDI);
  346. #define KSNODETYPE_SWMIDI DEFINE_GUIDNAMED(KSNODETYPE_SWMIDI)
  347. #define STATIC_KSNODETYPE_DRM_DESCRAMBLE\
  348. 0xFFBB6E3FL, 0xCCFE, 0x4D84, 0x90, 0xD9, 0x42, 0x14, 0x18, 0xB0, 0x3A, 0x8E
  349. DEFINE_GUIDSTRUCT("FFBB6E3F-CCFE-4D84-90D9-421418B03A8E", KSNODETYPE_DRM_DESCRAMBLE);
  350. #define KSNODETYPE_DRM_DESCRAMBLE DEFINE_GUIDNAMED(KSNODETYPE_DRM_DESCRAMBLE)
  351. // General categories
  352. #define STATIC_KSCATEGORY_AUDIO \
  353. 0x6994AD04L, 0x93EF, 0x11D0, 0xA3, 0xCC, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  354. DEFINE_GUIDSTRUCT("6994AD04-93EF-11D0-A3CC-00A0C9223196", KSCATEGORY_AUDIO);
  355. #define KSCATEGORY_AUDIO DEFINE_GUIDNAMED(KSCATEGORY_AUDIO)
  356. #define STATIC_KSCATEGORY_VIDEO \
  357. 0x6994AD05L, 0x93EF, 0x11D0, 0xA3, 0xCC, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  358. DEFINE_GUIDSTRUCT("6994AD05-93EF-11D0-A3CC-00A0C9223196", KSCATEGORY_VIDEO);
  359. #define KSCATEGORY_VIDEO DEFINE_GUIDNAMED(KSCATEGORY_VIDEO)
  360. #define STATIC_KSCATEGORY_TEXT \
  361. 0x6994AD06L, 0x93EF, 0x11D0, 0xA3, 0xCC, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  362. DEFINE_GUIDSTRUCT("6994AD06-93EF-11D0-A3CC-00A0C9223196", KSCATEGORY_TEXT);
  363. #define KSCATEGORY_TEXT DEFINE_GUIDNAMED(KSCATEGORY_TEXT)
  364. #define STATIC_KSCATEGORY_NETWORK \
  365. 0x67C9CC3CL, 0x69C4, 0x11D2, 0x87, 0x59, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  366. DEFINE_GUIDSTRUCT("67C9CC3C-69C4-11D2-8759-00A0C9223196", KSCATEGORY_NETWORK);
  367. #define KSCATEGORY_NETWORK DEFINE_GUIDNAMED(KSCATEGORY_NETWORK)
  368. #define STATIC_KSCATEGORY_TOPOLOGY \
  369. 0xDDA54A40L, 0x1E4C, 0x11D1, 0xA0, 0x50, 0x40, 0x57, 0x05, 0xC1, 0x00, 0x00
  370. DEFINE_GUIDSTRUCT("DDA54A40-1E4C-11D1-A050-405705C10000", KSCATEGORY_TOPOLOGY);
  371. #define KSCATEGORY_TOPOLOGY DEFINE_GUIDNAMED(KSCATEGORY_TOPOLOGY)
  372. #define STATIC_KSCATEGORY_VIRTUAL \
  373. 0x3503EAC4L, 0x1F26, 0x11D1, 0x8A, 0xB0, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  374. DEFINE_GUIDSTRUCT("3503EAC4-1F26-11D1-8AB0-00A0C9223196", KSCATEGORY_VIRTUAL);
  375. #define KSCATEGORY_VIRTUAL DEFINE_GUIDNAMED(KSCATEGORY_VIRTUAL)
  376. #define STATIC_KSCATEGORY_ACOUSTIC_ECHO_CANCEL \
  377. 0xBF963D80L, 0xC559, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  378. DEFINE_GUIDSTRUCT("BF963D80-C559-11D0-8A2B-00A0C9255AC1", KSCATEGORY_ACOUSTIC_ECHO_CANCEL);
  379. #define KSCATEGORY_ACOUSTIC_ECHO_CANCEL DEFINE_GUIDNAMED(KSCATEGORY_ACOUSTIC_ECHO_CANCEL)
  380. #define STATIC_KSCATEGORY_SYSAUDIO \
  381. 0xA7C7A5B1L, 0x5AF3, 0x11D1, 0x9C, 0xED, 0x00, 0xA0, 0x24, 0xBF, 0x04, 0x07
  382. DEFINE_GUIDSTRUCT("A7C7A5B1-5AF3-11D1-9CED-00A024BF0407", KSCATEGORY_SYSAUDIO);
  383. #define KSCATEGORY_SYSAUDIO DEFINE_GUIDNAMED(KSCATEGORY_SYSAUDIO)
  384. #define STATIC_KSCATEGORY_WDMAUD \
  385. 0x3E227E76L, 0x690D, 0x11D2, 0x81, 0x61, 0x00, 0x00, 0xF8, 0x77, 0x5B, 0xF1
  386. DEFINE_GUIDSTRUCT("3E227E76-690D-11D2-8161-0000F8775BF1", KSCATEGORY_WDMAUD);
  387. #define KSCATEGORY_WDMAUD DEFINE_GUIDNAMED(KSCATEGORY_WDMAUD)
  388. #define STATIC_KSCATEGORY_AUDIO_GFX \
  389. 0x9BAF9572L, 0x340C, 0x11D3, 0xAB, 0xDC, 0x00, 0xA0, 0xC9, 0x0A, 0xB1, 0x6F
  390. DEFINE_GUIDSTRUCT("9BAF9572-340C-11D3-ABDC-00A0C90AB16F", KSCATEGORY_AUDIO_GFX);
  391. #define KSCATEGORY_AUDIO_GFX DEFINE_GUIDNAMED(KSCATEGORY_AUDIO_GFX)
  392. #define STATIC_KSCATEGORY_AUDIO_SPLITTER \
  393. 0x9EA331FAL, 0xB91B, 0x45F8, 0x92, 0x85, 0xBD, 0x2B, 0xC7, 0x7A, 0xFC, 0xDE
  394. DEFINE_GUIDSTRUCT("9EA331FA-B91B-45F8-9285-BD2BC77AFCDE", KSCATEGORY_AUDIO_SPLITTER);
  395. #define KSCATEGORY_AUDIO_SPLITTER DEFINE_GUIDNAMED(KSCATEGORY_AUDIO_SPLITTER)
  396. #define STATIC_KSCATEGORY_SYNTHESIZER STATIC_KSNODETYPE_SYNTHESIZER
  397. #define KSCATEGORY_SYNTHESIZER KSNODETYPE_SYNTHESIZER
  398. #define STATIC_KSCATEGORY_DRM_DESCRAMBLE STATIC_KSNODETYPE_DRM_DESCRAMBLE
  399. #define KSCATEGORY_DRM_DESCRAMBLE KSNODETYPE_DRM_DESCRAMBLE
  400. #define STATIC_KSCATEGORY_AUDIO_DEVICE \
  401. 0xFBF6F530L, 0x07B9, 0x11D2, 0xA7, 0x1E, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  402. DEFINE_GUIDSTRUCT("FBF6F530-07B9-11D2-A71E-0000F8004788", KSCATEGORY_AUDIO_DEVICE);
  403. #define KSCATEGORY_AUDIO_DEVICE DEFINE_GUIDNAMED(KSCATEGORY_AUDIO_DEVICE)
  404. #define STATIC_KSCATEGORY_PREFERRED_WAVEOUT_DEVICE \
  405. 0xD6C5066EL, 0x72C1, 0x11D2, 0x97, 0x55, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  406. DEFINE_GUIDSTRUCT("D6C5066E-72C1-11D2-9755-0000F8004788", KSCATEGORY_PREFERRED_WAVEOUT_DEVICE);
  407. #define KSCATEGORY_PREFERRED_WAVEOUT_DEVICE DEFINE_GUIDNAMED(KSCATEGORY_PREFERRED_WAVEOUT_DEVICE)
  408. #define STATIC_KSCATEGORY_PREFERRED_WAVEIN_DEVICE \
  409. 0xD6C50671L, 0x72C1, 0x11D2, 0x97, 0x55, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  410. DEFINE_GUIDSTRUCT("D6C50671-72C1-11D2-9755-0000F8004788", KSCATEGORY_PREFERRED_WAVEIN_DEVICE);
  411. #define KSCATEGORY_PREFERRED_WAVEIN_DEVICE DEFINE_GUIDNAMED(KSCATEGORY_PREFERRED_WAVEIN_DEVICE)
  412. #define STATIC_KSCATEGORY_PREFERRED_MIDIOUT_DEVICE \
  413. 0xD6C50674L, 0x72C1, 0x11D2, 0x97, 0x55, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  414. DEFINE_GUIDSTRUCT("D6C50674-72C1-11D2-9755-0000F8004788", KSCATEGORY_PREFERRED_MIDIOUT_DEVICE);
  415. #define KSCATEGORY_PREFERRED_MIDIOUT_DEVICE DEFINE_GUIDNAMED(KSCATEGORY_PREFERRED_MIDIOUT_DEVICE)
  416. // Special pin category for wdmaud
  417. #define STATIC_KSCATEGORY_WDMAUD_USE_PIN_NAME \
  418. 0x47A4FA20L, 0xA251, 0x11D1, 0xA0, 0x50, 0x00, 0x00, 0xF8, 0x00, 0x47, 0x88
  419. DEFINE_GUIDSTRUCT("47A4FA20-A251-11D1-A050-0000F8004788", KSCATEGORY_WDMAUD_USE_PIN_NAME);
  420. #define KSCATEGORY_WDMAUD_USE_PIN_NAME DEFINE_GUIDNAMED(KSCATEGORY_WDMAUD_USE_PIN_NAME)
  421. // Escalante Platform Interface
  422. #define STATIC_KSCATEGORY_ESCALANTE_PLATFORM_DRIVER \
  423. 0x74f3aea8L, 0x9768, 0x11d1, 0x8e, 0x07, 0x00, 0xa0, 0xc9, 0x5e, 0xc2, 0x2e
  424. DEFINE_GUIDSTRUCT("74f3aea8-9768-11d1-8e07-00a0c95ec22e", KSCATEGORY_ESCALANTE_PLATFORM_DRIVER);
  425. #define KSCATEGORY_ESCALANTE_PLATFORM_DRIVER DEFINE_GUIDNAMED(KSCATEGORY_ESCALANTE_PLATFORM_DRIVER)
  426. // -- major types ---
  427. // 'vids' == MEDIATYPE_Video,
  428. #define STATIC_KSDATAFORMAT_TYPE_VIDEO\
  429. 0x73646976L, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71
  430. DEFINE_GUIDSTRUCT("73646976-0000-0010-8000-00aa00389b71", KSDATAFORMAT_TYPE_VIDEO);
  431. #define KSDATAFORMAT_TYPE_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_VIDEO)
  432. // 'auds' == MEDIATYPE_Audio
  433. #define STATIC_KSDATAFORMAT_TYPE_AUDIO\
  434. 0x73647561L, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71
  435. DEFINE_GUIDSTRUCT("73647561-0000-0010-8000-00aa00389b71", KSDATAFORMAT_TYPE_AUDIO);
  436. #define KSDATAFORMAT_TYPE_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_AUDIO)
  437. // 'txts' == MEDIATYPE_Text
  438. #define STATIC_KSDATAFORMAT_TYPE_TEXT\
  439. 0x73747874L, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71
  440. DEFINE_GUIDSTRUCT("73747874-0000-0010-8000-00aa00389b71", KSDATAFORMAT_TYPE_TEXT);
  441. #define KSDATAFORMAT_TYPE_TEXT DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_TEXT)
  442. #if !defined( DEFINE_WAVEFORMATEX_GUID )
  443. #define DEFINE_WAVEFORMATEX_GUID(x) (USHORT)(x), 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71
  444. #endif
  445. #define STATIC_KSDATAFORMAT_SUBTYPE_WAVEFORMATEX\
  446. 0x00000000L, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71
  447. DEFINE_GUIDSTRUCT("00000000-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_WAVEFORMATEX);
  448. #define KSDATAFORMAT_SUBTYPE_WAVEFORMATEX DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_WAVEFORMATEX)
  449. #define INIT_WAVEFORMATEX_GUID(Guid, x)\
  450. {\
  451. *(Guid) = KSDATAFORMAT_SUBTYPE_WAVEFORMATEX;\
  452. (Guid)->Data1 = (USHORT)(x);\
  453. }
  454. #define EXTRACT_WAVEFORMATEX_ID(Guid)\
  455. (USHORT)((Guid)->Data1)
  456. #define IS_VALID_WAVEFORMATEX_GUID(Guid)\
  457. (!memcmp(((PUSHORT)&KSDATAFORMAT_SUBTYPE_WAVEFORMATEX) + 1, ((PUSHORT)(Guid)) + 1, sizeof(GUID) - sizeof(USHORT)))
  458. #if !defined(INIT_MMREG_MID)
  459. //{d5a47fa7-6d98-11d1-a21a-00a0c9223196}
  460. #define INIT_MMREG_MID(guid, id)\
  461. {\
  462. (guid)->Data1 = 0xd5a47fa7 + (USHORT)(id);\
  463. (guid)->Data2 = 0x6d98;\
  464. (guid)->Data3 = 0x11d1;\
  465. (guid)->Data4[0] = 0xa2;\
  466. (guid)->Data4[1] = 0x1a;\
  467. (guid)->Data4[2] = 0x00;\
  468. (guid)->Data4[3] = 0xa0;\
  469. (guid)->Data4[4] = 0xc9;\
  470. (guid)->Data4[5] = 0x22;\
  471. (guid)->Data4[6] = 0x31;\
  472. (guid)->Data4[7] = 0x96;\
  473. }
  474. #define EXTRACT_MMREG_MID(guid)\
  475. (USHORT)((guid)->Data1 - 0xd5a47fa7)
  476. #define DEFINE_MMREG_MID_GUID(id)\
  477. 0xd5a47fa7+(USHORT)(id), 0x6d98, 0x11d1, 0xa2, 0x1a, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96
  478. #define IS_COMPATIBLE_MMREG_MID(guid)\
  479. (((guid)->Data1 >= 0xd5a47fa7) &&\
  480. ((guid)->Data1 < 0xd5a47fa7 + 0xffff) &&\
  481. ((guid)->Data2 == 0x6d98) &&\
  482. ((guid)->Data3 == 0x11d1) &&\
  483. ((guid)->Data4[0] == 0xa2) &&\
  484. ((guid)->Data4[1] == 0x1a) &&\
  485. ((guid)->Data4[2] == 0x00) &&\
  486. ((guid)->Data4[3] == 0xa0) &&\
  487. ((guid)->Data4[4] == 0xc9) &&\
  488. ((guid)->Data4[5] == 0x22) &&\
  489. ((guid)->Data4[6] == 0x31) &&\
  490. ((guid)->Data4[7] == 0x96))
  491. #endif // !defined(INIT_MMREG_MID)
  492. #if !defined(INIT_MMREG_PID)
  493. //{e36dc2ac-6d9a-11d1-a21a-00a0c9223196}
  494. #define INIT_MMREG_PID(guid, id)\
  495. {\
  496. (guid)->Data1 = 0xe36dc2ac + (USHORT)(id);\
  497. (guid)->Data2 = 0x6d9a;\
  498. (guid)->Data3 = 0x11d1;\
  499. (guid)->Data4[0] = 0xa2;\
  500. (guid)->Data4[1] = 0x1a;\
  501. (guid)->Data4[2] = 0x00;\
  502. (guid)->Data4[3] = 0xa0;\
  503. (guid)->Data4[4] = 0xc9;\
  504. (guid)->Data4[5] = 0x22;\
  505. (guid)->Data4[6] = 0x31;\
  506. (guid)->Data4[7] = 0x96;\
  507. }
  508. #define EXTRACT_MMREG_PID(guid)\
  509. (USHORT)((guid)->Data1 - 0xe36dc2ac)
  510. #define DEFINE_MMREG_PID_GUID(id)\
  511. 0xe36dc2ac+(USHORT)(id), 0x6d9a, 0x11d1, 0xa2, 0x1a, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96
  512. #define IS_COMPATIBLE_MMREG_PID(guid)\
  513. (((guid)->Data1 >= 0xe36dc2ac) &&\
  514. ((guid)->Data1 < 0xe36dc2ac + 0xffff) &&\
  515. ((guid)->Data2 == 0x6d9a) &&\
  516. ((guid)->Data3 == 0x11d1) &&\
  517. ((guid)->Data4[0] == 0xa2) &&\
  518. ((guid)->Data4[1] == 0x1a) &&\
  519. ((guid)->Data4[2] == 0x00) &&\
  520. ((guid)->Data4[3] == 0xa0) &&\
  521. ((guid)->Data4[4] == 0xc9) &&\
  522. ((guid)->Data4[5] == 0x22) &&\
  523. ((guid)->Data4[6] == 0x31) &&\
  524. ((guid)->Data4[7] == 0x96))
  525. #endif // !defined(INIT_MMREG_PID)
  526. #define STATIC_KSDATAFORMAT_SUBTYPE_ANALOG\
  527. 0x6dba3190L, 0x67bd, 0x11cf, 0xa0, 0xf7, 0x00, 0x20, 0xaf, 0xd1, 0x56, 0xe4
  528. DEFINE_GUIDSTRUCT("6dba3190-67bd-11cf-a0f7-0020afd156e4", KSDATAFORMAT_SUBTYPE_ANALOG);
  529. #define KSDATAFORMAT_SUBTYPE_ANALOG DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_ANALOG)
  530. #define STATIC_KSDATAFORMAT_SUBTYPE_PCM\
  531. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_PCM)
  532. DEFINE_GUIDSTRUCT("00000001-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_PCM);
  533. #define KSDATAFORMAT_SUBTYPE_PCM DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_PCM)
  534. #if defined(_INC_MMREG)
  535. #define STATIC_KSDATAFORMAT_SUBTYPE_IEEE_FLOAT\
  536. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_IEEE_FLOAT)
  537. DEFINE_GUIDSTRUCT("00000003-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_IEEE_FLOAT);
  538. #define KSDATAFORMAT_SUBTYPE_IEEE_FLOAT DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_IEEE_FLOAT)
  539. #define STATIC_KSDATAFORMAT_SUBTYPE_DRM\
  540. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_DRM)
  541. DEFINE_GUIDSTRUCT("00000009-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_DRM);
  542. #define KSDATAFORMAT_SUBTYPE_DRM DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_DRM)
  543. #define STATIC_KSDATAFORMAT_SUBTYPE_ALAW\
  544. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_ALAW)
  545. DEFINE_GUIDSTRUCT("00000006-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_ALAW);
  546. #define KSDATAFORMAT_SUBTYPE_ALAW DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_ALAW)
  547. #define STATIC_KSDATAFORMAT_SUBTYPE_MULAW\
  548. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_MULAW)
  549. DEFINE_GUIDSTRUCT("00000007-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_MULAW);
  550. #define KSDATAFORMAT_SUBTYPE_MULAW DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MULAW)
  551. #define STATIC_KSDATAFORMAT_SUBTYPE_ADPCM\
  552. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_ADPCM)
  553. DEFINE_GUIDSTRUCT("00000002-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_ADPCM);
  554. #define KSDATAFORMAT_SUBTYPE_ADPCM DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_ADPCM)
  555. #define STATIC_KSDATAFORMAT_SUBTYPE_MPEG\
  556. DEFINE_WAVEFORMATEX_GUID(WAVE_FORMAT_MPEG)
  557. DEFINE_GUIDSTRUCT("00000050-0000-0010-8000-00aa00389b71", KSDATAFORMAT_SUBTYPE_MPEG);
  558. #define KSDATAFORMAT_SUBTYPE_MPEG DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MPEG)
  559. #endif // defined(_INC_MMREG)
  560. #define STATIC_KSDATAFORMAT_SPECIFIER_VC_ID\
  561. 0xAD98D184L, 0xAAC3, 0x11D0, 0xA4, 0x1C, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  562. DEFINE_GUIDSTRUCT("AD98D184-AAC3-11D0-A41C-00A0C9223196", KSDATAFORMAT_SPECIFIER_VC_ID);
  563. #define KSDATAFORMAT_SPECIFIER_VC_ID DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_VC_ID)
  564. #define STATIC_KSDATAFORMAT_SPECIFIER_WAVEFORMATEX\
  565. 0x05589f81L, 0xc356, 0x11ce, 0xbf, 0x01, 0x00, 0xaa, 0x00, 0x55, 0x59, 0x5a
  566. DEFINE_GUIDSTRUCT("05589f81-c356-11ce-bf01-00aa0055595a", KSDATAFORMAT_SPECIFIER_WAVEFORMATEX);
  567. #define KSDATAFORMAT_SPECIFIER_WAVEFORMATEX DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_WAVEFORMATEX)
  568. #define STATIC_KSDATAFORMAT_SPECIFIER_DSOUND\
  569. 0x518590a2L, 0xa184, 0x11d0, 0x85, 0x22, 0x00, 0xc0, 0x4f, 0xd9, 0xba, 0xf3
  570. DEFINE_GUIDSTRUCT("518590a2-a184-11d0-8522-00c04fd9baf3", KSDATAFORMAT_SPECIFIER_DSOUND);
  571. #define KSDATAFORMAT_SPECIFIER_DSOUND DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_DSOUND)
  572. #if defined(_INC_MMSYSTEM) || defined(_INC_MMREG)
  573. #if !defined( PACK_PRAGMAS_NOT_SUPPORTED )
  574. #include <pshpack1.h>
  575. #endif
  576. typedef struct {
  577. KSDATAFORMAT DataFormat;
  578. WAVEFORMATEX WaveFormatEx;
  579. } KSDATAFORMAT_WAVEFORMATEX, *PKSDATAFORMAT_WAVEFORMATEX;
  580. #ifndef _WAVEFORMATEXTENSIBLE_
  581. #define _WAVEFORMATEXTENSIBLE_
  582. typedef struct {
  583. WAVEFORMATEX Format;
  584. union {
  585. WORD wValidBitsPerSample; /* bits of precision */
  586. WORD wSamplesPerBlock; /* valid if wBitsPerSample==0 */
  587. WORD wReserved; /* If neither applies, set to zero. */
  588. } Samples;
  589. DWORD dwChannelMask; /* which channels are */
  590. /* present in stream */
  591. GUID SubFormat;
  592. } WAVEFORMATEXTENSIBLE, *PWAVEFORMATEXTENSIBLE;
  593. #endif // !_WAVEFORMATEXTENSIBLE_
  594. #if !defined(WAVE_FORMAT_EXTENSIBLE)
  595. #define WAVE_FORMAT_EXTENSIBLE 0xFFFE
  596. #endif // !defined(WAVE_FORMAT_EXTENSIBLE)
  597. // DirectSound buffer description
  598. typedef struct {
  599. ULONG Flags;
  600. ULONG Control;
  601. WAVEFORMATEX WaveFormatEx;
  602. } KSDSOUND_BUFFERDESC, *PKSDSOUND_BUFFERDESC;
  603. // DirectSound format
  604. typedef struct {
  605. KSDATAFORMAT DataFormat;
  606. KSDSOUND_BUFFERDESC BufferDesc;
  607. } KSDATAFORMAT_DSOUND, *PKSDATAFORMAT_DSOUND;
  608. #if !defined( PACK_PRAGMAS_NOT_SUPPORTED )
  609. #include <poppack.h>
  610. #endif
  611. #endif // defined(_INC_MMSYSTEM) || defined(_INC_MMREG)
  612. // DirectSound buffer flags
  613. #define KSDSOUND_BUFFER_PRIMARY 0x00000001
  614. #define KSDSOUND_BUFFER_STATIC 0x00000002
  615. #define KSDSOUND_BUFFER_LOCHARDWARE 0x00000004
  616. #define KSDSOUND_BUFFER_LOCSOFTWARE 0x00000008
  617. // DirectSound buffer control flags
  618. #define KSDSOUND_BUFFER_CTRL_3D 0x00000001
  619. #define KSDSOUND_BUFFER_CTRL_FREQUENCY 0x00000002
  620. #define KSDSOUND_BUFFER_CTRL_PAN 0x00000004
  621. #define KSDSOUND_BUFFER_CTRL_VOLUME 0x00000008
  622. #define KSDSOUND_BUFFER_CTRL_POSITIONNOTIFY 0x00000010
  623. typedef struct {
  624. #if defined(_NTDDK_)
  625. ULONGLONG PlayOffset;
  626. ULONGLONG WriteOffset;
  627. #else // !_NTDDK_
  628. DWORDLONG PlayOffset;
  629. DWORDLONG WriteOffset;
  630. #endif // !_NTDDK_
  631. } KSAUDIO_POSITION, *PKSAUDIO_POSITION;
  632. //===========================================================================
  633. // DirectSound3D HAL
  634. typedef struct _DS3DVECTOR {
  635. union {
  636. FLOAT x;
  637. FLOAT dvX;
  638. };
  639. union {
  640. FLOAT y;
  641. FLOAT dvY;
  642. };
  643. union {
  644. FLOAT z;
  645. FLOAT dvZ;
  646. };
  647. } DS3DVECTOR, *PDS3DVECTOR;
  648. //===========================================================================
  649. //===========================================================================
  650. // KSPROPSETID_DirectSound3DListener : {437B3414-D060-11d0-8583-00C04FD9BAF3}
  651. #define STATIC_KSPROPSETID_DirectSound3DListener\
  652. 0x437b3414L, 0xd060, 0x11d0, 0x85, 0x83, 0x00, 0xc0, 0x4f, 0xd9, 0xba, 0xf3
  653. DEFINE_GUIDSTRUCT("437b3414-d060-11d0-8583-00c04fd9baf3",KSPROPSETID_DirectSound3DListener);
  654. #define KSPROPSETID_DirectSound3DListener DEFINE_GUIDNAMED(KSPROPSETID_DirectSound3DListener)
  655. typedef enum {
  656. KSPROPERTY_DIRECTSOUND3DLISTENER_ALL,
  657. KSPROPERTY_DIRECTSOUND3DLISTENER_POSITION,
  658. KSPROPERTY_DIRECTSOUND3DLISTENER_VELOCITY,
  659. KSPROPERTY_DIRECTSOUND3DLISTENER_ORIENTATION,
  660. KSPROPERTY_DIRECTSOUND3DLISTENER_DISTANCEFACTOR,
  661. KSPROPERTY_DIRECTSOUND3DLISTENER_ROLLOFFFACTOR,
  662. KSPROPERTY_DIRECTSOUND3DLISTENER_DOPPLERFACTOR,
  663. KSPROPERTY_DIRECTSOUND3DLISTENER_BATCH,
  664. KSPROPERTY_DIRECTSOUND3DLISTENER_ALLOCATION
  665. } KSPROPERTY_DIRECTSOUND3DLISTENER;
  666. typedef struct {
  667. DS3DVECTOR Position;
  668. DS3DVECTOR Velocity;
  669. DS3DVECTOR OrientFront;
  670. DS3DVECTOR OrientTop;
  671. FLOAT DistanceFactor;
  672. FLOAT RolloffFactor;
  673. FLOAT DopplerFactor;
  674. } KSDS3D_LISTENER_ALL, *PKSDS3D_LISTENER_ALL;
  675. typedef struct {
  676. DS3DVECTOR Front;
  677. DS3DVECTOR Top;
  678. } KSDS3D_LISTENER_ORIENTATION, *PKSDS3D_LISTENER_ORIENTATION;
  679. //===========================================================================
  680. //===========================================================================
  681. // KSPROPSETID_DirectSound3DBuffer : {437B3411-D060-11d0-8583-00C04FD9BAF3}
  682. #define STATIC_KSPROPSETID_DirectSound3DBuffer\
  683. 0x437b3411L, 0xd060, 0x11d0, 0x85, 0x83, 0x00, 0xc0, 0x4f, 0xd9, 0xba, 0xf3
  684. DEFINE_GUIDSTRUCT("437b3411-d060-11d0-8583-00c04fd9baf3", KSPROPSETID_DirectSound3DBuffer);
  685. #define KSPROPSETID_DirectSound3DBuffer DEFINE_GUIDNAMED(KSPROPSETID_DirectSound3DBuffer)
  686. typedef enum {
  687. KSPROPERTY_DIRECTSOUND3DBUFFER_ALL,
  688. KSPROPERTY_DIRECTSOUND3DBUFFER_POSITION,
  689. KSPROPERTY_DIRECTSOUND3DBUFFER_VELOCITY,
  690. KSPROPERTY_DIRECTSOUND3DBUFFER_CONEANGLES,
  691. KSPROPERTY_DIRECTSOUND3DBUFFER_CONEORIENTATION,
  692. KSPROPERTY_DIRECTSOUND3DBUFFER_CONEOUTSIDEVOLUME,
  693. KSPROPERTY_DIRECTSOUND3DBUFFER_MINDISTANCE,
  694. KSPROPERTY_DIRECTSOUND3DBUFFER_MAXDISTANCE,
  695. KSPROPERTY_DIRECTSOUND3DBUFFER_MODE
  696. } KSPROPERTY_DIRECTSOUND3DBUFFER;
  697. typedef struct {
  698. DS3DVECTOR Position;
  699. DS3DVECTOR Velocity;
  700. ULONG InsideConeAngle;
  701. ULONG OutsideConeAngle;
  702. DS3DVECTOR ConeOrientation;
  703. LONG ConeOutsideVolume;
  704. FLOAT MinDistance;
  705. FLOAT MaxDistance;
  706. ULONG Mode;
  707. } KSDS3D_BUFFER_ALL, *PKSDS3D_BUFFER_ALL;
  708. typedef struct {
  709. ULONG InsideConeAngle;
  710. ULONG OutsideConeAngle;
  711. } KSDS3D_BUFFER_CONE_ANGLES, *PKSDS3D_BUFFER_CONE_ANGLES;
  712. #define KSAUDIO_STEREO_SPEAKER_GEOMETRY_HEADPHONE (-1)
  713. #define KSAUDIO_STEREO_SPEAKER_GEOMETRY_MIN 5
  714. #define KSAUDIO_STEREO_SPEAKER_GEOMETRY_NARROW 10
  715. #define KSAUDIO_STEREO_SPEAKER_GEOMETRY_WIDE 20
  716. #define KSAUDIO_STEREO_SPEAKER_GEOMETRY_MAX 180
  717. #define KSDSOUND_3D_MODE_NORMAL 0x00000000
  718. #define KSDSOUND_3D_MODE_HEADRELATIVE 0x00000001
  719. #define KSDSOUND_3D_MODE_DISABLE 0x00000002
  720. typedef struct {
  721. KSDATARANGE DataRange;
  722. ULONG MaximumChannels;
  723. ULONG MinimumBitsPerSample;
  724. ULONG MaximumBitsPerSample;
  725. ULONG MinimumSampleFrequency;
  726. ULONG MaximumSampleFrequency;
  727. } KSDATARANGE_AUDIO, *PKSDATARANGE_AUDIO;
  728. //---------------------------------------------------------------------------
  729. #define STATIC_KSDATAFORMAT_SUBTYPE_RIFF\
  730. 0x4995DAEEL, 0x9EE6, 0x11D0, 0xA4, 0x0E, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  731. DEFINE_GUIDSTRUCT("4995DAEE-9EE6-11D0-A40E-00A0C9223196", KSDATAFORMAT_SUBTYPE_RIFF);
  732. #define KSDATAFORMAT_SUBTYPE_RIFF DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_RIFF)
  733. #define STATIC_KSDATAFORMAT_SUBTYPE_RIFFWAVE\
  734. 0xe436eb8bL, 0x524f, 0x11ce, 0x9f, 0x53, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70
  735. DEFINE_GUIDSTRUCT("e436eb8b-524f-11ce-9f53-0020af0ba770", KSDATAFORMAT_SUBTYPE_RIFFWAVE);
  736. #define KSDATAFORMAT_SUBTYPE_RIFFWAVE DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_RIFFWAVE)
  737. //===========================================================================
  738. //===========================================================================
  739. #define STATIC_KSPROPSETID_Bibliographic \
  740. 0x07BA150EL, 0xE2B1, 0x11D0, 0xAC, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  741. DEFINE_GUIDSTRUCT("07BA150E-E2B1-11D0-AC17-00A0C9223196", KSPROPSETID_Bibliographic);
  742. #define KSPROPSETID_Bibliographic DEFINE_GUIDNAMED(KSPROPSETID_Bibliographic)
  743. //Repeatable tags contain all entries within the property, each preceeded by length
  744. typedef enum {
  745. KSPROPERTY_BIBLIOGRAPHIC_LEADER = 'RDL ',
  746. KSPROPERTY_BIBLIOGRAPHIC_LCCN = '010 ',
  747. KSPROPERTY_BIBLIOGRAPHIC_ISBN = '020 ',
  748. KSPROPERTY_BIBLIOGRAPHIC_ISSN = '220 ',
  749. KSPROPERTY_BIBLIOGRAPHIC_CATALOGINGSOURCE = '040 ',
  750. KSPROPERTY_BIBLIOGRAPHIC_MAINPERSONALNAME = '001 ',
  751. KSPROPERTY_BIBLIOGRAPHIC_MAINCORPORATEBODY = '011 ',
  752. KSPROPERTY_BIBLIOGRAPHIC_MAINMEETINGNAME = '111 ',
  753. KSPROPERTY_BIBLIOGRAPHIC_MAINUNIFORMTITLE = '031 ',
  754. KSPROPERTY_BIBLIOGRAPHIC_UNIFORMTITLE = '042 ',
  755. KSPROPERTY_BIBLIOGRAPHIC_TITLESTATEMENT = '542 ',
  756. KSPROPERTY_BIBLIOGRAPHIC_VARYINGFORMTITLE = '642 ',
  757. KSPROPERTY_BIBLIOGRAPHIC_PUBLICATION = '062 ',
  758. KSPROPERTY_BIBLIOGRAPHIC_PHYSICALDESCRIPTION = '003 ',
  759. KSPROPERTY_BIBLIOGRAPHIC_ADDEDENTRYTITLE = '044 ',
  760. KSPROPERTY_BIBLIOGRAPHIC_SERIESSTATEMENT = '094 ',
  761. KSPROPERTY_BIBLIOGRAPHIC_GENERALNOTE = '005 ',
  762. KSPROPERTY_BIBLIOGRAPHIC_BIBLIOGRAPHYNOTE = '405 ',
  763. KSPROPERTY_BIBLIOGRAPHIC_CONTENTSNOTE = '505 ',
  764. KSPROPERTY_BIBLIOGRAPHIC_CREATIONCREDIT = '805 ',
  765. KSPROPERTY_BIBLIOGRAPHIC_CITATION = '015 ',
  766. KSPROPERTY_BIBLIOGRAPHIC_PARTICIPANT = '115 ',
  767. KSPROPERTY_BIBLIOGRAPHIC_SUMMARY = '025 ',
  768. KSPROPERTY_BIBLIOGRAPHIC_TARGETAUDIENCE = '125 ',
  769. KSPROPERTY_BIBLIOGRAPHIC_ADDEDFORMAVAILABLE = '035 ',
  770. KSPROPERTY_BIBLIOGRAPHIC_SYSTEMDETAILS = '835 ',
  771. KSPROPERTY_BIBLIOGRAPHIC_AWARDS = '685 ',
  772. KSPROPERTY_BIBLIOGRAPHIC_ADDEDENTRYPERSONALNAME = '006 ',
  773. KSPROPERTY_BIBLIOGRAPHIC_ADDEDENTRYTOPICALTERM = '056 ',
  774. KSPROPERTY_BIBLIOGRAPHIC_ADDEDENTRYGEOGRAPHIC = '156 ',
  775. KSPROPERTY_BIBLIOGRAPHIC_INDEXTERMGENRE = '556 ',
  776. KSPROPERTY_BIBLIOGRAPHIC_INDEXTERMCURRICULUM = '856 ',
  777. KSPROPERTY_BIBLIOGRAPHIC_ADDEDENTRYUNIFORMTITLE = '037 ',
  778. KSPROPERTY_BIBLIOGRAPHIC_ADDEDENTRYRELATED = '047 ',
  779. KSPROPERTY_BIBLIOGRAPHIC_SERIESSTATEMENTPERSONALNAME = '008 ',
  780. KSPROPERTY_BIBLIOGRAPHIC_SERIESSTATEMENTUNIFORMTITLE = '038 '
  781. } KSPROPERTY_BIBLIOGRAPHIC;
  782. #define STATIC_KSPROPSETID_TopologyNode\
  783. 0x45FFAAA1L, 0x6E1B, 0x11D0, 0xBC, 0xF2, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00
  784. DEFINE_GUIDSTRUCT("45FFAAA1-6E1B-11D0-BCF2-444553540000", KSPROPSETID_TopologyNode);
  785. #define KSPROPSETID_TopologyNode DEFINE_GUIDNAMED(KSPROPSETID_TopologyNode)
  786. typedef enum {
  787. KSPROPERTY_TOPOLOGYNODE_ENABLE = 1,
  788. KSPROPERTY_TOPOLOGYNODE_RESET
  789. } KSPROPERTY_TOPOLOGYNODE;
  790. //===========================================================================
  791. #if defined(_NTDDK_)
  792. typedef NTSTATUS (CALLBACK *PRTAUDIOGETPOSITION)(IN PFILE_OBJECT PinFileObject,
  793. OUT PUCHAR *ppPlayPosition,
  794. OUT PLONG plOffset);
  795. #endif // defined(_NTDDK_)
  796. #define STATIC_KSPROPSETID_RtAudio\
  797. 0xa855a48c, 0x2f78, 0x4729, 0x90, 0x51, 0x19, 0x68, 0x74, 0x6b, 0x9e, 0xef
  798. DEFINE_GUIDSTRUCT("A855A48C-2F78-4729-9051-1968746B9EEF", KSPROPSETID_RtAudio);
  799. #define KSPROPSETID_RtAudio DEFINE_GUIDNAMED(KSPROPSETID_RtAudio)
  800. typedef enum {
  801. KSPROPERTY_RTAUDIO_GETPOSITIONFUNCTION
  802. } KSPROPERTY_RTAUDIO;
  803. //===========================================================================
  804. #define STATIC_KSPROPSETID_DrmAudioStream\
  805. 0x2f2c8ddd, 0x4198, 0x4fac, 0xba, 0x29, 0x61, 0xbb, 0x5, 0xb7, 0xde, 0x6
  806. DEFINE_GUIDSTRUCT("2F2C8DDD-4198-4fac-BA29-61BB05B7DE06", KSPROPSETID_DrmAudioStream);
  807. #define KSPROPSETID_DrmAudioStream DEFINE_GUIDNAMED(KSPROPSETID_DrmAudioStream)
  808. typedef enum {
  809. KSPROPERTY_DRMAUDIOSTREAM_CONTENTID
  810. } KSPROPERTY_DRMAUDIOSTREAM;
  811. //===========================================================================
  812. #define STATIC_KSPROPSETID_Audio\
  813. 0x45FFAAA0L, 0x6E1B, 0x11D0, 0xBC, 0xF2, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00
  814. DEFINE_GUIDSTRUCT("45FFAAA0-6E1B-11D0-BCF2-444553540000", KSPROPSETID_Audio);
  815. #define KSPROPSETID_Audio DEFINE_GUIDNAMED(KSPROPSETID_Audio)
  816. typedef enum {
  817. KSPROPERTY_AUDIO_LATENCY = 1,
  818. KSPROPERTY_AUDIO_COPY_PROTECTION,
  819. KSPROPERTY_AUDIO_CHANNEL_CONFIG,
  820. KSPROPERTY_AUDIO_VOLUMELEVEL,
  821. KSPROPERTY_AUDIO_POSITION,
  822. KSPROPERTY_AUDIO_DYNAMIC_RANGE,
  823. KSPROPERTY_AUDIO_QUALITY,
  824. KSPROPERTY_AUDIO_SAMPLING_RATE,
  825. KSPROPERTY_AUDIO_DYNAMIC_SAMPLING_RATE,
  826. KSPROPERTY_AUDIO_MIX_LEVEL_TABLE,
  827. KSPROPERTY_AUDIO_MIX_LEVEL_CAPS,
  828. KSPROPERTY_AUDIO_MUX_SOURCE,
  829. KSPROPERTY_AUDIO_MUTE,
  830. KSPROPERTY_AUDIO_BASS,
  831. KSPROPERTY_AUDIO_MID,
  832. KSPROPERTY_AUDIO_TREBLE,
  833. KSPROPERTY_AUDIO_BASS_BOOST,
  834. KSPROPERTY_AUDIO_EQ_LEVEL,
  835. KSPROPERTY_AUDIO_NUM_EQ_BANDS,
  836. KSPROPERTY_AUDIO_EQ_BANDS,
  837. KSPROPERTY_AUDIO_AGC,
  838. KSPROPERTY_AUDIO_DELAY,
  839. KSPROPERTY_AUDIO_LOUDNESS,
  840. KSPROPERTY_AUDIO_WIDE_MODE,
  841. KSPROPERTY_AUDIO_WIDENESS,
  842. KSPROPERTY_AUDIO_REVERB_LEVEL,
  843. KSPROPERTY_AUDIO_CHORUS_LEVEL,
  844. KSPROPERTY_AUDIO_DEV_SPECIFIC,
  845. KSPROPERTY_AUDIO_DEMUX_DEST,
  846. KSPROPERTY_AUDIO_STEREO_ENHANCE,
  847. KSPROPERTY_AUDIO_MANUFACTURE_GUID,
  848. KSPROPERTY_AUDIO_PRODUCT_GUID,
  849. KSPROPERTY_AUDIO_CPU_RESOURCES,
  850. KSPROPERTY_AUDIO_STEREO_SPEAKER_GEOMETRY,
  851. KSPROPERTY_AUDIO_SURROUND_ENCODE,
  852. KSPROPERTY_AUDIO_3D_INTERFACE,
  853. KSPROPERTY_AUDIO_PEAKMETER,
  854. KSPROPERTY_AUDIO_ALGORITHM_INSTANCE,
  855. KSPROPERTY_AUDIO_FILTER_STATE,
  856. KSPROPERTY_AUDIO_PREFERRED_STATUS
  857. } KSPROPERTY_AUDIO;
  858. // Audio quality constants
  859. #define KSAUDIO_QUALITY_WORST 0x0
  860. #define KSAUDIO_QUALITY_PC 0x1
  861. #define KSAUDIO_QUALITY_BASIC 0x2
  862. #define KSAUDIO_QUALITY_ADVANCED 0x3
  863. // Audio CPU resource constants
  864. #define KSAUDIO_CPU_RESOURCES_NOT_HOST_CPU 0x00000000
  865. #define KSAUDIO_CPU_RESOURCES_HOST_CPU 0x7FFFFFFF
  866. typedef struct {
  867. BOOL fCopyrighted;
  868. BOOL fOriginal;
  869. } KSAUDIO_COPY_PROTECTION, *PKSAUDIO_COPY_PROTECTION;
  870. typedef struct {
  871. LONG ActiveSpeakerPositions;
  872. } KSAUDIO_CHANNEL_CONFIG, *PKSAUDIO_CHANNEL_CONFIG;
  873. // Speaker Positions:
  874. #define SPEAKER_FRONT_LEFT 0x1
  875. #define SPEAKER_FRONT_RIGHT 0x2
  876. #define SPEAKER_FRONT_CENTER 0x4
  877. #define SPEAKER_LOW_FREQUENCY 0x8
  878. #define SPEAKER_BACK_LEFT 0x10
  879. #define SPEAKER_BACK_RIGHT 0x20
  880. #define SPEAKER_FRONT_LEFT_OF_CENTER 0x40
  881. #define SPEAKER_FRONT_RIGHT_OF_CENTER 0x80
  882. #define SPEAKER_BACK_CENTER 0x100
  883. #define SPEAKER_SIDE_LEFT 0x200
  884. #define SPEAKER_SIDE_RIGHT 0x400
  885. #define SPEAKER_TOP_CENTER 0x800
  886. #define SPEAKER_TOP_FRONT_LEFT 0x1000
  887. #define SPEAKER_TOP_FRONT_CENTER 0x2000
  888. #define SPEAKER_TOP_FRONT_RIGHT 0x4000
  889. #define SPEAKER_TOP_BACK_LEFT 0x8000
  890. #define SPEAKER_TOP_BACK_CENTER 0x10000
  891. #define SPEAKER_TOP_BACK_RIGHT 0x20000
  892. // Bit mask locations reserved for future use
  893. #define SPEAKER_RESERVED 0x7FFC0000
  894. // Used to specify that any possible permutation of speaker configurations
  895. #define SPEAKER_ALL 0x80000000
  896. // DirectSound Speaker Config
  897. #define KSAUDIO_SPEAKER_DIRECTOUT 0
  898. #define KSAUDIO_SPEAKER_MONO (SPEAKER_FRONT_CENTER)
  899. #define KSAUDIO_SPEAKER_STEREO (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT)
  900. #define KSAUDIO_SPEAKER_QUAD (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | \
  901. SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT)
  902. #define KSAUDIO_SPEAKER_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | \
  903. SPEAKER_FRONT_CENTER | SPEAKER_BACK_CENTER)
  904. #define KSAUDIO_SPEAKER_5POINT1 (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | \
  905. SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | \
  906. SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT)
  907. #define KSAUDIO_SPEAKER_7POINT1 (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | \
  908. SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | \
  909. SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT | \
  910. SPEAKER_FRONT_LEFT_OF_CENTER | SPEAKER_FRONT_RIGHT_OF_CENTER)
  911. #define KSAUDIO_SPEAKER_5POINT1_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | \
  912. SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | \
  913. SPEAKER_SIDE_LEFT | SPEAKER_SIDE_RIGHT)
  914. #define KSAUDIO_SPEAKER_7POINT1_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | \
  915. SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | \
  916. SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT | \
  917. SPEAKER_SIDE_LEFT | SPEAKER_SIDE_RIGHT)
  918. // The following are obsolete 5.1 and 7.1 settings (they lack side speakers). Note this means
  919. // that the default 5.1 and 7.1 settings (KSAUDIO_SPEAKER_5POINT1 and KSAUDIO_SPEAKER_7POINT1 are
  920. // similarly obsolete but are unchanged for compatibility reasons).
  921. #define KSAUDIO_SPEAKER_5POINT1_BACK KSAUDIO_SPEAKER_5POINT1
  922. #define KSAUDIO_SPEAKER_7POINT1_WIDE KSAUDIO_SPEAKER_7POINT1
  923. // DVD Speaker Positions
  924. #define KSAUDIO_SPEAKER_GROUND_FRONT_LEFT SPEAKER_FRONT_LEFT
  925. #define KSAUDIO_SPEAKER_GROUND_FRONT_CENTER SPEAKER_FRONT_CENTER
  926. #define KSAUDIO_SPEAKER_GROUND_FRONT_RIGHT SPEAKER_FRONT_RIGHT
  927. #define KSAUDIO_SPEAKER_GROUND_REAR_LEFT SPEAKER_BACK_LEFT
  928. #define KSAUDIO_SPEAKER_GROUND_REAR_RIGHT SPEAKER_BACK_RIGHT
  929. #define KSAUDIO_SPEAKER_TOP_MIDDLE SPEAKER_TOP_CENTER
  930. #define KSAUDIO_SPEAKER_SUPER_WOOFER SPEAKER_LOW_FREQUENCY
  931. typedef struct {
  932. ULONG QuietCompression;
  933. ULONG LoudCompression;
  934. } KSAUDIO_DYNAMIC_RANGE, *PKSAUDIO_DYNAMIC_RANGE;
  935. typedef struct {
  936. BOOL Mute;
  937. LONG Level;
  938. } KSAUDIO_MIXLEVEL, *PKSAUDIO_MIXLEVEL;
  939. typedef struct {
  940. BOOL Mute;
  941. LONG Minimum;
  942. LONG Maximum;
  943. LONG Reset;
  944. } KSAUDIO_MIX_CAPS, *PKSAUDIO_MIX_CAPS;
  945. typedef struct {
  946. ULONG InputChannels;
  947. ULONG OutputChannels;
  948. KSAUDIO_MIX_CAPS Capabilities[1];
  949. } KSAUDIO_MIXCAP_TABLE, *PKSAUDIO_MIXCAP_TABLE;
  950. typedef enum {
  951. SE_TECH_NONE,
  952. SE_TECH_ANALOG_DEVICES_PHAT,
  953. SE_TECH_CREATIVE,
  954. SE_TECH_NATIONAL_SEMI,
  955. SE_TECH_YAMAHA_YMERSION,
  956. SE_TECH_BBE,
  957. SE_TECH_CRYSTAL_SEMI,
  958. SE_TECH_QSOUND_QXPANDER,
  959. SE_TECH_SPATIALIZER,
  960. SE_TECH_SRS,
  961. SE_TECH_PLATFORM_TECH,
  962. SE_TECH_AKM,
  963. SE_TECH_AUREAL,
  964. SE_TECH_AZTECH,
  965. SE_TECH_BINAURA,
  966. SE_TECH_ESS_TECH,
  967. SE_TECH_HARMAN_VMAX,
  968. SE_TECH_NVIDEA,
  969. SE_TECH_PHILIPS_INCREDIBLE,
  970. SE_TECH_TEXAS_INST,
  971. SE_TECH_VLSI_TECH
  972. } SE_TECHNIQUE;
  973. typedef struct {
  974. SE_TECHNIQUE Technique;
  975. ULONG Center;
  976. ULONG Depth;
  977. ULONG Reserved;
  978. } KSAUDIO_STEREO_ENHANCE, *PKSAUDIO_STEREO_ENHANCE;
  979. typedef enum { // preferred device index
  980. KSPROPERTY_SYSAUDIO_NORMAL_DEFAULT = 0,
  981. KSPROPERTY_SYSAUDIO_PLAYBACK_DEFAULT,
  982. KSPROPERTY_SYSAUDIO_RECORD_DEFAULT,
  983. KSPROPERTY_SYSAUDIO_MIDI_DEFAULT,
  984. KSPROPERTY_SYSAUDIO_MIXER_DEFAULT
  985. } KSPROPERTY_SYSAUDIO_DEFAULT_TYPE;
  986. typedef struct {
  987. BOOL Enable;
  988. KSPROPERTY_SYSAUDIO_DEFAULT_TYPE DeviceType;
  989. ULONG Flags;
  990. ULONG Reserved;
  991. } KSAUDIO_PREFERRED_STATUS, *PKSAUDIO_PREFERRED_STATUS;
  992. //===========================================================================
  993. // Topology Node Type GUIDs
  994. #define STATIC_KSNODETYPE_DAC\
  995. 0x507AE360L, 0xC554, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  996. DEFINE_GUIDSTRUCT("507AE360-C554-11D0-8A2B-00A0C9255AC1", KSNODETYPE_DAC);
  997. #define KSNODETYPE_DAC DEFINE_GUIDNAMED(KSNODETYPE_DAC)
  998. #define STATIC_KSNODETYPE_ADC\
  999. 0x4D837FE0L, 0xC555, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1000. DEFINE_GUIDSTRUCT("4D837FE0-C555-11D0-8A2B-00A0C9255AC1", KSNODETYPE_ADC);
  1001. #define KSNODETYPE_ADC DEFINE_GUIDNAMED(KSNODETYPE_ADC)
  1002. #define STATIC_KSNODETYPE_SRC\
  1003. 0x9DB7B9E0L, 0xC555, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1004. DEFINE_GUIDSTRUCT("9DB7B9E0-C555-11D0-8A2B-00A0C9255AC1", KSNODETYPE_SRC);
  1005. #define KSNODETYPE_SRC DEFINE_GUIDNAMED(KSNODETYPE_SRC)
  1006. #define STATIC_KSNODETYPE_SUPERMIX\
  1007. 0xE573ADC0L, 0xC555, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1008. DEFINE_GUIDSTRUCT("E573ADC0-C555-11D0-8A2B-00A0C9255AC1", KSNODETYPE_SUPERMIX);
  1009. #define KSNODETYPE_SUPERMIX DEFINE_GUIDNAMED(KSNODETYPE_SUPERMIX)
  1010. #define STATIC_KSNODETYPE_MUX\
  1011. 0x2CEAF780L, 0xC556, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1012. DEFINE_GUIDSTRUCT("2CEAF780-C556-11D0-8A2B-00A0C9255AC1", KSNODETYPE_MUX);
  1013. #define KSNODETYPE_MUX DEFINE_GUIDNAMED(KSNODETYPE_MUX)
  1014. #define STATIC_KSNODETYPE_DEMUX\
  1015. 0xC0EB67D4L, 0xE807, 0x11D0, 0x95, 0x8A, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1016. DEFINE_GUIDSTRUCT("C0EB67D4-E807-11D0-958A-00C04FB925D3", KSNODETYPE_DEMUX);
  1017. #define KSNODETYPE_DEMUX DEFINE_GUIDNAMED(KSNODETYPE_DEMUX)
  1018. #define STATIC_KSNODETYPE_SUM\
  1019. 0xDA441A60L, 0xC556, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1020. DEFINE_GUIDSTRUCT("DA441A60-C556-11D0-8A2B-00A0C9255AC1", KSNODETYPE_SUM);
  1021. #define KSNODETYPE_SUM DEFINE_GUIDNAMED(KSNODETYPE_SUM)
  1022. #define STATIC_KSNODETYPE_MUTE\
  1023. 0x02B223C0L, 0xC557, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1024. DEFINE_GUIDSTRUCT("02B223C0-C557-11D0-8A2B-00A0C9255AC1", KSNODETYPE_MUTE);
  1025. #define KSNODETYPE_MUTE DEFINE_GUIDNAMED(KSNODETYPE_MUTE)
  1026. #define STATIC_KSNODETYPE_VOLUME\
  1027. 0x3A5ACC00L, 0xC557, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1028. DEFINE_GUIDSTRUCT("3A5ACC00-C557-11D0-8A2B-00A0C9255AC1", KSNODETYPE_VOLUME);
  1029. #define KSNODETYPE_VOLUME DEFINE_GUIDNAMED(KSNODETYPE_VOLUME)
  1030. #define STATIC_KSNODETYPE_TONE\
  1031. 0x7607E580L, 0xC557, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1032. DEFINE_GUIDSTRUCT("7607E580-C557-11D0-8A2B-00A0C9255AC1", KSNODETYPE_TONE);
  1033. #define KSNODETYPE_TONE DEFINE_GUIDNAMED(KSNODETYPE_TONE)
  1034. #define STATIC_KSNODETYPE_EQUALIZER\
  1035. 0x9D41B4A0L, 0xC557, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1036. DEFINE_GUIDSTRUCT("9D41B4A0-C557-11D0-8A2B-00A0C9255AC1", KSNODETYPE_EQUALIZER);
  1037. #define KSNODETYPE_EQUALIZER DEFINE_GUIDNAMED(KSNODETYPE_EQUALIZER)
  1038. #define STATIC_KSNODETYPE_AGC\
  1039. 0xE88C9BA0L, 0xC557, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1040. DEFINE_GUIDSTRUCT("E88C9BA0-C557-11D0-8A2B-00A0C9255AC1", KSNODETYPE_AGC);
  1041. #define KSNODETYPE_AGC DEFINE_GUIDNAMED(KSNODETYPE_AGC)
  1042. #define STATIC_KSNODETYPE_NOISE_SUPPRESS\
  1043. 0xe07f903f, 0x62fd, 0x4e60, 0x8c, 0xdd, 0xde, 0xa7, 0x23, 0x66, 0x65, 0xb5
  1044. DEFINE_GUIDSTRUCT("E07F903F-62FD-4e60-8CDD-DEA7236665B5", KSNODETYPE_NOISE_SUPPRESS);
  1045. #define KSNODETYPE_NOISE_SUPPRESS DEFINE_GUIDNAMED(KSNODETYPE_NOISE_SUPPRESS)
  1046. #define STATIC_KSNODETYPE_DELAY\
  1047. 0x144981E0L, 0xC558, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1048. DEFINE_GUIDSTRUCT("144981E0-C558-11D0-8A2B-00A0C9255AC1", KSNODETYPE_DELAY);
  1049. #define KSNODETYPE_DELAY DEFINE_GUIDNAMED(KSNODETYPE_DELAY)
  1050. #define STATIC_KSNODETYPE_LOUDNESS\
  1051. 0x41887440L, 0xC558, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1052. DEFINE_GUIDSTRUCT("41887440-C558-11D0-8A2B-00A0C9255AC1", KSNODETYPE_LOUDNESS);
  1053. #define KSNODETYPE_LOUDNESS DEFINE_GUIDNAMED(KSNODETYPE_LOUDNESS)
  1054. #define STATIC_KSNODETYPE_PROLOGIC_DECODER\
  1055. 0x831C2C80L, 0xC558, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1056. DEFINE_GUIDSTRUCT("831C2C80-C558-11D0-8A2B-00A0C9255AC1", KSNODETYPE_PROLOGIC_DECODER);
  1057. #define KSNODETYPE_PROLOGIC_DECODER DEFINE_GUIDNAMED(KSNODETYPE_PROLOGIC_DECODER)
  1058. #define STATIC_KSNODETYPE_STEREO_WIDE\
  1059. 0xA9E69800L, 0xC558, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1060. DEFINE_GUIDSTRUCT("A9E69800-C558-11D0-8A2B-00A0C9255AC1", KSNODETYPE_STEREO_WIDE);
  1061. #define KSNODETYPE_STEREO_WIDE DEFINE_GUIDNAMED(KSNODETYPE_STEREO_WIDE)
  1062. #define STATIC_KSNODETYPE_STEREO_ENHANCE\
  1063. 0xAF6878ACL, 0xE83F, 0x11D0, 0x95, 0x8A, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1064. DEFINE_GUIDSTRUCT("AF6878AC-E83F-11D0-958A-00C04FB925D3", KSNODETYPE_STEREO_ENHANCE);
  1065. #define KSNODETYPE_STEREO_ENHANCE DEFINE_GUIDNAMED(KSNODETYPE_STEREO_ENHANCE)
  1066. #define STATIC_KSNODETYPE_REVERB\
  1067. 0xEF0328E0L, 0xC558, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1068. DEFINE_GUIDSTRUCT("EF0328E0-C558-11D0-8A2B-00A0C9255AC1", KSNODETYPE_REVERB);
  1069. #define KSNODETYPE_REVERB DEFINE_GUIDNAMED(KSNODETYPE_REVERB)
  1070. #define STATIC_KSNODETYPE_CHORUS\
  1071. 0x20173F20L, 0xC559, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1072. DEFINE_GUIDSTRUCT("20173F20-C559-11D0-8A2B-00A0C9255AC1", KSNODETYPE_CHORUS);
  1073. #define KSNODETYPE_CHORUS DEFINE_GUIDNAMED(KSNODETYPE_CHORUS)
  1074. #define STATIC_KSNODETYPE_3D_EFFECTS\
  1075. 0x55515860L, 0xC559, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1076. DEFINE_GUIDSTRUCT("55515860-C559-11D0-8A2B-00A0C9255AC1", KSNODETYPE_3D_EFFECTS);
  1077. #define KSNODETYPE_3D_EFFECTS DEFINE_GUIDNAMED(KSNODETYPE_3D_EFFECTS)
  1078. #define STATIC_KSNODETYPE_ACOUSTIC_ECHO_CANCEL STATIC_KSCATEGORY_ACOUSTIC_ECHO_CANCEL
  1079. #define KSNODETYPE_ACOUSTIC_ECHO_CANCEL KSCATEGORY_ACOUSTIC_ECHO_CANCEL
  1080. #define STATIC_KSALGORITHMINSTANCE_SYSTEM_ACOUSTIC_ECHO_CANCEL\
  1081. 0x1c22c56dL, 0x9879, 0x4f5b, 0xa3, 0x89, 0x27, 0x99, 0x6d, 0xdc, 0x28, 0x10
  1082. DEFINE_GUIDSTRUCT("1C22C56D-9879-4f5b-A389-27996DDC2810", KSALGORITHMINSTANCE_SYSTEM_ACOUSTIC_ECHO_CANCEL);
  1083. #define KSALGORITHMINSTANCE_SYSTEM_ACOUSTIC_ECHO_CANCEL DEFINE_GUIDNAMED(KSALGORITHMINSTANCE_SYSTEM_ACOUSTIC_ECHO_CANCEL)
  1084. #define STATIC_KSALGORITHMINSTANCE_SYSTEM_NOISE_SUPPRESS\
  1085. 0x5ab0882eL, 0x7274, 0x4516, 0x87, 0x7d, 0x4e, 0xee, 0x99, 0xba, 0x4f, 0xd0
  1086. DEFINE_GUIDSTRUCT("5AB0882E-7274-4516-877D-4EEE99BA4FD0", KSALGORITHMINSTANCE_SYSTEM_NOISE_SUPPRESS);
  1087. #define KSALGORITHMINSTANCE_SYSTEM_NOISE_SUPPRESS DEFINE_GUIDNAMED(KSALGORITHMINSTANCE_SYSTEM_NOISE_SUPPRESS)
  1088. #define STATIC_KSALGORITHMINSTANCE_SYSTEM_AGC\
  1089. 0x950e55b9L, 0x877c, 0x4c67, 0xbe, 0x8, 0xe4, 0x7b, 0x56, 0x11, 0x13, 0xa
  1090. DEFINE_GUIDSTRUCT("950E55B9-877C-4c67-BE08-E47B5611130A", KSALGORITHMINSTANCE_SYSTEM_AGC);
  1091. #define KSALGORITHMINSTANCE_SYSTEM_AGC DEFINE_GUIDNAMED(KSALGORITHMINSTANCE_SYSTEM_AGC)
  1092. #define STATIC_KSALGORITHMINSTANCE_SYSTEM_MICROPHONE_ARRAY_PROCESSOR\
  1093. 0xB6F5A0A0L, 0x9E61, 0x4F8C, 0x91, 0xE3, 0x76, 0xCF, 0xF, 0x3C, 0x47, 0x1F
  1094. DEFINE_GUIDSTRUCT("B6F5A0A0-9E61-4f8c-91E3-76CF0F3C471F", KSALGORITHMINSTANCE_SYSTEM_MICROPHONE_ARRAY_PROCESSOR);
  1095. #define KSALGORITHMINSTANCE_SYSTEM_MICROPHONE_ARRAY_PROCESSOR DEFINE_GUIDNAMED(KSALGORITHMINSTANCE_SYSTEM_MICROPHONE_ARRAY_PROCESSOR)
  1096. #define STATIC_KSNODETYPE_MICROPHONE_ARRAY_PROCESSOR STATIC_KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR
  1097. #define KSNODETYPE_MICROPHONE_ARRAY_PROCESSOR KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR
  1098. #define STATIC_KSNODETYPE_DEV_SPECIFIC\
  1099. 0x941C7AC0L, 0xC559, 0x11D0, 0x8A, 0x2B, 0x00, 0xA0, 0xC9, 0x25, 0x5A, 0xC1
  1100. DEFINE_GUIDSTRUCT("941C7AC0-C559-11D0-8A2B-00A0C9255AC1", KSNODETYPE_DEV_SPECIFIC);
  1101. #define KSNODETYPE_DEV_SPECIFIC DEFINE_GUIDNAMED(KSNODETYPE_DEV_SPECIFIC)
  1102. #define STATIC_KSNODETYPE_PROLOGIC_ENCODER\
  1103. 0x8074C5B2L, 0x3C66, 0x11D2, 0xB4, 0x5A, 0x30, 0x78, 0x30, 0x2C, 0x20, 0x30
  1104. DEFINE_GUIDSTRUCT("8074C5B2-3C66-11D2-B45A-3078302C2030", KSNODETYPE_PROLOGIC_ENCODER);
  1105. #define KSNODETYPE_PROLOGIC_ENCODER DEFINE_GUIDNAMED(KSNODETYPE_PROLOGIC_ENCODER)
  1106. #define KSNODETYPE_SURROUND_ENCODER KSNODETYPE_PROLOGIC_ENCODER
  1107. #define STATIC_KSNODETYPE_PEAKMETER\
  1108. 0xa085651eL, 0x5f0d, 0x4b36, 0xa8, 0x69, 0xd1, 0x95, 0xd6, 0xab, 0x4b, 0x9e
  1109. DEFINE_GUIDSTRUCT("A085651E-5F0D-4b36-A869-D195D6AB4B9E", KSNODETYPE_PEAKMETER);
  1110. #define KSNODETYPE_PEAKMETER DEFINE_GUIDNAMED(KSNODETYPE_PEAKMETER)
  1111. //===========================================================================
  1112. // Topology Node Name GUIDs for common audio nodes
  1113. #define STATIC_KSAUDFNAME_BASS\
  1114. 0x185FEDE0L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1115. DEFINE_GUIDSTRUCT("185FEDE0-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_BASS);
  1116. #define KSAUDFNAME_BASS DEFINE_GUIDNAMED(KSAUDFNAME_BASS)
  1117. #define STATIC_KSAUDFNAME_TREBLE\
  1118. 0x185FEDE1L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1119. DEFINE_GUIDSTRUCT("185FEDE1-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_TREBLE);
  1120. #define KSAUDFNAME_TREBLE DEFINE_GUIDNAMED(KSAUDFNAME_TREBLE)
  1121. #define STATIC_KSAUDFNAME_3D_STEREO\
  1122. 0x185FEDE2L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1123. DEFINE_GUIDSTRUCT("185FEDE2-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_3D_STEREO);
  1124. #define KSAUDFNAME_3D_STEREO DEFINE_GUIDNAMED(KSAUDFNAME_3D_STEREO)
  1125. #define STATIC_KSAUDFNAME_MASTER_VOLUME\
  1126. 0x185FEDE3L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1127. DEFINE_GUIDSTRUCT("185FEDE3-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MASTER_VOLUME);
  1128. #define KSAUDFNAME_MASTER_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MASTER_VOLUME)
  1129. #define STATIC_KSAUDFNAME_MASTER_MUTE\
  1130. 0x185FEDE4L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1131. DEFINE_GUIDSTRUCT("185FEDE4-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MASTER_MUTE);
  1132. #define KSAUDFNAME_MASTER_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_MASTER_MUTE)
  1133. #define STATIC_KSAUDFNAME_WAVE_VOLUME\
  1134. 0x185FEDE5L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1135. DEFINE_GUIDSTRUCT("185FEDE5-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_WAVE_VOLUME);
  1136. #define KSAUDFNAME_WAVE_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_WAVE_VOLUME)
  1137. #define STATIC_KSAUDFNAME_WAVE_MUTE\
  1138. 0x185FEDE6L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1139. DEFINE_GUIDSTRUCT("185FEDE6-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_WAVE_MUTE);
  1140. #define KSAUDFNAME_WAVE_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_WAVE_MUTE)
  1141. #define STATIC_KSAUDFNAME_MIDI_VOLUME\
  1142. 0x185FEDE7L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1143. DEFINE_GUIDSTRUCT("185FEDE7-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIDI_VOLUME);
  1144. #define KSAUDFNAME_MIDI_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MIDI_VOLUME)
  1145. #define STATIC_KSAUDFNAME_MIDI_MUTE\
  1146. 0x185FEDE8L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1147. DEFINE_GUIDSTRUCT("185FEDE8-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIDI_MUTE);
  1148. #define KSAUDFNAME_MIDI_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_MIDI_MUTE)
  1149. #define STATIC_KSAUDFNAME_CD_VOLUME\
  1150. 0x185FEDE9L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1151. DEFINE_GUIDSTRUCT("185FEDE9-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_CD_VOLUME);
  1152. #define KSAUDFNAME_CD_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_CD_VOLUME)
  1153. #define STATIC_KSAUDFNAME_CD_MUTE\
  1154. 0x185FEDEAL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1155. DEFINE_GUIDSTRUCT("185FEDEA-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_CD_MUTE);
  1156. #define KSAUDFNAME_CD_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_CD_MUTE)
  1157. #define STATIC_KSAUDFNAME_LINE_VOLUME\
  1158. 0x185FEDEBL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1159. DEFINE_GUIDSTRUCT("185FEDEB-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_LINE_VOLUME);
  1160. #define KSAUDFNAME_LINE_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_LINE_VOLUME)
  1161. #define STATIC_KSAUDFNAME_LINE_MUTE\
  1162. 0x185FEDECL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1163. DEFINE_GUIDSTRUCT("185FEDEC-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_LINE_MUTE);
  1164. #define KSAUDFNAME_LINE_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_LINE_MUTE)
  1165. #define STATIC_KSAUDFNAME_MIC_VOLUME\
  1166. 0x185FEDEDL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1167. DEFINE_GUIDSTRUCT("185FEDED-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIC_VOLUME);
  1168. #define KSAUDFNAME_MIC_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MIC_VOLUME)
  1169. #define STATIC_KSAUDFNAME_MIC_MUTE\
  1170. 0x185FEDEEL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1171. DEFINE_GUIDSTRUCT("185FEDEE-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIC_MUTE);
  1172. #define KSAUDFNAME_MIC_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_MIC_MUTE)
  1173. #define STATIC_KSAUDFNAME_RECORDING_SOURCE\
  1174. 0x185FEDEFL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1175. DEFINE_GUIDSTRUCT("185FEDEF-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_RECORDING_SOURCE);
  1176. #define KSAUDFNAME_RECORDING_SOURCE DEFINE_GUIDNAMED(KSAUDFNAME_RECORDING_SOURCE)
  1177. #define STATIC_KSAUDFNAME_PC_SPEAKER_VOLUME\
  1178. 0x185FEDF0L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1179. DEFINE_GUIDSTRUCT("185FEDF0-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_PC_SPEAKER_VOLUME);
  1180. #define KSAUDFNAME_PC_SPEAKER_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_PC_SPEAKER_VOLUME)
  1181. #define STATIC_KSAUDFNAME_PC_SPEAKER_MUTE\
  1182. 0x185FEDF1L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1183. DEFINE_GUIDSTRUCT("185FEDF1-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_PC_SPEAKER_MUTE);
  1184. #define KSAUDFNAME_PC_SPEAKER_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_PC_SPEAKER_MUTE)
  1185. #define STATIC_KSAUDFNAME_MIDI_IN_VOLUME\
  1186. 0x185FEDF2L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1187. DEFINE_GUIDSTRUCT("185FEDF2-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIDI_IN_VOLUME);
  1188. #define KSAUDFNAME_MIDI_IN_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MIDI_IN_VOLUME)
  1189. #define STATIC_KSAUDFNAME_CD_IN_VOLUME\
  1190. 0x185FEDF3L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1191. DEFINE_GUIDSTRUCT("185FEDF3-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_CD_IN_VOLUME);
  1192. #define KSAUDFNAME_CD_IN_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_CD_IN_VOLUME)
  1193. #define STATIC_KSAUDFNAME_LINE_IN_VOLUME\
  1194. 0x185FEDF4L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1195. DEFINE_GUIDSTRUCT("185FEDF4-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_LINE_IN_VOLUME);
  1196. #define KSAUDFNAME_LINE_IN_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_LINE_IN_VOLUME)
  1197. #define STATIC_KSAUDFNAME_MIC_IN_VOLUME\
  1198. 0x185FEDF5L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1199. DEFINE_GUIDSTRUCT("185FEDF5-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIC_IN_VOLUME);
  1200. #define KSAUDFNAME_MIC_IN_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MIC_IN_VOLUME)
  1201. #define STATIC_KSAUDFNAME_WAVE_IN_VOLUME\
  1202. 0x185FEDF6L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1203. DEFINE_GUIDSTRUCT("185FEDF6-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_WAVE_IN_VOLUME);
  1204. #define KSAUDFNAME_WAVE_IN_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_WAVE_IN_VOLUME)
  1205. #define STATIC_KSAUDFNAME_VOLUME_CONTROL\
  1206. 0x185FEDF7L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1207. DEFINE_GUIDSTRUCT("185FEDF7-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_VOLUME_CONTROL);
  1208. #define KSAUDFNAME_VOLUME_CONTROL DEFINE_GUIDNAMED(KSAUDFNAME_VOLUME_CONTROL)
  1209. #define STATIC_KSAUDFNAME_MIDI\
  1210. 0x185FEDF8L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1211. DEFINE_GUIDSTRUCT("185FEDF8-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_MIDI);
  1212. #define KSAUDFNAME_MIDI DEFINE_GUIDNAMED(KSAUDFNAME_MIDI)
  1213. #define STATIC_KSAUDFNAME_LINE_IN\
  1214. 0x185FEDF9L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1215. DEFINE_GUIDSTRUCT("185FEDF9-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_LINE_IN);
  1216. #define KSAUDFNAME_LINE_IN DEFINE_GUIDNAMED(KSAUDFNAME_LINE_IN)
  1217. #define STATIC_KSAUDFNAME_RECORDING_CONTROL\
  1218. 0x185FEDFAL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1219. DEFINE_GUIDSTRUCT("185FEDFA-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_RECORDING_CONTROL);
  1220. #define KSAUDFNAME_RECORDING_CONTROL DEFINE_GUIDNAMED(KSAUDFNAME_RECORDING_CONTROL)
  1221. #define STATIC_KSAUDFNAME_CD_AUDIO\
  1222. 0x185FEDFBL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1223. DEFINE_GUIDSTRUCT("185FEDFB-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_CD_AUDIO);
  1224. #define KSAUDFNAME_CD_AUDIO DEFINE_GUIDNAMED(KSAUDFNAME_CD_AUDIO)
  1225. #define STATIC_KSAUDFNAME_AUX_VOLUME\
  1226. 0x185FEDFCL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1227. DEFINE_GUIDSTRUCT("185FEDFC-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_AUX_VOLUME);
  1228. #define KSAUDFNAME_AUX_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_AUX_VOLUME)
  1229. #define STATIC_KSAUDFNAME_AUX_MUTE\
  1230. 0x185FEDFDL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1231. DEFINE_GUIDSTRUCT("185FEDFD-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_AUX_MUTE);
  1232. #define KSAUDFNAME_AUX_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_AUX_MUTE)
  1233. #define STATIC_KSAUDFNAME_AUX\
  1234. 0x185FEDFEL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1235. DEFINE_GUIDSTRUCT("185FEDFE-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_AUX);
  1236. #define KSAUDFNAME_AUX DEFINE_GUIDNAMED(KSAUDFNAME_AUX)
  1237. #define STATIC_KSAUDFNAME_PC_SPEAKER\
  1238. 0x185FEDFFL, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1239. DEFINE_GUIDSTRUCT("185FEDFF-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_PC_SPEAKER);
  1240. #define KSAUDFNAME_PC_SPEAKER DEFINE_GUIDNAMED(KSAUDFNAME_PC_SPEAKER)
  1241. #define STATIC_KSAUDFNAME_WAVE_OUT_MIX\
  1242. 0x185FEE00L, 0x9905, 0x11D1, 0x95, 0xA9, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1243. DEFINE_GUIDSTRUCT("185FEE00-9905-11D1-95A9-00C04FB925D3", KSAUDFNAME_WAVE_OUT_MIX);
  1244. #define KSAUDFNAME_WAVE_OUT_MIX DEFINE_GUIDNAMED(KSAUDFNAME_WAVE_OUT_MIX)
  1245. #define STATIC_KSAUDFNAME_MONO_OUT\
  1246. 0xf9b41dc3L, 0x96e2, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1247. DEFINE_GUIDSTRUCT("F9B41DC3-96E2-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MONO_OUT);
  1248. #define KSAUDFNAME_MONO_OUT DEFINE_GUIDNAMED(KSAUDFNAME_MONO_OUT)
  1249. #define STATIC_KSAUDFNAME_STEREO_MIX\
  1250. 0xdff077L, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1251. DEFINE_GUIDSTRUCT("00DFF077-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_STEREO_MIX);
  1252. #define KSAUDFNAME_STEREO_MIX DEFINE_GUIDNAMED(KSAUDFNAME_STEREO_MIX)
  1253. #define STATIC_KSAUDFNAME_MONO_MIX\
  1254. 0xdff078L, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1255. DEFINE_GUIDSTRUCT("00DFF078-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MONO_MIX);
  1256. #define KSAUDFNAME_MONO_MIX DEFINE_GUIDNAMED(KSAUDFNAME_MONO_MIX)
  1257. #define STATIC_KSAUDFNAME_MONO_OUT_VOLUME\
  1258. 0x1ad247ebL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1259. DEFINE_GUIDSTRUCT("1AD247EB-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MONO_OUT_VOLUME);
  1260. #define KSAUDFNAME_MONO_OUT_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MONO_OUT_VOLUME)
  1261. #define STATIC_KSAUDFNAME_MONO_OUT_MUTE\
  1262. 0x1ad247ecL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1263. DEFINE_GUIDSTRUCT("1AD247EC-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MONO_OUT_MUTE);
  1264. #define KSAUDFNAME_MONO_OUT_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_MONO_OUT_MUTE)
  1265. #define STATIC_KSAUDFNAME_STEREO_MIX_VOLUME\
  1266. 0x1ad247edL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1267. DEFINE_GUIDSTRUCT("1AD247ED-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_STEREO_MIX_VOLUME);
  1268. #define KSAUDFNAME_STEREO_MIX_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_STEREO_MIX_VOLUME)
  1269. #define STATIC_KSAUDFNAME_STEREO_MIX_MUTE\
  1270. 0x22b0eafdL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1271. DEFINE_GUIDSTRUCT("22B0EAFD-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_STEREO_MIX_MUTE);
  1272. #define KSAUDFNAME_STEREO_MIX_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_STEREO_MIX_MUTE)
  1273. #define STATIC_KSAUDFNAME_MONO_MIX_VOLUME\
  1274. 0x22b0eafeL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1275. DEFINE_GUIDSTRUCT("22B0EAFE-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MONO_MIX_VOLUME);
  1276. #define KSAUDFNAME_MONO_MIX_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_MONO_MIX_VOLUME)
  1277. #define STATIC_KSAUDFNAME_MONO_MIX_MUTE\
  1278. 0x2bc31d69L, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1279. DEFINE_GUIDSTRUCT("2BC31D69-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MONO_MIX_MUTE);
  1280. #define KSAUDFNAME_MONO_MIX_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_MONO_MIX_MUTE)
  1281. #define STATIC_KSAUDFNAME_MICROPHONE_BOOST\
  1282. 0x2bc31d6aL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1283. DEFINE_GUIDSTRUCT("2BC31D6A-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_MICROPHONE_BOOST);
  1284. #define KSAUDFNAME_MICROPHONE_BOOST DEFINE_GUIDNAMED(KSAUDFNAME_MICROPHONE_BOOST)
  1285. #define STATIC_KSAUDFNAME_ALTERNATE_MICROPHONE\
  1286. 0x2bc31d6bL, 0x96e3, 0x11d2, 0xac, 0x4c, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1287. DEFINE_GUIDSTRUCT("2BC31D6B-96E3-11d2-AC4C-00C04F8EFB68", KSAUDFNAME_ALTERNATE_MICROPHONE);
  1288. #define KSAUDFNAME_ALTERNATE_MICROPHONE DEFINE_GUIDNAMED(KSAUDFNAME_ALTERNATE_MICROPHONE)
  1289. #define STATIC_KSAUDFNAME_3D_DEPTH\
  1290. 0x63ff5747L, 0x991f, 0x11d2, 0xac, 0x4d, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1291. DEFINE_GUIDSTRUCT("63FF5747-991F-11d2-AC4D-00C04F8EFB68", KSAUDFNAME_3D_DEPTH);
  1292. #define KSAUDFNAME_3D_DEPTH DEFINE_GUIDNAMED(KSAUDFNAME_3D_DEPTH)
  1293. #define STATIC_KSAUDFNAME_3D_CENTER\
  1294. 0x9f0670b4L, 0x991f, 0x11d2, 0xac, 0x4d, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1295. DEFINE_GUIDSTRUCT("9F0670B4-991F-11d2-AC4D-00C04F8EFB68", KSAUDFNAME_3D_CENTER);
  1296. #define KSAUDFNAME_3D_CENTER DEFINE_GUIDNAMED(KSAUDFNAME_3D_CENTER)
  1297. #define STATIC_KSAUDFNAME_VIDEO_VOLUME\
  1298. 0x9b46e708L, 0x992a, 0x11d2, 0xac, 0x4d, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1299. DEFINE_GUIDSTRUCT("9B46E708-992A-11d2-AC4D-00C04F8EFB68", KSAUDFNAME_VIDEO_VOLUME);
  1300. #define KSAUDFNAME_VIDEO_VOLUME DEFINE_GUIDNAMED(KSAUDFNAME_VIDEO_VOLUME)
  1301. #define STATIC_KSAUDFNAME_VIDEO_MUTE\
  1302. 0x9b46e709L, 0x992a, 0x11d2, 0xac, 0x4d, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1303. DEFINE_GUIDSTRUCT("9B46E709-992A-11d2-AC4D-00C04F8EFB68", KSAUDFNAME_VIDEO_MUTE);
  1304. #define KSAUDFNAME_VIDEO_MUTE DEFINE_GUIDNAMED(KSAUDFNAME_VIDEO_MUTE)
  1305. #define STATIC_KSAUDFNAME_VIDEO\
  1306. 0x915daec4L, 0xa434, 0x11d2, 0xac, 0x52, 0x0, 0xc0, 0x4f, 0x8e, 0xfb, 0x68
  1307. DEFINE_GUIDSTRUCT("915DAEC4-A434-11d2-AC52-00C04F8EFB68", KSAUDFNAME_VIDEO);
  1308. #define KSAUDFNAME_VIDEO DEFINE_GUIDNAMED(KSAUDFNAME_VIDEO)
  1309. #define STATIC_KSAUDFNAME_PEAKMETER\
  1310. 0x57e24340L, 0xfc5b, 0x4612, 0xa5, 0x62, 0x72, 0xb1, 0x1a, 0x29, 0xdf, 0xae
  1311. DEFINE_GUIDSTRUCT("57E24340-FC5B-4612-A562-72B11A29DFAE", KSAUDFNAME_PEAKMETER);
  1312. #define KSAUDFNAME_PEAKMETER DEFINE_GUIDNAMED(KSAUDFNAME_PEAKMETER)
  1313. // Internal topology node pin definitions
  1314. #define KSNODEPIN_STANDARD_IN 1
  1315. #define KSNODEPIN_STANDARD_OUT 0
  1316. #define KSNODEPIN_SUM_MUX_IN 1 // can be >= 1
  1317. #define KSNODEPIN_SUM_MUX_OUT 0
  1318. #define KSNODEPIN_DEMUX_IN 0
  1319. #define KSNODEPIN_DEMUX_OUT 1 // can be >= 1
  1320. #define KSNODEPIN_AEC_RENDER_IN 1
  1321. #define KSNODEPIN_AEC_RENDER_OUT 0
  1322. #define KSNODEPIN_AEC_CAPTURE_IN 2
  1323. #define KSNODEPIN_AEC_CAPTURE_OUT 3
  1324. //===========================================================================
  1325. //===========================================================================
  1326. #define STATIC_KSMETHODSETID_Wavetable\
  1327. 0xDCEF31EBL, 0xD907, 0x11D0, 0x95, 0x83, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1328. DEFINE_GUIDSTRUCT("DCEF31EB-D907-11D0-9583-00C04FB925D3", KSMETHODSETID_Wavetable);
  1329. #define KSMETHODSETID_Wavetable DEFINE_GUIDNAMED(KSMETHODSETID_Wavetable)
  1330. typedef enum {
  1331. KSMETHOD_WAVETABLE_WAVE_ALLOC,
  1332. KSMETHOD_WAVETABLE_WAVE_FREE,
  1333. KSMETHOD_WAVETABLE_WAVE_FIND,
  1334. KSMETHOD_WAVETABLE_WAVE_WRITE
  1335. } KSMETHOD_WAVETABLE;
  1336. typedef struct {
  1337. KSIDENTIFIER Identifier; // wave identifier
  1338. ULONG Size; // wave size
  1339. BOOL Looped; // wave looped flag
  1340. ULONG LoopPoint; // wave loop point
  1341. BOOL InROM; // wave InROM flag
  1342. KSDATAFORMAT Format; // wave format
  1343. } KSWAVETABLE_WAVE_DESC, *PKSWAVETABLE_WAVE_DESC;
  1344. //===========================================================================
  1345. //===========================================================================
  1346. /*
  1347. Property sets and items
  1348. */
  1349. //===========================================================================
  1350. //===========================================================================
  1351. #define STATIC_KSPROPSETID_Acoustic_Echo_Cancel\
  1352. 0xd7a4af8bL, 0x3dc1, 0x4902, 0x91, 0xea, 0x8a, 0x15, 0xc9, 0x0e, 0x05, 0xb2
  1353. DEFINE_GUIDSTRUCT("D7A4AF8B-3DC1-4902-91EA-8A15C90E05B2", KSPROPSETID_Acoustic_Echo_Cancel);
  1354. #define KSPROPSETID_Acoustic_Echo_Cancel DEFINE_GUIDNAMED(KSPROPSETID_Acoustic_Echo_Cancel)
  1355. typedef enum {
  1356. KSPROPERTY_AEC_NOISE_FILL_ENABLE = 0,
  1357. KSPROPERTY_AEC_STATUS,
  1358. KSPROPERTY_AEC_MODE
  1359. } KSPROPERTY_AEC;
  1360. #define AEC_STATUS_FD_HISTORY_UNINITIALIZED 0x0
  1361. #define AEC_STATUS_FD_HISTORY_CONTINUOUSLY_CONVERGED 0x1
  1362. #define AEC_STATUS_FD_HISTORY_PREVIOUSLY_DIVERGED 0x2
  1363. #define AEC_STATUS_FD_CURRENTLY_CONVERGED 0x8
  1364. #define AEC_MODE_PASS_THROUGH 0x0
  1365. #define AEC_MODE_HALF_DUPLEX 0x1
  1366. #define AEC_MODE_FULL_DUPLEX 0x2
  1367. //===========================================================================
  1368. //===========================================================================
  1369. #define STATIC_KSPROPSETID_Wave_Queued\
  1370. 0x16a15b10L, 0x16f0, 0x11d0, 0xa1, 0x95, 0x00, 0x20, 0xaf, 0xd1, 0x56, 0xe4
  1371. DEFINE_GUIDSTRUCT("16a15b10-16f0-11d0-a195-0020afd156e4", KSPROPSETID_Wave_Queued);
  1372. #define KSPROPSETID_Wave_Queued DEFINE_GUIDNAMED(KSPROPSETID_Wave_Queued)
  1373. #define KSPROPERTY_WAVE_QUEUED_POSITION 0x00000001
  1374. #define STATIC_KSMETHODSETID_Wave_Queued\
  1375. 0x7432c160L, 0x8827, 0x11cf, 0xa1, 0x02, 0x00, 0x20, 0xaf, 0xd1, 0x56, 0xe4
  1376. DEFINE_GUIDSTRUCT("7432c160-8827-11cf-a102-0020afd156e4", KSMETHODSETID_Wave_Queued);
  1377. #define KSMETHODSETID_Wave_Queued DEFINE_GUIDNAMED(KSMETHODSETID_Wave_Queued)
  1378. #define KSMETHOD_WAVE_QUEUED_BREAKLOOP 0x00000001
  1379. #define STATIC_KSPROPSETID_Wave\
  1380. 0x924e54b0L, 0x630f, 0x11cf, 0xad, 0xa7, 0x08, 0x00, 0x3e, 0x30, 0x49, 0x4a
  1381. DEFINE_GUIDSTRUCT("924e54b0-630f-11cf-ada7-08003e30494a", KSPROPSETID_Wave);
  1382. #define KSPROPSETID_Wave DEFINE_GUIDNAMED(KSPROPSETID_Wave)
  1383. typedef enum {
  1384. KSPROPERTY_WAVE_COMPATIBLE_CAPABILITIES,
  1385. KSPROPERTY_WAVE_INPUT_CAPABILITIES,
  1386. KSPROPERTY_WAVE_OUTPUT_CAPABILITIES,
  1387. KSPROPERTY_WAVE_BUFFER,
  1388. KSPROPERTY_WAVE_FREQUENCY,
  1389. KSPROPERTY_WAVE_VOLUME,
  1390. KSPROPERTY_WAVE_PAN
  1391. } KSPROPERTY_WAVE;
  1392. typedef struct {
  1393. ULONG ulDeviceType;
  1394. } KSWAVE_COMPATCAPS, *PKSWAVE_COMPATCAPS;
  1395. #define KSWAVE_COMPATCAPS_INPUT 0x00000000
  1396. #define KSWAVE_COMPATCAPS_OUTPUT 0x00000001
  1397. typedef struct {
  1398. ULONG MaximumChannelsPerConnection;
  1399. ULONG MinimumBitsPerSample;
  1400. ULONG MaximumBitsPerSample;
  1401. ULONG MinimumSampleFrequency;
  1402. ULONG MaximumSampleFrequency;
  1403. ULONG TotalConnections;
  1404. ULONG ActiveConnections;
  1405. } KSWAVE_INPUT_CAPABILITIES, *PKSWAVE_INPUT_CAPABILITIES;
  1406. typedef struct {
  1407. ULONG MaximumChannelsPerConnection;
  1408. ULONG MinimumBitsPerSample;
  1409. ULONG MaximumBitsPerSample;
  1410. ULONG MinimumSampleFrequency;
  1411. ULONG MaximumSampleFrequency;
  1412. ULONG TotalConnections;
  1413. ULONG StaticConnections;
  1414. ULONG StreamingConnections;
  1415. ULONG ActiveConnections;
  1416. ULONG ActiveStaticConnections;
  1417. ULONG ActiveStreamingConnections;
  1418. ULONG Total3DConnections;
  1419. ULONG Static3DConnections;
  1420. ULONG Streaming3DConnections;
  1421. ULONG Active3DConnections;
  1422. ULONG ActiveStatic3DConnections;
  1423. ULONG ActiveStreaming3DConnections;
  1424. ULONG TotalSampleMemory;
  1425. ULONG FreeSampleMemory;
  1426. ULONG LargestFreeContiguousSampleMemory;
  1427. } KSWAVE_OUTPUT_CAPABILITIES, *PKSWAVE_OUTPUT_CAPABILITIES;
  1428. typedef struct {
  1429. LONG LeftAttenuation;
  1430. LONG RightAttenuation;
  1431. } KSWAVE_VOLUME, *PKSWAVE_VOLUME;
  1432. #define KSWAVE_BUFFER_ATTRIBUTEF_LOOPING 0x00000001
  1433. #define KSWAVE_BUFFER_ATTRIBUTEF_STATIC 0x00000002
  1434. typedef struct {
  1435. ULONG Attributes;
  1436. ULONG BufferSize;
  1437. PVOID BufferAddress;
  1438. } KSWAVE_BUFFER, *PKSWAVE_BUFFER;
  1439. //===========================================================================
  1440. //===========================================================================
  1441. #define STATIC_KSMUSIC_TECHNOLOGY_PORT\
  1442. 0x86C92E60L, 0x62E8, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1443. DEFINE_GUIDSTRUCT("86C92E60-62E8-11CF-A5D6-28DB04C10000", KSMUSIC_TECHNOLOGY_PORT);
  1444. #define KSMUSIC_TECHNOLOGY_PORT DEFINE_GUIDNAMED(KSMUSIC_TECHNOLOGY_PORT)
  1445. #define STATIC_KSMUSIC_TECHNOLOGY_SQSYNTH\
  1446. 0x0ECF4380L, 0x62E9, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1447. DEFINE_GUIDSTRUCT("0ECF4380-62E9-11CF-A5D6-28DB04C10000", KSMUSIC_TECHNOLOGY_SQSYNTH);
  1448. #define KSMUSIC_TECHNOLOGY_SQSYNTH DEFINE_GUIDNAMED(KSMUSIC_TECHNOLOGY_SQSYNTH)
  1449. #define STATIC_KSMUSIC_TECHNOLOGY_FMSYNTH\
  1450. 0x252C5C80L, 0x62E9, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1451. DEFINE_GUIDSTRUCT("252C5C80-62E9-11CF-A5D6-28DB04C10000", KSMUSIC_TECHNOLOGY_FMSYNTH);
  1452. #define KSMUSIC_TECHNOLOGY_FMSYNTH DEFINE_GUIDNAMED(KSMUSIC_TECHNOLOGY_FMSYNTH)
  1453. #define STATIC_KSMUSIC_TECHNOLOGY_WAVETABLE\
  1454. 0x394EC7C0L, 0x62E9, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1455. DEFINE_GUIDSTRUCT("394EC7C0-62E9-11CF-A5D6-28DB04C10000", KSMUSIC_TECHNOLOGY_WAVETABLE);
  1456. #define KSMUSIC_TECHNOLOGY_WAVETABLE DEFINE_GUIDNAMED(KSMUSIC_TECHNOLOGY_WAVETABLE)
  1457. #define STATIC_KSMUSIC_TECHNOLOGY_SWSYNTH\
  1458. 0x37407736L, 0x3620, 0x11D1, 0x85, 0xD3, 0x00, 0x00, 0xF8, 0x75, 0x43, 0x80
  1459. DEFINE_GUIDSTRUCT("37407736-3620-11D1-85D3-0000F8754380", KSMUSIC_TECHNOLOGY_SWSYNTH);
  1460. #define KSMUSIC_TECHNOLOGY_SWSYNTH DEFINE_GUIDNAMED(KSMUSIC_TECHNOLOGY_SWSYNTH)
  1461. #define STATIC_KSPROPSETID_WaveTable\
  1462. 0x8539E660L, 0x62E9, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1463. DEFINE_GUIDSTRUCT("8539E660-62E9-11CF-A5D6-28DB04C10000", KSPROPSETID_WaveTable);
  1464. #define KSPROPSETID_WaveTable DEFINE_GUIDNAMED(KSPROPSETID_WaveTable)
  1465. typedef enum {
  1466. KSPROPERTY_WAVETABLE_LOAD_SAMPLE,
  1467. KSPROPERTY_WAVETABLE_UNLOAD_SAMPLE,
  1468. KSPROPERTY_WAVETABLE_MEMORY,
  1469. KSPROPERTY_WAVETABLE_VERSION
  1470. } KSPROPERTY_WAVETABLE;
  1471. typedef struct {
  1472. KSDATARANGE DataRange;
  1473. GUID Technology;
  1474. ULONG Channels;
  1475. ULONG Notes;
  1476. ULONG ChannelMask;
  1477. } KSDATARANGE_MUSIC, *PKSDATARANGE_MUSIC;
  1478. //===========================================================================
  1479. #define STATIC_KSEVENTSETID_Cyclic\
  1480. 0x142C1AC0L, 0x072A, 0x11D0, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1481. DEFINE_GUIDSTRUCT("142C1AC0-072A-11D0-A5D6-28DB04C10000", KSEVENTSETID_Cyclic);
  1482. #define KSEVENTSETID_Cyclic DEFINE_GUIDNAMED(KSEVENTSETID_Cyclic)
  1483. typedef enum {
  1484. KSEVENT_CYCLIC_TIME_INTERVAL,
  1485. } KSEVENT_CYCLIC_TIME;
  1486. #define STATIC_KSPROPSETID_Cyclic\
  1487. 0x3FFEAEA0L, 0x2BEE, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1488. DEFINE_GUIDSTRUCT("3FFEAEA0-2BEE-11CF-A5D6-28DB04C10000", KSPROPSETID_Cyclic);
  1489. #define KSPROPSETID_Cyclic DEFINE_GUIDNAMED(KSPROPSETID_Cyclic)
  1490. typedef enum {
  1491. KSPROPERTY_CYCLIC_POSITION,
  1492. } KSPROPERTY_CYCLIC;
  1493. //===========================================================================
  1494. #define STATIC_KSEVENTSETID_AudioControlChange\
  1495. 0xE85E9698L, 0xFA2F, 0x11D1, 0x95, 0xBD, 0x00, 0xC0, 0x4F, 0xB9, 0x25, 0xD3
  1496. DEFINE_GUIDSTRUCT("E85E9698-FA2F-11D1-95BD-00C04FB925D3", KSEVENTSETID_AudioControlChange);
  1497. #define KSEVENTSETID_AudioControlChange DEFINE_GUIDNAMED(KSEVENTSETID_AudioControlChange)
  1498. typedef enum {
  1499. KSEVENT_CONTROL_CHANGE,
  1500. } KSEVENT_AUDIO_CONTROL_CHANGE;
  1501. //===========================================================================
  1502. #define STATIC_KSEVENTSETID_LoopedStreaming\
  1503. 0x4682B940L, 0xC6EF, 0x11D0, 0x96, 0xD8, 0x00, 0xAA, 0x00, 0x51, 0xE5, 0x1D
  1504. DEFINE_GUIDSTRUCT("4682B940-C6EF-11D0-96D8-00AA0051E51D", KSEVENTSETID_LoopedStreaming);
  1505. #define KSEVENTSETID_LoopedStreaming DEFINE_GUIDNAMED(KSEVENTSETID_LoopedStreaming)
  1506. typedef enum {
  1507. KSEVENT_LOOPEDSTREAMING_POSITION,
  1508. } KSEVENT_LOOPEDSTREAMING;
  1509. typedef struct {
  1510. KSEVENTDATA KsEventData;
  1511. #if defined(_NTDDK_)
  1512. ULONGLONG Position;
  1513. #else // !_NTDDK_
  1514. DWORDLONG Position;
  1515. #endif // !_NTDDK_
  1516. } LOOPEDSTREAMING_POSITION_EVENT_DATA, *PLOOPEDSTREAMING_POSITION_EVENT_DATA ;
  1517. // @@BEGIN_DDKSPLIT
  1518. //===========================================================================
  1519. #define STATIC_KSEVENTSETID_Sysaudio \
  1520. 0x04800320L, 0x4491, 0x11D1, 0xA0, 0x50, 0x40, 0x57, 0x05, 0xC1, 0x00, 0x00
  1521. DEFINE_GUIDSTRUCT("04800320-4491-11D1-A050-405705C10000", KSEVENTSETID_Sysaudio);
  1522. #define KSEVENTSETID_Sysaudio DEFINE_GUIDNAMED(KSEVENTSETID_Sysaudio)
  1523. typedef enum {
  1524. KSEVENT_SYSAUDIO_ADDREMOVE_DEVICE,
  1525. KSEVENT_SYSAUDIO_CHANGE_DEVICE
  1526. } KSEVENT_SYSAUDIO;
  1527. // @@END_DDKSPLIT
  1528. //===========================================================================
  1529. #define STATIC_KSPROPSETID_Sysaudio\
  1530. 0xCBE3FAA0L, 0xCC75, 0x11D0, 0xB4, 0x65, 0x00, 0x00, 0x1A, 0x18, 0x18, 0xE6
  1531. DEFINE_GUIDSTRUCT("CBE3FAA0-CC75-11D0-B465-00001A1818E6", KSPROPSETID_Sysaudio);
  1532. #define KSPROPSETID_Sysaudio DEFINE_GUIDNAMED(KSPROPSETID_Sysaudio)
  1533. typedef enum {
  1534. KSPROPERTY_SYSAUDIO_DEVICE_COUNT = 1,
  1535. KSPROPERTY_SYSAUDIO_DEVICE_FRIENDLY_NAME = 2,
  1536. KSPROPERTY_SYSAUDIO_DEVICE_INSTANCE = 3,
  1537. KSPROPERTY_SYSAUDIO_DEVICE_INTERFACE_NAME = 4,
  1538. KSPROPERTY_SYSAUDIO_SELECT_GRAPH = 5,
  1539. KSPROPERTY_SYSAUDIO_CREATE_VIRTUAL_SOURCE = 6,
  1540. KSPROPERTY_SYSAUDIO_DEVICE_DEFAULT = 7,
  1541. // @@BEGIN_DDKSPLIT
  1542. KSPROPERTY_SYSAUDIO_ALWAYS_CREATE_VIRTUAL_SOURCE = 8,
  1543. KSPROPERTY_SYSAUDIO_ADDREMOVE_LOCK = 9,
  1544. KSPROPERTY_SYSAUDIO_ADDREMOVE_UNLOCK = 10,
  1545. KSPROPERTY_SYSAUDIO_RENDER_PIN_INSTANCES = 11,
  1546. KSPROPERTY_SYSAUDIO_RENDER_CONNECTION_INDEX = 12,
  1547. KSPROPERTY_SYSAUDIO_CREATE_VIRTUAL_SOURCE_ONLY = 13,
  1548. // @@END_DDKSPLIT
  1549. KSPROPERTY_SYSAUDIO_INSTANCE_INFO = 14,
  1550. // @@BEGIN_DDKSPLIT
  1551. KSPROPERTY_SYSAUDIO_PREFERRED_DEVICE = 15,
  1552. // @@END_DDKSPLIT
  1553. KSPROPERTY_SYSAUDIO_COMPONENT_ID = 16,
  1554. // @@BEGIN_DDKSPLIT
  1555. KSPROPERTY_SYSAUDIO_ADDREMOVE_GFX = 17
  1556. // @@END_DDKSPLIT
  1557. } KSPROPERTY_SYSAUDIO;
  1558. typedef struct {
  1559. KSPROPERTY Property;
  1560. GUID PinCategory;
  1561. GUID PinName;
  1562. } SYSAUDIO_CREATE_VIRTUAL_SOURCE, *PSYSAUDIO_CREATE_VIRTUAL_SOURCE;
  1563. // @@BEGIN_DDKSPLIT
  1564. typedef struct {
  1565. BOOL Enable;
  1566. HANDLE hGfx;
  1567. ULONG ulOrder; // Order of the GFX
  1568. ULONG ulType; // Type of the GFX
  1569. ULONG ulFlags;
  1570. ULONG ulDeviceNameOffset; // DeviceInterface on which this GFX needs to be attached
  1571. ULONG ulFriendlyNameOffset; // Friendly name of the GFX
  1572. } SYSAUDIO_GFX, *PSYSAUDIO_GFX;
  1573. #define GFX_DEVICETYPE_RENDER 1
  1574. #define GFX_DEVICETYPE_CAPTURE 2
  1575. // @@END_DDKSPLIT
  1576. typedef struct {
  1577. KSPROPERTY Property;
  1578. ULONG PinId;
  1579. ULONG NodeId;
  1580. ULONG Flags;
  1581. ULONG Reserved;
  1582. } SYSAUDIO_SELECT_GRAPH, *PSYSAUDIO_SELECT_GRAPH;
  1583. typedef struct {
  1584. KSPROPERTY Property;
  1585. ULONG Flags;
  1586. ULONG DeviceNumber;
  1587. } SYSAUDIO_INSTANCE_INFO, *PSYSAUDIO_INSTANCE_INFO;
  1588. #define SYSAUDIO_FLAGS_DONT_COMBINE_PINS 0x00000001
  1589. // @@BEGIN_DDKSPLIT
  1590. typedef struct {
  1591. KSPROPERTY Property;
  1592. ULONG Flags;
  1593. ULONG Index; // KSPROPERTY_SYSAUDIO_DEFAULT_TYPE
  1594. } SYSAUDIO_PREFERRED_DEVICE, *PSYSAUDIO_PREFERRED_DEVICE;
  1595. #define SYSAUDIO_FLAGS_CLEAR_PREFERRED 0x00000002
  1596. // @@END_DDKSPLIT
  1597. #define STATIC_KSPROPSETID_Sysaudio_Pin \
  1598. 0xA3A53220L, 0xC6E4, 0x11D0, 0xB4, 0x65, 0x00, 0x00, 0x1A, 0x18, 0x18, 0xE6
  1599. DEFINE_GUIDSTRUCT("A3A53220-C6E4-11D0-B465-00001A1818E6", KSPROPSETID_Sysaudio_Pin);
  1600. #define KSPROPSETID_Sysaudio_Pin DEFINE_GUIDNAMED(KSPROPSETID_Sysaudio_Pin)
  1601. typedef enum {
  1602. // @@BEGIN_DDKSPLIT
  1603. KSPROPERTY_SYSAUDIO_TOPOLOGY_CONNECTION_INDEX = 0,
  1604. // @@END_DDKSPLIT
  1605. KSPROPERTY_SYSAUDIO_ATTACH_VIRTUAL_SOURCE = 1,
  1606. // @@BEGIN_DDKSPLIT
  1607. KSPROPERTY_SYSAUDIO_PIN_VOLUME_NODE = 2
  1608. // @@END_DDKSPLIT
  1609. } KSPROPERTY_SYSAUDIO_PIN;
  1610. typedef struct {
  1611. KSPROPERTY Property;
  1612. ULONG MixerPinId;
  1613. ULONG Reserved;
  1614. } SYSAUDIO_ATTACH_VIRTUAL_SOURCE, *PSYSAUDIO_ATTACH_VIRTUAL_SOURCE;
  1615. //===========================================================================
  1616. typedef struct {
  1617. KSPROPERTY Property;
  1618. ULONG NodeId;
  1619. ULONG Reserved;
  1620. } KSNODEPROPERTY, *PKSNODEPROPERTY;
  1621. typedef struct {
  1622. KSNODEPROPERTY NodeProperty;
  1623. LONG Channel; // value to get or set
  1624. ULONG Reserved;
  1625. } KSNODEPROPERTY_AUDIO_CHANNEL, *PKSNODEPROPERTY_AUDIO_CHANNEL;
  1626. typedef struct {
  1627. KSNODEPROPERTY NodeProperty;
  1628. ULONG DevSpecificId;
  1629. ULONG DeviceInfo;
  1630. ULONG Length;
  1631. } KSNODEPROPERTY_AUDIO_DEV_SPECIFIC, *PKSNODEPROPERTY_AUDIO_DEV_SPECIFIC;
  1632. typedef struct {
  1633. KSNODEPROPERTY NodeProperty;
  1634. PVOID ListenerId;
  1635. #ifndef _WIN64
  1636. ULONG Reserved;
  1637. #endif // _WIN64
  1638. } KSNODEPROPERTY_AUDIO_3D_LISTENER, *PKSNODEPROPERTY_AUDIO_3D_LISTENER;
  1639. typedef struct {
  1640. KSNODEPROPERTY NodeProperty;
  1641. PVOID AppContext;
  1642. ULONG Length;
  1643. #ifndef _WIN64
  1644. ULONG Reserved;
  1645. #endif // _WIN64
  1646. } KSNODEPROPERTY_AUDIO_PROPERTY, *PKSNODEPROPERTY_AUDIO_PROPERTY;
  1647. //===========================================================================
  1648. // {79A9312E-59AE-43b0-A350-8B05284CAB24}
  1649. #define STATIC_KSPROPSETID_AudioGfx\
  1650. 0x79a9312eL, 0x59ae, 0x43b0, 0xa3, 0x50, 0x8b, 0x5, 0x28, 0x4c, 0xab, 0x24
  1651. DEFINE_GUIDSTRUCT("79A9312E-59AE-43b0-A350-8B05284CAB24", KSPROPSETID_AudioGfx);
  1652. #define KSPROPSETID_AudioGfx DEFINE_GUIDNAMED(KSPROPSETID_AudioGfx)
  1653. typedef enum {
  1654. KSPROPERTY_AUDIOGFX_RENDERTARGETDEVICEID,
  1655. KSPROPERTY_AUDIOGFX_CAPTURETARGETDEVICEID
  1656. } KSPROPERTY_AUDIOGFX;
  1657. //===========================================================================
  1658. #define STATIC_KSPROPSETID_Linear\
  1659. 0x5A2FFE80L, 0x16B9, 0x11D0, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1660. DEFINE_GUIDSTRUCT("5A2FFE80-16B9-11D0-A5D6-28DB04C10000", KSPROPSETID_Linear);
  1661. #define KSPROPSETID_Linear DEFINE_GUIDNAMED(KSPROPSETID_Linear)
  1662. typedef enum {
  1663. KSPROPERTY_LINEAR_POSITION,
  1664. } KSPROPERTY_LINEAR;
  1665. //===========================================================================
  1666. //
  1667. // Midi definitions
  1668. //
  1669. /*
  1670. Formats
  1671. */
  1672. #define STATIC_KSDATAFORMAT_TYPE_MUSIC\
  1673. 0xE725D360L, 0x62CC, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1674. DEFINE_GUIDSTRUCT("E725D360-62CC-11CF-A5D6-28DB04C10000", KSDATAFORMAT_TYPE_MUSIC);
  1675. #define KSDATAFORMAT_TYPE_MUSIC DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_MUSIC)
  1676. // 'mids' == MEDIATYPE_Midi
  1677. #define STATIC_KSDATAFORMAT_TYPE_MIDI\
  1678. 0x7364696DL, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71
  1679. DEFINE_GUIDSTRUCT("7364696D-0000-0010-8000-00aa00389b71", KSDATAFORMAT_TYPE_MIDI);
  1680. #define KSDATAFORMAT_TYPE_MIDI DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_MIDI)
  1681. #define STATIC_KSDATAFORMAT_SUBTYPE_MIDI\
  1682. 0x1D262760L, 0xE957, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1683. DEFINE_GUIDSTRUCT("1D262760-E957-11CF-A5D6-28DB04C10000", KSDATAFORMAT_SUBTYPE_MIDI);
  1684. #define KSDATAFORMAT_SUBTYPE_MIDI DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MIDI)
  1685. #define STATIC_KSDATAFORMAT_SUBTYPE_MIDI_BUS\
  1686. 0x2CA15FA0L, 0x6CFE, 0x11CF, 0xA5, 0xD6, 0x28, 0xDB, 0x04, 0xC1, 0x00, 0x00
  1687. DEFINE_GUIDSTRUCT("2CA15FA0-6CFE-11CF-A5D6-28DB04C10000", KSDATAFORMAT_SUBTYPE_MIDI_BUS);
  1688. #define KSDATAFORMAT_SUBTYPE_MIDI_BUS DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MIDI_BUS)
  1689. #define STATIC_KSDATAFORMAT_SUBTYPE_RIFFMIDI\
  1690. 0x4995DAF0L, 0x9EE6, 0x11D0, 0xA4, 0x0E, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  1691. DEFINE_GUIDSTRUCT("4995DAF0-9EE6-11D0-A40E-00A0C9223196", KSDATAFORMAT_SUBTYPE_RIFFMIDI);
  1692. #define KSDATAFORMAT_SUBTYPE_RIFFMIDI DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_RIFFMIDI)
  1693. /*
  1694. KSDATAFORMAT_SUBTYPE_DIRECTMUSIC
  1695. see DMusicKS.h
  1696. */
  1697. // WARNING! This structure MUST be dword aligned
  1698. // regardless of the number of data bytes.
  1699. typedef struct {
  1700. ULONG TimeDeltaMs; // Delta Milliseconds from the previous midiformat
  1701. // in the packet. The first midiformat in the packet
  1702. // is a delta from the PTS in the KSSTREAM_HEADER.
  1703. ULONG ByteCount; // Number of bytes of data that follow this struct.
  1704. } KSMUSICFORMAT, *PKSMUSICFORMAT;
  1705. //
  1706. // This entire set of MPEG Standard/Dialect Guids are obsolete. Do not use them.
  1707. //
  1708. //====================================================================================================
  1709. //====================================================================================================
  1710. // The following official MPEG Formats, Subtypes and Specifiers are listed as required or optional
  1711. // These official MPEG GUIDs are the preferred method of supporting MPEG/AC-3 media types in new code.
  1712. // Older MPEG GUIDs should also be supported for compatibilty, but these new modes are still required.
  1713. //====================================================================================================
  1714. //====================================================================================================
  1715. /*
  1716. This is a summary of what media types/specifiers will be required for all DVD+DSS+DVB+DTV MPEG decoders.
  1717. These media types are what the decoder driver must accept, hardware support for all of these media types
  1718. may or may not actually be provided by the decoder natively. These media types are intended to define
  1719. the "officially" supported MPEG/AC-3 media types that all WHQL certified decoders must implement. This
  1720. specifically includes driver and/or hardware support for all the required standards and dialects.
  1721. All MPEG video decoders must support all of the MPEG video modes shown as [required] below.
  1722. All MPEG audio decoders must support all of the MPEG audio modes shown as [required] below.
  1723. All AC-3 audio decoders must support all of the AC-3 audio modes shown as [required] below.
  1724. The line items shown as [optional] need not be implemented, but are possible formats that might be implemented.
  1725. Note that the input/output pin formats are defined by 2 or 3 GUIDs: TYPE, SUBTYPE, and maybe SPECIFIER.
  1726. The specifiers are included if the data format is a "dialect" that needs to be differentiated during decoding.
  1727. The decoder MUST be prepared to deal with ALL requests for _required_ "Standard" formats OR _required_ "Dialects".
  1728. STATIC_KSDATAFORMAT_TYPE_STANDARD_ELEMENTARY_STREAM [required]
  1729. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO [required]
  1730. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO [optional]
  1731. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO [required]
  1732. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO [optional]
  1733. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO [required]
  1734. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO [required]
  1735. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO [required]
  1736. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO [optional]
  1737. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO [required]
  1738. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO [optional]
  1739. STATIC_KSDATAFORMAT_TYPE_STANDARD_PES_PACKET [required]
  1740. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO [optional]
  1741. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO [optional]
  1742. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO [optional]
  1743. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO [optional]
  1744. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO [required]
  1745. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO [required]
  1746. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO [required]
  1747. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO [required]
  1748. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO [required]
  1749. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO [optional]
  1750. STATIC_KSDATAFORMAT_TYPE_STANDARD_PACK_HEADER [required]
  1751. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO [required]
  1752. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO [required]
  1753. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO [required]
  1754. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO [optional]
  1755. STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO [required]
  1756. STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO [optional]
  1757. Note that the SPECIFIER GUIDs normally identify particular versions of MPEG such as DSS and DVD.
  1758. This approach was taken to minimize the number of DSS/DVB/DVD/DTV etc. media SUBTYPES.
  1759. These specifiers are currently required to disambiguate MPEG syntax _parsing_ by the decoder
  1760. using alternate parsing routines or downloadable firmware or hardware decode settings.
  1761. In the future these specifiers will be extended to cover new KS MPEG flavors such as DVB and DTV.
  1762. Thus, the optional specifiers will be subject to clarification and/or definition as they are needed.
  1763. Important note: Per the ITU MPEG specs, MPEG 2 media may contain pure MPEG 1 syntax and
  1764. any "MPEG 2" PES packets may actually contain MPEG 1 payloads and MPEG 1 syntax. Some MPEG
  1765. broadcasts can revert from MPEG2 to MPEG1 format data at their discretion, without warning.
  1766. CAUTION: Decoders MUST attempt to process MPEG data AS SOON AS POSSIBLE after reception.
  1767. In particular, elementary MPEG or MPEG PES packet streams should not be aggregated into DVD
  1768. "pack headers" internally before submission to the codec hardware if AT ALL POSSIBLE. The
  1769. reason is that mpeg data may need to be processed immediately but there may be no additional
  1770. MPEG data forthcoming to fill up the PES packet OR DVD "pack" in a timely fashion. This is
  1771. particularly true of MPEG dialects that utilize "repeat field signally" to reuse the last
  1772. decoded MPEG video field.
  1773. */
  1774. /////////////////////////////////////////////////////////////////////////
  1775. // The major data type GUIDs that define the data packet encapsulation //
  1776. /////////////////////////////////////////////////////////////////////////
  1777. // STATIC_KSDATAFORMAT_TYPE_STANDARD_ELEMENTARY_STREAM
  1778. #define STATIC_KSDATAFORMAT_TYPE_STANDARD_ELEMENTARY_STREAM \
  1779. 0x36523b11L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1780. DEFINE_GUIDSTRUCT("36523B11-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_TYPE_STANDARD_ELEMENTARY_STREAM );
  1781. #define KSDATAFORMAT_TYPE_STANDARD_ELEMENTARY_STREAM DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_STANDARD_ELEMENTARY_STREAM)
  1782. // STATIC_KSDATAFORMAT_TYPE_STANDARD_PES_PACKET
  1783. #define STATIC_KSDATAFORMAT_TYPE_STANDARD_PES_PACKET \
  1784. 0x36523b12L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1785. DEFINE_GUIDSTRUCT("36523B12-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_TYPE_STANDARD_PES_PACKET );
  1786. #define KSDATAFORMAT_TYPE_STANDARD_PES_PACKET DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_STANDARD_PES_PACKET)
  1787. // STATIC_KSDATAFORMAT_TYPE_STANDARD_PACK_HEADER
  1788. #define STATIC_KSDATAFORMAT_TYPE_STANDARD_PACK_HEADER \
  1789. 0x36523b13L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1790. DEFINE_GUIDSTRUCT("36523B13-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_TYPE_STANDARD_PACK_HEADER );
  1791. #define KSDATAFORMAT_TYPE_STANDARD_PACK_HEADER DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_STANDARD_PACK_HEADER)
  1792. ///////////////////////////////////////////////////////////////////////////////
  1793. // The minor data subtype GUIDs that define the exact class of the data type.//
  1794. ///////////////////////////////////////////////////////////////////////////////
  1795. // STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO
  1796. #define STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO \
  1797. 0x36523b21L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1798. DEFINE_GUIDSTRUCT("36523B21-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO );
  1799. #define KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_VIDEO)
  1800. // STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO
  1801. #define STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO \
  1802. 0x36523b22L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1803. DEFINE_GUIDSTRUCT("36523B22-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO );
  1804. #define KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_STANDARD_MPEG1_AUDIO)
  1805. // STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO
  1806. #define STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO \
  1807. 0x36523b23L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1808. DEFINE_GUIDSTRUCT("36523B23-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO );
  1809. #define KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_VIDEO)
  1810. // STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO
  1811. #define STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO \
  1812. 0x36523b24L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1813. DEFINE_GUIDSTRUCT("36523B24-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO );
  1814. #define KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_STANDARD_MPEG2_AUDIO)
  1815. // STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO
  1816. #define STATIC_KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO \
  1817. 0x36523b25L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1818. DEFINE_GUIDSTRUCT("36523B25-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO );
  1819. #define KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_STANDARD_AC3_AUDIO)
  1820. ///////////////////////////////////////////////////////////////////////////////
  1821. // The low-level specifier GUIDs that define the flavor of the data subtype. //
  1822. // Some SUBTYPES, notably MPEG2_VIDEO, MPEG2_AUDIO have different dialects. //
  1823. // These specifiers are intended to be accompanied by a specifier structure. //
  1824. ///////////////////////////////////////////////////////////////////////////////
  1825. // STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO
  1826. #define STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO \
  1827. 0x36523b31L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1828. DEFINE_GUIDSTRUCT("36523B31-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO );
  1829. #define KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_VIDEO)
  1830. // STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO
  1831. #define STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO \
  1832. 0x36523b32L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1833. DEFINE_GUIDSTRUCT("36523B32-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO );
  1834. #define KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_DIALECT_MPEG1_AUDIO)
  1835. // STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO Associated with KS_MPEGVIDEOINFO2 defined later
  1836. #define STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO \
  1837. 0x36523b33L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1838. DEFINE_GUIDSTRUCT("36523B33-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO );
  1839. #define KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_VIDEO)
  1840. // STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO Associated with KS_MPEGAUDIOINFO defined later
  1841. #define STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO \
  1842. 0x36523b34L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1843. DEFINE_GUIDSTRUCT("36523B34-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO );
  1844. #define KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_DIALECT_MPEG2_AUDIO)
  1845. // STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO
  1846. #define STATIC_KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO \
  1847. 0x36523b35L, 0x8ee5, 0x11d1, 0x8c, 0xa3, 0x00, 0x60, 0xb0, 0x57, 0x66, 0x4a
  1848. DEFINE_GUIDSTRUCT("36523B35-8EE5-11d1-8CA3-0060B057664A", KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO );
  1849. #define KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_DIALECT_AC3_AUDIO)
  1850. //====================================================================================================
  1851. //====================================================================================================
  1852. // *** COMPATIBILITY WARNING ***
  1853. // The *following* older DSS, MPEG, DVD & AC-3 GUID definitions are retained for backward compability.
  1854. // These MPEG GUIDs should also be supported for compatibilty, but the above newer modes are still required.
  1855. //====================================================================================================
  1856. //====================================================================================================
  1857. //
  1858. // DSS definitions
  1859. //
  1860. #define STATIC_KSDATAFORMAT_SUBTYPE_DSS_VIDEO\
  1861. 0xa0af4f81L, 0xe163, 0x11d0, 0xba, 0xd9, 0x00, 0x60, 0x97, 0x44, 0x11, 0x1a
  1862. DEFINE_GUIDSTRUCT("a0af4f81-e163-11d0-bad9-00609744111a", KSDATAFORMAT_SUBTYPE_DSS_VIDEO);
  1863. #define KSDATAFORMAT_SUBTYPE_DSS_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_DSS_VIDEO)
  1864. #define STATIC_KSDATAFORMAT_SUBTYPE_DSS_AUDIO\
  1865. 0xa0af4f82L, 0xe163, 0x11d0, 0xba, 0xd9, 0x00, 0x60, 0x97, 0x44, 0x11, 0x1a
  1866. DEFINE_GUIDSTRUCT("a0af4f82-e163-11d0-bad9-00609744111a", KSDATAFORMAT_SUBTYPE_DSS_AUDIO);
  1867. #define KSDATAFORMAT_SUBTYPE_DSS_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_DSS_AUDIO)
  1868. //
  1869. // End of obsolete MPEG definitions.
  1870. //
  1871. //
  1872. // mpeg 1 definitions
  1873. //
  1874. #define STATIC_KSDATAFORMAT_SUBTYPE_MPEG1Packet\
  1875. 0xe436eb80, 0x524f, 0x11ce, 0x9f, 0x53, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70
  1876. DEFINE_GUIDSTRUCT("e436eb80-524f-11ce-9F53-0020af0ba770", KSDATAFORMAT_SUBTYPE_MPEG1Packet);
  1877. #define KSDATAFORMAT_SUBTYPE_MPEG1Packet DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MPEG1Packet)
  1878. #define STATIC_KSDATAFORMAT_SUBTYPE_MPEG1Payload\
  1879. 0xe436eb81, 0x524f, 0x11ce, 0x9f, 0x53, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70
  1880. DEFINE_GUIDSTRUCT("e436eb81-524f-11ce-9F53-0020af0ba770", KSDATAFORMAT_SUBTYPE_MPEG1Payload);
  1881. #define KSDATAFORMAT_SUBTYPE_MPEG1Payload DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MPEG1Payload)
  1882. // MEDIASUBTYPE_MPEG1Video
  1883. #define STATIC_KSDATAFORMAT_SUBTYPE_MPEG1Video\
  1884. 0xe436eb86, 0x524f, 0x11ce, 0x9f, 0x53, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70
  1885. DEFINE_GUIDSTRUCT("e436eb86-524f-11ce-9f53-0020af0ba770", KSDATAFORMAT_SUBTYPE_MPEG1Video);
  1886. #define KSDATAFORMAT_SUBTYPE_MPEG1Video DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MPEG1Video)
  1887. //FORMAT_MPEGVideo
  1888. #define STATIC_KSDATAFORMAT_SPECIFIER_MPEG1_VIDEO\
  1889. 0x05589f82L, 0xc356, 0x11ce, 0xbf, 0x01, 0x00, 0xaa, 0x00, 0x55, 0x59, 0x5a
  1890. DEFINE_GUIDSTRUCT("05589f82-c356-11ce-bf01-00aa0055595a", KSDATAFORMAT_SPECIFIER_MPEG1_VIDEO);
  1891. #define KSDATAFORMAT_SPECIFIER_MPEG1_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_MPEG1_VIDEO)
  1892. //
  1893. // mpeg 2 definitions
  1894. //
  1895. #define STATIC_KSDATAFORMAT_TYPE_MPEG2_PES\
  1896. 0xe06d8020L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1897. DEFINE_GUIDSTRUCT("e06d8020-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_TYPE_MPEG2_PES);
  1898. #define KSDATAFORMAT_TYPE_MPEG2_PES DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_MPEG2_PES)
  1899. #define STATIC_KSDATAFORMAT_TYPE_MPEG2_PROGRAM\
  1900. 0xe06d8022L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1901. DEFINE_GUIDSTRUCT("e06d8022-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_TYPE_MPEG2_PROGRAM);
  1902. #define KSDATAFORMAT_TYPE_MPEG2_PROGRAM DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_MPEG2_PROGRAM)
  1903. #define STATIC_KSDATAFORMAT_TYPE_MPEG2_TRANSPORT\
  1904. 0xe06d8023L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1905. DEFINE_GUIDSTRUCT("e06d8023-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_TYPE_MPEG2_TRANSPORT);
  1906. #define KSDATAFORMAT_TYPE_MPEG2_TRANSPORT DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_MPEG2_TRANSPORT)
  1907. #define STATIC_KSDATAFORMAT_SUBTYPE_MPEG2_VIDEO\
  1908. 0xe06d8026L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1909. DEFINE_GUIDSTRUCT("e06d8026-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_MPEG2_VIDEO);
  1910. #define KSDATAFORMAT_SUBTYPE_MPEG2_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MPEG2_VIDEO)
  1911. // use MPEGVIDEOINFO2 (defined below) with KSDATAFORMAT_SPECIFIER_MPEG2_VIDEO
  1912. #define STATIC_KSDATAFORMAT_SPECIFIER_MPEG2_VIDEO\
  1913. 0xe06d80e3L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1914. DEFINE_GUIDSTRUCT("e06d80e3-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SPECIFIER_MPEG2_VIDEO);
  1915. #define KSDATAFORMAT_SPECIFIER_MPEG2_VIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_MPEG2_VIDEO)
  1916. //
  1917. // Mpeg2 video properties
  1918. //
  1919. #define STATIC_KSPROPSETID_Mpeg2Vid\
  1920. 0xC8E11B60L, 0x0CC9, 0x11D0, 0xBD, 0x69, 0x00, 0x35, 0x05, 0xC1, 0x03, 0xA9
  1921. DEFINE_GUIDSTRUCT("C8E11B60-0CC9-11D0-BD69-003505C103A9", KSPROPSETID_Mpeg2Vid);
  1922. #define KSPROPSETID_Mpeg2Vid DEFINE_GUIDNAMED( KSPROPSETID_Mpeg2Vid )
  1923. typedef enum {
  1924. KSPROPERTY_MPEG2VID_MODES, // available output modes of decoder
  1925. KSPROPERTY_MPEG2VID_CUR_MODE, // current mode of the decoder
  1926. KSPROPERTY_MPEG2VID_4_3_RECT, // output coordinates for 4:3 source
  1927. KSPROPERTY_MPEG2VID_16_9_RECT, // output coordinates for 16:9 source
  1928. KSPROPERTY_MPEG2VID_16_9_PANSCAN, // pan and scan vectors
  1929. } KSPROPERTY_MPEG2VID;
  1930. //
  1931. // bit field definitions for MPEG2 VIDEO mode
  1932. //
  1933. #define KSMPEGVIDMODE_PANSCAN 0x0001
  1934. #define KSMPEGVIDMODE_LTRBOX 0x0002
  1935. #define KSMPEGVIDMODE_SCALE 0x0004
  1936. //
  1937. // rectangle definitions for the 4/3 and 16/9 cropping properties of
  1938. // the MPEG2Video decoder
  1939. //
  1940. typedef struct _KSMPEGVID_RECT {
  1941. ULONG StartX;
  1942. ULONG StartY;
  1943. ULONG EndX;
  1944. ULONG EndY;
  1945. } KSMPEGVID_RECT, *PKSMPEGVID_RECT;
  1946. //
  1947. // Params for pan / scan
  1948. //
  1949. //
  1950. // MPEG2 Audio definition
  1951. //
  1952. #define STATIC_KSDATAFORMAT_SUBTYPE_MPEG2_AUDIO\
  1953. 0xe06d802bL, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1954. DEFINE_GUIDSTRUCT("e06d802b-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_MPEG2_AUDIO);
  1955. #define KSDATAFORMAT_SUBTYPE_MPEG2_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_MPEG2_AUDIO)
  1956. #define STATIC_KSDATAFORMAT_SPECIFIER_MPEG2_AUDIO\
  1957. 0xe06d80e5L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1958. DEFINE_GUIDSTRUCT("e06d80e5-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SPECIFIER_MPEG2_AUDIO);
  1959. #define KSDATAFORMAT_SPECIFIER_MPEG2_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_MPEG2_AUDIO)
  1960. //
  1961. // DVD LPCM Audio definition
  1962. //
  1963. #define STATIC_KSDATAFORMAT_SUBTYPE_LPCM_AUDIO\
  1964. 0xe06d8032L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1965. DEFINE_GUIDSTRUCT("e06d8032-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_LPCM_AUDIO);
  1966. #define KSDATAFORMAT_SUBTYPE_LPCM_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_LPCM_AUDIO)
  1967. #define STATIC_KSDATAFORMAT_SPECIFIER_LPCM_AUDIO\
  1968. 0xe06d80e6L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1969. DEFINE_GUIDSTRUCT("e06d80e6-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SPECIFIER_LPCM_AUDIO);
  1970. #define KSDATAFORMAT_SPECIFIER_LPCM_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_LPCM_AUDIO)
  1971. //
  1972. // AC-3 definition
  1973. //
  1974. #define STATIC_KSDATAFORMAT_SUBTYPE_AC3_AUDIO\
  1975. 0xe06d802cL, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1976. DEFINE_GUIDSTRUCT("e06d802c-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_AC3_AUDIO);
  1977. #define KSDATAFORMAT_SUBTYPE_AC3_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_AC3_AUDIO)
  1978. #define STATIC_KSDATAFORMAT_SPECIFIER_AC3_AUDIO\
  1979. 0xe06d80e4L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  1980. DEFINE_GUIDSTRUCT("e06d80e4-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SPECIFIER_AC3_AUDIO);
  1981. #define KSDATAFORMAT_SPECIFIER_AC3_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_AC3_AUDIO)
  1982. #define STATIC_KSPROPSETID_AC3\
  1983. 0xBFABE720L, 0x6E1F, 0x11D0, 0xBC, 0xF2, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00
  1984. DEFINE_GUIDSTRUCT("BFABE720-6E1F-11D0-BCF2-444553540000", KSPROPSETID_AC3);
  1985. #define KSPROPSETID_AC3 DEFINE_GUIDNAMED(KSPROPSETID_AC3)
  1986. typedef enum {
  1987. KSPROPERTY_AC3_ERROR_CONCEALMENT = 1,
  1988. KSPROPERTY_AC3_ALTERNATE_AUDIO,
  1989. KSPROPERTY_AC3_DOWNMIX,
  1990. KSPROPERTY_AC3_BIT_STREAM_MODE,
  1991. KSPROPERTY_AC3_DIALOGUE_LEVEL,
  1992. KSPROPERTY_AC3_LANGUAGE_CODE,
  1993. KSPROPERTY_AC3_ROOM_TYPE
  1994. } KSPROPERTY_AC3;
  1995. typedef struct {
  1996. BOOL fRepeatPreviousBlock;
  1997. BOOL fErrorInCurrentBlock;
  1998. } KSAC3_ERROR_CONCEALMENT, *PKSAC3_ERROR_CONCEALMENT;
  1999. typedef struct {
  2000. BOOL fStereo;
  2001. ULONG DualMode;
  2002. } KSAC3_ALTERNATE_AUDIO, *PKSAC3_ALTERNATE_AUDIO;
  2003. #define KSAC3_ALTERNATE_AUDIO_1 1
  2004. #define KSAC3_ALTERNATE_AUDIO_2 2
  2005. #define KSAC3_ALTERNATE_AUDIO_BOTH 3
  2006. typedef struct {
  2007. BOOL fDownMix;
  2008. BOOL fDolbySurround;
  2009. } KSAC3_DOWNMIX, *PKSAC3_DOWNMIX;
  2010. typedef struct {
  2011. LONG BitStreamMode;
  2012. } KSAC3_BIT_STREAM_MODE, *PKSAC3_BIT_STREAM_MODE;
  2013. #define KSAC3_SERVICE_MAIN_AUDIO 0
  2014. #define KSAC3_SERVICE_NO_DIALOG 1
  2015. #define KSAC3_SERVICE_VISUALLY_IMPAIRED 2
  2016. #define KSAC3_SERVICE_HEARING_IMPAIRED 3
  2017. #define KSAC3_SERVICE_DIALOG_ONLY 4
  2018. #define KSAC3_SERVICE_COMMENTARY 5
  2019. #define KSAC3_SERVICE_EMERGENCY_FLASH 6
  2020. #define KSAC3_SERVICE_VOICE_OVER 7
  2021. typedef struct {
  2022. ULONG DialogueLevel;
  2023. } KSAC3_DIALOGUE_LEVEL, *PKSAC3_DIALOGUE_LEVEL;
  2024. typedef struct {
  2025. BOOL fLargeRoom;
  2026. } KSAC3_ROOM_TYPE, *PKSAC3_ROOM_TYPE;
  2027. //
  2028. // DTS and SDDS definitions (media subtype GUIDs)
  2029. //
  2030. #define STATIC_KSDATAFORMAT_SUBTYPE_DTS_AUDIO\
  2031. 0xe06d8033L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  2032. DEFINE_GUIDSTRUCT("e06d8033-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_DTS_AUDIO);
  2033. #define KSDATAFORMAT_SUBTYPE_DTS_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_DTS_AUDIO)
  2034. #define STATIC_KSDATAFORMAT_SUBTYPE_SDDS_AUDIO\
  2035. 0xe06d8034L, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  2036. DEFINE_GUIDSTRUCT("e06d8034-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_SDDS_AUDIO);
  2037. #define KSDATAFORMAT_SUBTYPE_SDDS_AUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_SDDS_AUDIO)
  2038. //
  2039. // audio decoder output properties
  2040. //
  2041. #define STATIC_KSPROPSETID_AudioDecoderOut\
  2042. 0x6ca6e020L, 0x43bd, 0x11d0, 0xbd, 0x6a, 0x00, 0x35, 0x05, 0xc1, 0x03, 0xa9
  2043. DEFINE_GUIDSTRUCT("6ca6e020-43bd-11d0-bd6a-003505c103a9", KSPROPSETID_AudioDecoderOut);
  2044. #define KSPROPSETID_AudioDecoderOut DEFINE_GUIDNAMED(KSPROPSETID_AudioDecoderOut)
  2045. typedef enum {
  2046. KSPROPERTY_AUDDECOUT_MODES, // available output modes of decoder
  2047. KSPROPERTY_AUDDECOUT_CUR_MODE, // current mode of the decoder
  2048. } KSPROPERTY_AUDDECOUT;
  2049. #define KSAUDDECOUTMODE_STEREO_ANALOG 0x0001
  2050. #define KSAUDDECOUTMODE_PCM_51 0x0002
  2051. #define KSAUDDECOUTMODE_SPDIFF 0x0004
  2052. //
  2053. // subpicture definition
  2054. //
  2055. #define STATIC_KSDATAFORMAT_SUBTYPE_SUBPICTURE\
  2056. 0xe06d802dL, 0xdb46, 0x11cf, 0xb4, 0xd1, 0x00, 0x80, 0x5f, 0x6c, 0xbb, 0xea
  2057. DEFINE_GUIDSTRUCT("e06d802d-db46-11cf-b4d1-00805f6cbbea", KSDATAFORMAT_SUBTYPE_SUBPICTURE);
  2058. #define KSDATAFORMAT_SUBTYPE_SUBPICTURE DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_SUBPICTURE)
  2059. #define STATIC_KSPROPSETID_DvdSubPic\
  2060. 0xac390460L, 0x43af, 0x11d0, 0xbd, 0x6a, 0x00, 0x35, 0x05, 0xc1, 0x03, 0xa9
  2061. DEFINE_GUIDSTRUCT("ac390460-43af-11d0-bd6a-003505c103a9", KSPROPSETID_DvdSubPic);
  2062. #define KSPROPSETID_DvdSubPic DEFINE_GUIDNAMED(KSPROPSETID_DvdSubPic)
  2063. typedef enum {
  2064. KSPROPERTY_DVDSUBPIC_PALETTE,
  2065. KSPROPERTY_DVDSUBPIC_HLI,
  2066. KSPROPERTY_DVDSUBPIC_COMPOSIT_ON, // TRUE for subpicture is displayed
  2067. } KSPROPERTY_DVDSUBPIC;
  2068. typedef struct _KS_DVD_YCrCb {
  2069. UCHAR Reserved;
  2070. UCHAR Y;
  2071. UCHAR Cr;
  2072. UCHAR Cb;
  2073. } KS_DVD_YCrCb, *PKS_DVD_YCrCb;
  2074. /* The KS_DVD_YUV structure is now superseded by KS_DVD_YCrCb above and is
  2075. here for backward compatibility only */
  2076. typedef struct _KS_DVD_YUV {
  2077. UCHAR Reserved;
  2078. UCHAR Y;
  2079. UCHAR V;
  2080. UCHAR U;
  2081. } KS_DVD_YUV, *PKS_DVD_YUV;
  2082. typedef struct _KSPROPERTY_SPPAL {
  2083. KS_DVD_YUV sppal[16];
  2084. } KSPROPERTY_SPPAL, *PKSPROPERTY_SPPAL;
  2085. typedef struct _KS_COLCON {
  2086. UCHAR emph1col:4;
  2087. UCHAR emph2col:4;
  2088. UCHAR backcol:4;
  2089. UCHAR patcol:4;
  2090. UCHAR emph1con:4;
  2091. UCHAR emph2con:4;
  2092. UCHAR backcon:4;
  2093. UCHAR patcon:4;
  2094. } KS_COLCON, *PKS_COLCON;
  2095. typedef struct _KSPROPERTY_SPHLI {
  2096. USHORT HLISS;
  2097. USHORT Reserved;
  2098. ULONG StartPTM; // start presentation time in x/90000
  2099. ULONG EndPTM; // end PTM in x/90000
  2100. USHORT StartX;
  2101. USHORT StartY;
  2102. USHORT StopX;
  2103. USHORT StopY;
  2104. KS_COLCON ColCon; // color contrast description (4 bytes as given in HLI)
  2105. } KSPROPERTY_SPHLI, *PKSPROPERTY_SPHLI;
  2106. typedef BOOL KSPROPERTY_COMPOSIT_ON, *PKSPROPERTY_COMPOSIT_ON;
  2107. #define STATIC_KSPROPSETID_CopyProt \
  2108. 0x0E8A0A40L, 0x6AEF, 0x11D0, 0x9E, 0xD0, 0x00, 0xA0, 0x24, 0xCA, 0x19, 0xB3
  2109. DEFINE_GUIDSTRUCT("0E8A0A40-6AEF-11D0-9ED0-00A024CA19B3", KSPROPSETID_CopyProt);
  2110. #define KSPROPSETID_CopyProt DEFINE_GUIDNAMED(KSPROPSETID_CopyProt)
  2111. typedef enum {
  2112. KSPROPERTY_DVDCOPY_CHLG_KEY = 0x01,
  2113. KSPROPERTY_DVDCOPY_DVD_KEY1,
  2114. KSPROPERTY_DVDCOPY_DEC_KEY2,
  2115. KSPROPERTY_DVDCOPY_TITLE_KEY,
  2116. KSPROPERTY_COPY_MACROVISION,
  2117. KSPROPERTY_DVDCOPY_REGION,
  2118. KSPROPERTY_DVDCOPY_SET_COPY_STATE,
  2119. KSPROPERTY_DVDCOPY_DISC_KEY = 0x80
  2120. } KSPROPERTY_COPYPROT;
  2121. typedef struct _KS_DVDCOPY_CHLGKEY {
  2122. BYTE ChlgKey[10];
  2123. BYTE Reserved[2];
  2124. } KS_DVDCOPY_CHLGKEY, *PKS_DVDCOPY_CHLGKEY;
  2125. typedef struct _KS_DVDCOPY_BUSKEY {
  2126. BYTE BusKey[5];
  2127. BYTE Reserved[1];
  2128. } KS_DVDCOPY_BUSKEY, *PKS_DVDCOPY_BUSKEY;
  2129. typedef struct _KS_DVDCOPY_DISCKEY {
  2130. BYTE DiscKey[2048];
  2131. } KS_DVDCOPY_DISCKEY, *PKS_DVDCOPY_DISCKEY;
  2132. typedef struct _KS_DVDCOPY_REGION {
  2133. UCHAR Reserved;
  2134. UCHAR RegionData;
  2135. UCHAR Reserved2[2];
  2136. } KS_DVDCOPY_REGION, *PKS_DVDCOPY_REGION;
  2137. typedef struct _KS_DVDCOPY_TITLEKEY {
  2138. ULONG KeyFlags;
  2139. ULONG ReservedNT[2];
  2140. UCHAR TitleKey[6];
  2141. UCHAR Reserved[2];
  2142. } KS_DVDCOPY_TITLEKEY, *PKS_DVDCOPY_TITLEKEY;
  2143. typedef struct _KS_COPY_MACROVISION {
  2144. ULONG MACROVISIONLevel;
  2145. } KS_COPY_MACROVISION, *PKS_COPY_MACROVISION;
  2146. typedef struct _KS_DVDCOPY_SET_COPY_STATE {
  2147. ULONG DVDCopyState;
  2148. } KS_DVDCOPY_SET_COPY_STATE, *PKS_DVDCOPY_SET_COPY_STATE;
  2149. typedef enum {
  2150. KS_DVDCOPYSTATE_INITIALIZE, // indicates we are starting a full
  2151. // copy protection sequence.
  2152. KS_DVDCOPYSTATE_INITIALIZE_TITLE, // indicates we are starting a title
  2153. // key copy protection sequence
  2154. KS_DVDCOPYSTATE_AUTHENTICATION_NOT_REQUIRED,
  2155. KS_DVDCOPYSTATE_AUTHENTICATION_REQUIRED,
  2156. KS_DVDCOPYSTATE_DONE,
  2157. } KS_DVDCOPYSTATE;
  2158. typedef enum {
  2159. KS_MACROVISION_DISABLED,
  2160. KS_MACROVISION_LEVEL1,
  2161. KS_MACROVISION_LEVEL2,
  2162. KS_MACROVISION_LEVEL3
  2163. } KS_COPY_MACROVISION_LEVEL, *PKS_COPY_MACROVISION_LEVEL;
  2164. //
  2165. // CGMS Copy Protection Flags
  2166. //
  2167. #define KS_DVD_CGMS_RESERVED_MASK 0x00000078
  2168. #define KS_DVD_CGMS_COPY_PROTECT_MASK 0x00000018
  2169. #define KS_DVD_CGMS_COPY_PERMITTED 0x00000000
  2170. #define KS_DVD_CGMS_COPY_ONCE 0x00000010
  2171. #define KS_DVD_CGMS_NO_COPY 0x00000018
  2172. #define KS_DVD_COPYRIGHT_MASK 0x00000040
  2173. #define KS_DVD_NOT_COPYRIGHTED 0x00000000
  2174. #define KS_DVD_COPYRIGHTED 0x00000040
  2175. #define KS_DVD_SECTOR_PROTECT_MASK 0x00000020
  2176. #define KS_DVD_SECTOR_NOT_PROTECTED 0x00000000
  2177. #define KS_DVD_SECTOR_PROTECTED 0x00000020
  2178. //===========================================================================
  2179. // The following MUST match the structures in WinGDI.h and AMVideo.h
  2180. //===========================================================================
  2181. #define STATIC_KSCATEGORY_TVTUNER \
  2182. 0xa799a800L, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4
  2183. DEFINE_GUIDSTRUCT("a799a800-a46d-11d0-a18c-00a02401dcd4", KSCATEGORY_TVTUNER);
  2184. #define KSCATEGORY_TVTUNER DEFINE_GUIDNAMED(KSCATEGORY_TVTUNER)
  2185. #define STATIC_KSCATEGORY_CROSSBAR \
  2186. 0xa799a801L, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4
  2187. DEFINE_GUIDSTRUCT("a799a801-a46d-11d0-a18c-00a02401dcd4", KSCATEGORY_CROSSBAR);
  2188. #define KSCATEGORY_CROSSBAR DEFINE_GUIDNAMED(KSCATEGORY_CROSSBAR)
  2189. #define STATIC_KSCATEGORY_TVAUDIO \
  2190. 0xa799a802L, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4
  2191. DEFINE_GUIDSTRUCT("a799a802-a46d-11d0-a18c-00a02401dcd4", KSCATEGORY_TVAUDIO);
  2192. #define KSCATEGORY_TVAUDIO DEFINE_GUIDNAMED(KSCATEGORY_TVAUDIO)
  2193. #define STATIC_KSCATEGORY_VPMUX \
  2194. 0xa799a803L, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4
  2195. DEFINE_GUIDSTRUCT("a799a803-a46d-11d0-a18c-00a02401dcd4", KSCATEGORY_VPMUX);
  2196. #define KSCATEGORY_VPMUX DEFINE_GUIDNAMED(KSCATEGORY_VPMUX)
  2197. #define STATIC_KSCATEGORY_VBICODEC \
  2198. 0x07dad660L, 0x22f1, 0x11d1, 0xa9, 0xf4, 0x00, 0xc0, 0x4f, 0xbb, 0xde, 0x8f
  2199. DEFINE_GUIDSTRUCT("07dad660-22f1-11d1-a9f4-00c04fbbde8f", KSCATEGORY_VBICODEC);
  2200. #define KSCATEGORY_VBICODEC DEFINE_GUIDNAMED(KSCATEGORY_VBICODEC)
  2201. // SUBTYPE_VPVideo
  2202. #define STATIC_KSDATAFORMAT_SUBTYPE_VPVideo\
  2203. 0x5a9b6a40L, 0x1a22, 0x11d1, 0xba, 0xd9, 0x0, 0x60, 0x97, 0x44, 0x11, 0x1a
  2204. DEFINE_GUIDSTRUCT("5a9b6a40-1a22-11d1-bad9-00609744111a", KSDATAFORMAT_SUBTYPE_VPVideo);
  2205. #define KSDATAFORMAT_SUBTYPE_VPVideo DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_VPVideo)
  2206. // SUBTYPE_VPVBI
  2207. #define STATIC_KSDATAFORMAT_SUBTYPE_VPVBI\
  2208. 0x5a9b6a41L, 0x1a22, 0x11d1, 0xba, 0xd9, 0x0, 0x60, 0x97, 0x44, 0x11, 0x1a
  2209. DEFINE_GUIDSTRUCT("5a9b6a41-1a22-11d1-bad9-00609744111a", KSDATAFORMAT_SUBTYPE_VPVBI);
  2210. #define KSDATAFORMAT_SUBTYPE_VPVBI DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_VPVBI)
  2211. // FORMAT_VideoInfo
  2212. #define STATIC_KSDATAFORMAT_SPECIFIER_VIDEOINFO\
  2213. 0x05589f80L, 0xc356, 0x11ce, 0xbf, 0x01, 0x00, 0xaa, 0x00, 0x55, 0x59, 0x5a
  2214. DEFINE_GUIDSTRUCT("05589f80-c356-11ce-bf01-00aa0055595a", KSDATAFORMAT_SPECIFIER_VIDEOINFO);
  2215. #define KSDATAFORMAT_SPECIFIER_VIDEOINFO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_VIDEOINFO)
  2216. // FORMAT_VideoInfo2
  2217. #define STATIC_KSDATAFORMAT_SPECIFIER_VIDEOINFO2\
  2218. 0xf72a76A0L, 0xeb0a, 0x11d0, 0xac, 0xe4, 0x00, 0x00, 0xc0, 0xcc, 0x16, 0xba
  2219. DEFINE_GUIDSTRUCT("f72a76A0-eb0a-11d0-ace4-0000c0cc16ba", KSDATAFORMAT_SPECIFIER_VIDEOINFO2);
  2220. #define KSDATAFORMAT_SPECIFIER_VIDEOINFO2 DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_VIDEOINFO2)
  2221. // MEDIATYPE_AnalogVideo
  2222. #define STATIC_KSDATAFORMAT_TYPE_ANALOGVIDEO\
  2223. 0x0482dde1L, 0x7817, 0x11cf, 0x8a, 0x03, 0x00, 0xaa, 0x00, 0x6e, 0xcb, 0x65
  2224. DEFINE_GUIDSTRUCT("0482dde1-7817-11cf-8a03-00aa006ecb65", KSDATAFORMAT_TYPE_ANALOGVIDEO);
  2225. #define KSDATAFORMAT_TYPE_ANALOGVIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_ANALOGVIDEO)
  2226. // FORMAT_AnalogVideo
  2227. #define STATIC_KSDATAFORMAT_SPECIFIER_ANALOGVIDEO\
  2228. 0x0482dde0L, 0x7817, 0x11cf, 0x8a, 0x03, 0x00, 0xaa, 0x00, 0x6e, 0xcb, 0x65
  2229. DEFINE_GUIDSTRUCT("0482dde0-7817-11cf-8a03-00aa006ecb65", KSDATAFORMAT_SPECIFIER_ANALOGVIDEO);
  2230. #define KSDATAFORMAT_SPECIFIER_ANALOGVIDEO DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_ANALOGVIDEO)
  2231. // MEDIATYPE_AnalogAudio
  2232. #define STATIC_KSDATAFORMAT_TYPE_ANALOGAUDIO \
  2233. 0x0482dee1L, 0x7817, 0x11cf, 0x8a, 0x03, 0x00, 0xaa, 0x00, 0x6e, 0xcb, 0x65
  2234. DEFINE_GUIDSTRUCT("0482DEE1-7817-11cf-8a03-00aa006ecb65", KSDATAFORMAT_TYPE_ANALOGAUDIO);
  2235. #define KSDATAFORMAT_TYPE_ANALOGAUDIO DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_ANALOGAUDIO)
  2236. // FORMAT_VBI
  2237. #define STATIC_KSDATAFORMAT_SPECIFIER_VBI\
  2238. 0xf72a76e0L, 0xeb0a, 0x11d0, 0xac, 0xe4, 0x00, 0x00, 0xc0, 0xcc, 0x16, 0xba
  2239. DEFINE_GUIDSTRUCT("f72a76e0-eb0a-11d0-ace4-0000c0cc16ba", KSDATAFORMAT_SPECIFIER_VBI);
  2240. #define KSDATAFORMAT_SPECIFIER_VBI DEFINE_GUIDNAMED(KSDATAFORMAT_SPECIFIER_VBI)
  2241. // MEDIATYPE_VBI
  2242. #define STATIC_KSDATAFORMAT_TYPE_VBI\
  2243. 0xf72a76e1L, 0xeb0a, 0x11d0, 0xac, 0xe4, 0x00, 0x00, 0xc0, 0xcc, 0x16, 0xba
  2244. DEFINE_GUIDSTRUCT("f72a76e1-eb0a-11d0-ace4-0000c0cc16ba", KSDATAFORMAT_TYPE_VBI);
  2245. #define KSDATAFORMAT_TYPE_VBI DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_VBI)
  2246. // SUBTYPE_RAW8
  2247. #define STATIC_KSDATAFORMAT_SUBTYPE_RAW8\
  2248. 0xca20d9a0, 0x3e3e, 0x11d1, 0x9b, 0xf9, 0x0, 0xc0, 0x4f, 0xbb, 0xde, 0xbf
  2249. DEFINE_GUIDSTRUCT("ca20d9a0-3e3e-11d1-9bf9-00c04fbbdebf", KSDATAFORMAT_SUBTYPE_RAW8);
  2250. #define KSDATAFORMAT_SUBTYPE_RAW8 DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_RAW8)
  2251. // MEDIASUBTYPE_CC
  2252. #define STATIC_KSDATAFORMAT_SUBTYPE_CC\
  2253. 0x33214cc1, 0x11f, 0x11d2, 0xb4, 0xb1, 0x0, 0xa0, 0xd1, 0x2, 0xcf, 0xbe
  2254. DEFINE_GUIDSTRUCT("33214CC1-011F-11D2-B4B1-00A0D102CFBE", KSDATAFORMAT_SUBTYPE_CC);
  2255. #define KSDATAFORMAT_SUBTYPE_CC DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_CC)
  2256. // MEDIASUBTYPE_NABTS
  2257. #define STATIC_KSDATAFORMAT_SUBTYPE_NABTS\
  2258. 0xf72a76e2L, 0xeb0a, 0x11d0, 0xac, 0xe4, 0x00, 0x00, 0xc0, 0xcc, 0x16, 0xba
  2259. DEFINE_GUIDSTRUCT("f72a76e2-eb0a-11d0-ace4-0000c0cc16ba", KSDATAFORMAT_SUBTYPE_NABTS);
  2260. #define KSDATAFORMAT_SUBTYPE_NABTS DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_NABTS)
  2261. // MEDIASUBTYPE_TELETEXT
  2262. #define STATIC_KSDATAFORMAT_SUBTYPE_TELETEXT\
  2263. 0xf72a76e3L, 0xeb0a, 0x11d0, 0xac, 0xe4, 0x00, 0x00, 0xc0, 0xcc, 0x16, 0xba
  2264. DEFINE_GUIDSTRUCT("f72a76e3-eb0a-11d0-ace4-0000c0cc16ba", KSDATAFORMAT_SUBTYPE_TELETEXT);
  2265. #define KSDATAFORMAT_SUBTYPE_TELETEXT DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_TELETEXT)
  2266. /* constants for the biCompression field */
  2267. #define KS_BI_RGB 0L
  2268. #define KS_BI_RLE8 1L
  2269. #define KS_BI_RLE4 2L
  2270. #define KS_BI_BITFIELDS 3L
  2271. typedef struct tagKS_RGBQUAD { // rgbq
  2272. BYTE rgbBlue;
  2273. BYTE rgbGreen;
  2274. BYTE rgbRed;
  2275. BYTE rgbReserved;
  2276. } KS_RGBQUAD, *PKS_RGBQUAD;
  2277. /* constants for palettes */
  2278. #define KS_iPALETTE_COLORS 256 // Maximum colours in palette
  2279. #define KS_iEGA_COLORS 16 // Number colours in EGA palette
  2280. #define KS_iMASK_COLORS 3 // Maximum three components
  2281. #define KS_iTRUECOLOR 16 // Minimum true colour device
  2282. #define KS_iRED 0 // Index position for RED mask
  2283. #define KS_iGREEN 1 // Index position for GREEN mask
  2284. #define KS_iBLUE 2 // Index position for BLUE mask
  2285. #define KS_iPALETTE 8 // Maximum colour depth using a palette
  2286. #define KS_iMAXBITS 8 // Maximum bits per colour component
  2287. #define KS_SIZE_EGA_PALETTE (KS_iEGA_COLORS * sizeof(KS_RGBQUAD))
  2288. #define KS_SIZE_PALETTE (KS_iPALETTE_COLORS * sizeof(KS_RGBQUAD))
  2289. typedef struct tagKS_BITMAPINFOHEADER{
  2290. DWORD biSize;
  2291. LONG biWidth;
  2292. LONG biHeight;
  2293. WORD biPlanes;
  2294. WORD biBitCount;
  2295. DWORD biCompression;
  2296. DWORD biSizeImage;
  2297. LONG biXPelsPerMeter;
  2298. LONG biYPelsPerMeter;
  2299. DWORD biClrUsed;
  2300. DWORD biClrImportant;
  2301. } KS_BITMAPINFOHEADER, *PKS_BITMAPINFOHEADER;
  2302. // Used for true colour images that also have a palette
  2303. typedef struct tag_KS_TRUECOLORINFO {
  2304. DWORD dwBitMasks[KS_iMASK_COLORS];
  2305. KS_RGBQUAD bmiColors[KS_iPALETTE_COLORS];
  2306. } KS_TRUECOLORINFO, *PKS_TRUECOLORINFO;
  2307. #define KS_WIDTHBYTES(bits) ((DWORD)(((bits)+31) & (~31)) / 8)
  2308. #define KS_DIBWIDTHBYTES(bi) (DWORD)KS_WIDTHBYTES((DWORD)(bi).biWidth * (DWORD)(bi).biBitCount)
  2309. #define KS__DIBSIZE(bi) (KS_DIBWIDTHBYTES(bi) * (DWORD)(bi).biHeight)
  2310. #define KS_DIBSIZE(bi) ((bi).biHeight < 0 ? (-1)*(KS__DIBSIZE(bi)) : KS__DIBSIZE(bi))
  2311. typedef LONGLONG REFERENCE_TIME;
  2312. // The BITMAPINFOHEADER contains all the details about the video stream such
  2313. // as the actual image dimensions and their pixel depth. A source filter may
  2314. // also request that the sink take only a section of the video by providing a
  2315. // clipping rectangle in rcSource. In the worst case where the sink filter
  2316. // forgets to check this on connection it will simply render the whole thing
  2317. // which isn't a disaster. Ideally a sink filter will check the rcSource and
  2318. // if it doesn't support image extraction and the rectangle is not empty then
  2319. // it will reject the connection. A filter should use SetRectEmpty to reset a
  2320. // rectangle to all zeroes (and IsRectEmpty to later check the rectangle).
  2321. // The rcTarget specifies the destination rectangle for the video, for most
  2322. // source filters they will set this to all zeroes, a downstream filter may
  2323. // request that the video be placed in a particular area of the buffers it
  2324. // supplies in which case it will call QueryAccept with a non empty target
  2325. typedef struct tagKS_VIDEOINFOHEADER {
  2326. RECT rcSource; // The bit we really want to use
  2327. RECT rcTarget; // Where the video should go
  2328. DWORD dwBitRate; // Approximate bit data rate
  2329. DWORD dwBitErrorRate; // Bit error rate for this stream
  2330. REFERENCE_TIME AvgTimePerFrame; // Average time per frame (100ns units)
  2331. KS_BITMAPINFOHEADER bmiHeader;
  2332. } KS_VIDEOINFOHEADER, *PKS_VIDEOINFOHEADER;
  2333. // !!! WARNING !!!
  2334. // DO NOT use the following structure unless you are sure that the BITMAPINFOHEADER
  2335. // has a normal biSize == sizeof(BITMAPINFOHEADER) !
  2336. // !!! WARNING !!!
  2337. typedef struct tagKS_VIDEOINFO {
  2338. RECT rcSource; // The bit we really want to use
  2339. RECT rcTarget; // Where the video should go
  2340. DWORD dwBitRate; // Approximate bit data rate
  2341. DWORD dwBitErrorRate; // Bit error rate for this stream
  2342. REFERENCE_TIME AvgTimePerFrame; // Average time per frame (100ns units)
  2343. KS_BITMAPINFOHEADER bmiHeader;
  2344. union {
  2345. KS_RGBQUAD bmiColors[KS_iPALETTE_COLORS]; // Colour palette
  2346. DWORD dwBitMasks[KS_iMASK_COLORS]; // True colour masks
  2347. KS_TRUECOLORINFO TrueColorInfo; // Both of the above
  2348. };
  2349. } KS_VIDEOINFO, *PKS_VIDEOINFO;
  2350. #define KS_SIZE_MASKS (KS_iMASK_COLORS * sizeof(DWORD))
  2351. #define KS_SIZE_PREHEADER (FIELD_OFFSET(KS_VIDEOINFOHEADER,bmiHeader))
  2352. // For normal size
  2353. // #define KS_SIZE_VIDEOHEADER (sizeof(KS_BITMAPINFOHEADER) + KS_SIZE_PREHEADER)
  2354. // !!! for abnormal biSizes
  2355. #define KS_SIZE_VIDEOHEADER(pbmi) ((pbmi)->bmiHeader.biSize + KS_SIZE_PREHEADER)
  2356. // VBI
  2357. // Used for NABTS, CC, Intercast, WST
  2358. typedef struct tagKS_VBIINFOHEADER {
  2359. ULONG StartLine; // inclusive
  2360. ULONG EndLine; // inclusive
  2361. ULONG SamplingFrequency; // Hz.
  2362. ULONG MinLineStartTime; // microSec * 100 from HSync LE
  2363. ULONG MaxLineStartTime; // microSec * 100 from HSync LE
  2364. ULONG ActualLineStartTime; // microSec * 100 from HSync LE
  2365. ULONG ActualLineEndTime; // microSec * 100 from HSync LE
  2366. ULONG VideoStandard; // KS_AnalogVideoStandard*
  2367. ULONG SamplesPerLine;
  2368. ULONG StrideInBytes; // May be > SamplesPerLine
  2369. ULONG BufferSize; // Bytes
  2370. } KS_VBIINFOHEADER, *PKS_VBIINFOHEADER;
  2371. // VBI Sampling Rates
  2372. #define KS_VBIDATARATE_NABTS (5727272L)
  2373. #define KS_VBIDATARATE_CC ( 503493L) // ~= 1/1.986125e-6
  2374. #define KS_VBISAMPLINGRATE_4X_NABTS ((long)(4*KS_VBIDATARATE_NABTS))
  2375. #define KS_VBISAMPLINGRATE_47X_NABTS ((long)(27000000))
  2376. #define KS_VBISAMPLINGRATE_5X_NABTS ((long)(5*KS_VBIDATARATE_NABTS))
  2377. #define KS_47NABTS_SCALER (KS_VBISAMPLINGRATE_47X_NABTS/(double)KS_VBIDATARATE_NABTS)
  2378. // Analog video variant - Use this when the format is FORMAT_AnalogVideo
  2379. //
  2380. // rcSource defines the portion of the active video signal to use
  2381. // rcTarget defines the destination rectangle
  2382. // both of the above are relative to the dwActiveWidth and dwActiveHeight fields
  2383. // dwActiveWidth is currently set to 720 for all formats (but could change for HDTV)
  2384. // dwActiveHeight is 483 for NTSC and 575 for PAL/SECAM (but could change for HDTV)
  2385. typedef struct tagKS_AnalogVideoInfo {
  2386. RECT rcSource; // Width max is 720, height varies w/ TransmissionStd
  2387. RECT rcTarget; // Where the video should go
  2388. DWORD dwActiveWidth; // Always 720 (CCIR-601 active samples per line)
  2389. DWORD dwActiveHeight; // 483 for NTSC, 575 for PAL/SECAM
  2390. REFERENCE_TIME AvgTimePerFrame; // Normal ActiveMovie units (100 nS)
  2391. } KS_ANALOGVIDEOINFO, *PKS_ANALOGVIDEOINFO;
  2392. //===========================================================================
  2393. // Data packet passed on Analog video stream channel change
  2394. //===========================================================================
  2395. #define KS_TVTUNER_CHANGE_BEGIN_TUNE 0x0001L // Starting a tuning operation
  2396. #define KS_TVTUNER_CHANGE_END_TUNE 0x0002L // Ending a tuning operation
  2397. typedef struct tagKS_TVTUNER_CHANGE_INFO {
  2398. DWORD dwFlags; // KS_TVTUNER_CHANGE_*
  2399. DWORD dwCountryCode;
  2400. DWORD dwAnalogVideoStandard; // KS_AnalogVideoStandard
  2401. DWORD dwChannel;
  2402. } KS_TVTUNER_CHANGE_INFO, *PKS_TVTUNER_CHANGE_INFO;
  2403. //===========================================================================
  2404. // Video format blocks
  2405. //===========================================================================
  2406. typedef enum {
  2407. KS_MPEG2Level_Low,
  2408. KS_MPEG2Level_Main,
  2409. KS_MPEG2Level_High1440,
  2410. KS_MPEG2Level_High
  2411. } KS_MPEG2Level;
  2412. typedef enum {
  2413. KS_MPEG2Profile_Simple,
  2414. KS_MPEG2Profile_Main,
  2415. KS_MPEG2Profile_SNRScalable,
  2416. KS_MPEG2Profile_SpatiallyScalable,
  2417. KS_MPEG2Profile_High
  2418. } KS_MPEG2Profile;
  2419. #define KS_INTERLACE_IsInterlaced 0x00000001 // if 0, other interlace bits are irrelevent
  2420. #define KS_INTERLACE_1FieldPerSample 0x00000002 // else 2 fields per media sample
  2421. #define KS_INTERLACE_Field1First 0x00000004 // else Field 2 is first; top field in PAL is field 1, top field in NTSC is field 2?
  2422. #define KS_INTERLACE_UNUSED 0x00000008 //
  2423. #define KS_INTERLACE_FieldPatternMask 0x00000030 // use this mask with AMINTERLACE_FieldPat*
  2424. #define KS_INTERLACE_FieldPatField1Only 0x00000000 // Data never contains a Field2
  2425. #define KS_INTERLACE_FieldPatField2Only 0x00000010 // Data never contains a Field1
  2426. #define KS_INTERLACE_FieldPatBothRegular 0x00000020 // There will be a Field2 for every Field1 (required for Weave?)
  2427. #define KS_INTERLACE_FieldPatBothIrregular 0x00000030 // Random pattern of Field1s and Field2s
  2428. #define KS_INTERLACE_DisplayModeMask 0x000000c0
  2429. #define KS_INTERLACE_DisplayModeBobOnly 0x00000000
  2430. #define KS_INTERLACE_DisplayModeWeaveOnly 0x00000040
  2431. #define KS_INTERLACE_DisplayModeBobOrWeave 0x00000080
  2432. #define KS_MPEG2_DoPanScan 0x00000001 //if set, the MPEG-2 video decoder should crop output image
  2433. // based on pan-scan vectors in picture_display_extension
  2434. // and change the picture aspect ratio accordingly.
  2435. #define KS_MPEG2_DVDLine21Field1 0x00000002 //if set, the MPEG-2 decoder must be able to produce an output
  2436. // pin for DVD style closed caption data found in GOP layer of field 1
  2437. #define KS_MPEG2_DVDLine21Field2 0x00000004 //if set, the MPEG-2 decoder must be able to produce an output
  2438. // pin for DVD style closed caption data found in GOP layer of field 2
  2439. #define KS_MPEG2_SourceIsLetterboxed 0x00000008 //if set, indicates that black bars have been encoded in the top
  2440. // and bottom of the video.
  2441. #define KS_MPEG2_FilmCameraMode 0x00000010 //if set, indicates "film mode" used for 625/50 content. If cleared,
  2442. // indicates that "camera mode" was used.
  2443. #define KS_MPEG2_LetterboxAnalogOut 0x00000020 //if set and this stream is sent to an analog output, it should
  2444. // be letterboxed. Streams sent to VGA should be letterboxed only by renderers.
  2445. #define KS_MPEG2_DSS_UserData 0x00000040 //if set, the MPEG-2 decoder must process DSS style user data
  2446. #define KS_MPEG2_DVB_UserData 0x00000080 //if set, the MPEG-2 decoder must process DVB style user data
  2447. #define KS_MPEG2_27MhzTimebase 0x00000100 //if set, the PTS,DTS timestamps advance at 27MHz rather than 90KHz
  2448. typedef struct tagKS_VIDEOINFOHEADER2 {
  2449. RECT rcSource;
  2450. RECT rcTarget;
  2451. DWORD dwBitRate;
  2452. DWORD dwBitErrorRate;
  2453. REFERENCE_TIME AvgTimePerFrame;
  2454. DWORD dwInterlaceFlags; // use AMINTERLACE_* defines. Reject connection if undefined bits are not 0
  2455. DWORD dwCopyProtectFlags; // use AMCOPYPROTECT_* defines. Reject connection if undefined bits are not 0
  2456. DWORD dwPictAspectRatioX; // X dimension of picture aspect ratio, e.g. 16 for 16x9 display
  2457. DWORD dwPictAspectRatioY; // Y dimension of picture aspect ratio, e.g. 9 for 16x9 display
  2458. DWORD dwReserved1; // must be 0; reject connection otherwise
  2459. DWORD dwReserved2; // must be 0; reject connection otherwise
  2460. KS_BITMAPINFOHEADER bmiHeader;
  2461. } KS_VIDEOINFOHEADER2, *PKS_VIDEOINFOHEADER2;
  2462. typedef struct tagKS_MPEG1VIDEOINFO {
  2463. KS_VIDEOINFOHEADER hdr; // Compatible with VIDEOINFO
  2464. DWORD dwStartTimeCode; // 25-bit Group of pictures time code at start of data
  2465. DWORD cbSequenceHeader; // Length in bytes of bSequenceHeader
  2466. BYTE bSequenceHeader[1]; // Sequence header including quantization matrices if any
  2467. } KS_MPEG1VIDEOINFO, *PKS_MPEG1VIDEOINFO;
  2468. #define KS_MAX_SIZE_MPEG1_SEQUENCE_INFO 140
  2469. #define KS_SIZE_MPEG1VIDEOINFO(pv) (FIELD_OFFSET(KS_MPEG1VIDEOINFO, bSequenceHeader[0]) + (pv)->cbSequenceHeader)
  2470. #define KS_MPEG1_SEQUENCE_INFO(pv) ((const BYTE *)(pv)->bSequenceHeader)
  2471. typedef struct tagKS_MPEGVIDEOINFO2 {
  2472. KS_VIDEOINFOHEADER2 hdr;
  2473. DWORD dwStartTimeCode; // ?? not used for DVD ??
  2474. DWORD cbSequenceHeader; // is 0 for DVD (no sequence header)
  2475. DWORD dwProfile; // use enum MPEG2Profile
  2476. DWORD dwLevel; // use enum MPEG2Level
  2477. DWORD dwFlags; // use AMMPEG2_* defines. Reject connection if undefined bits are not 0
  2478. DWORD bSequenceHeader[1]; // DWORD instead of Byte for alignment purposes
  2479. // For MPEG-2, if a sequence_header is included, the sequence_extension
  2480. // should also be included
  2481. } KS_MPEGVIDEOINFO2, *PKS_MPEGVIDEOINFO2;
  2482. #define KS_SIZE_MPEGVIDEOINFO2(pv) (FIELD_OFFSET(KS_MPEGVIDEOINFO2, bSequenceHeader[0]) + (pv)->cbSequenceHeader)
  2483. #define KS_MPEG1_SEQUENCE_INFO(pv) ((const BYTE *)(pv)->bSequenceHeader)
  2484. //===========================================================================
  2485. // Audio format blocks
  2486. //===========================================================================
  2487. //if set, the PTS,DTS timestamps advance at 27MHz rather than 90KHz
  2488. #define KS_MPEGAUDIOINFO_27MhzTimebase 0x00000001
  2489. typedef struct tagKS_MPEAUDIOINFO {
  2490. DWORD dwFlags; // use KS_MPEGAUDIOINFO_* defines. Reject connection if undefined bits are not 0
  2491. DWORD dwReserved1; // must be 0; reject connection otherwise
  2492. DWORD dwReserved2; // must be 0; reject connection otherwise
  2493. DWORD dwReserved3; // must be 0; reject connection otherwise
  2494. } KS_MPEGAUDIOINFO, *PKS_MPEGAUDIOINFO;
  2495. //===========================================================================
  2496. // Video DATAFORMATs
  2497. //===========================================================================
  2498. typedef struct tagKS_DATAFORMAT_VIDEOINFOHEADER {
  2499. KSDATAFORMAT DataFormat;
  2500. KS_VIDEOINFOHEADER VideoInfoHeader;
  2501. } KS_DATAFORMAT_VIDEOINFOHEADER, *PKS_DATAFORMAT_VIDEOINFOHEADER;
  2502. typedef struct tagKS_DATAFORMAT_VIDEOINFOHEADER2 {
  2503. KSDATAFORMAT DataFormat;
  2504. KS_VIDEOINFOHEADER2 VideoInfoHeader2;
  2505. } KS_DATAFORMAT_VIDEOINFOHEADER2, *PKS_DATAFORMAT_VIDEOINFOHEADER2;
  2506. typedef struct tagKS_DATAFORMAT_VIDEOINFO_PALETTE {
  2507. KSDATAFORMAT DataFormat;
  2508. KS_VIDEOINFO VideoInfo;
  2509. } KS_DATAFORMAT_VIDEOINFO_PALETTE, *PKS_DATAFORMAT_VIDEOINFO_PALETTE;
  2510. typedef struct tagKS_DATAFORMAT_VBIINFOHEADER {
  2511. KSDATAFORMAT DataFormat;
  2512. KS_VBIINFOHEADER VBIInfoHeader;
  2513. } KS_DATAFORMAT_VBIINFOHEADER, *PKS_DATAFORMAT_VBIINFOHEADER;
  2514. typedef struct _KS_VIDEO_STREAM_CONFIG_CAPS {
  2515. GUID guid; // will be MEDIATYPE_Video
  2516. ULONG VideoStandard; // logical OR of all AnalogVideoStandards
  2517. // supported
  2518. SIZE InputSize; // the inherent size of the incoming signal
  2519. // (every pixel unique)
  2520. SIZE MinCroppingSize; // smallest rcSrc cropping rect allowed
  2521. SIZE MaxCroppingSize; // largest rcSrc cropping rect allowed
  2522. int CropGranularityX; // granularity of cropping size
  2523. int CropGranularityY;
  2524. int CropAlignX; // alignment of cropping rect
  2525. int CropAlignY;
  2526. SIZE MinOutputSize; // smallest bitmap stream can produce
  2527. SIZE MaxOutputSize; // largest bitmap stream can produce
  2528. int OutputGranularityX; // granularity of output bitmap size
  2529. int OutputGranularityY;
  2530. int StretchTapsX; // 0, no stretch, 1 pix dup, 2 interp, ...
  2531. int StretchTapsY; // Describes quality of hardware scaler
  2532. int ShrinkTapsX; //
  2533. int ShrinkTapsY; //
  2534. LONGLONG MinFrameInterval; // 100 nS units
  2535. LONGLONG MaxFrameInterval;
  2536. LONG MinBitsPerSecond;
  2537. LONG MaxBitsPerSecond;
  2538. } KS_VIDEO_STREAM_CONFIG_CAPS, *PKS_VIDEO_STREAM_CONFIG_CAPS;
  2539. //===========================================================================
  2540. // Video DATARANGEs
  2541. //===========================================================================
  2542. typedef struct tagKS_DATARANGE_VIDEO {
  2543. KSDATARANGE DataRange;
  2544. BOOL bFixedSizeSamples; // all samples same size?
  2545. BOOL bTemporalCompression; // all I frames?
  2546. DWORD StreamDescriptionFlags; // KS_VIDEO_DESC_*
  2547. DWORD MemoryAllocationFlags; // KS_VIDEO_ALLOC_*
  2548. KS_VIDEO_STREAM_CONFIG_CAPS ConfigCaps;
  2549. KS_VIDEOINFOHEADER VideoInfoHeader; // default format
  2550. } KS_DATARANGE_VIDEO, *PKS_DATARANGE_VIDEO;
  2551. typedef struct tagKS_DATARANGE_VIDEO2 {
  2552. KSDATARANGE DataRange;
  2553. BOOL bFixedSizeSamples; // all samples same size?
  2554. BOOL bTemporalCompression; // all I frames?
  2555. DWORD StreamDescriptionFlags; // KS_VIDEO_DESC_*
  2556. DWORD MemoryAllocationFlags; // KS_VIDEO_ALLOC_*
  2557. KS_VIDEO_STREAM_CONFIG_CAPS ConfigCaps;
  2558. KS_VIDEOINFOHEADER2 VideoInfoHeader; // default format
  2559. } KS_DATARANGE_VIDEO2, *PKS_DATARANGE_VIDEO2;
  2560. typedef struct tagKS_DATARANGE_MPEG1_VIDEO {
  2561. KSDATARANGE DataRange;
  2562. BOOL bFixedSizeSamples; // all samples same size?
  2563. BOOL bTemporalCompression; // all I frames?
  2564. DWORD StreamDescriptionFlags; // KS_VIDEO_DESC_*
  2565. DWORD MemoryAllocationFlags; // KS_VIDEO_ALLOC_*
  2566. KS_VIDEO_STREAM_CONFIG_CAPS ConfigCaps;
  2567. KS_MPEG1VIDEOINFO VideoInfoHeader; // default format
  2568. } KS_DATARANGE_MPEG1_VIDEO, *PKS_DATARANGE_MPEG1_VIDEO;
  2569. typedef struct tagKS_DATARANGE_MPEG2_VIDEO {
  2570. KSDATARANGE DataRange;
  2571. BOOL bFixedSizeSamples; // all samples same size?
  2572. BOOL bTemporalCompression; // all I frames?
  2573. DWORD StreamDescriptionFlags; // KS_VIDEO_DESC_*
  2574. DWORD MemoryAllocationFlags; // KS_VIDEO_ALLOC_*
  2575. KS_VIDEO_STREAM_CONFIG_CAPS ConfigCaps;
  2576. KS_MPEGVIDEOINFO2 VideoInfoHeader; // default format
  2577. } KS_DATARANGE_MPEG2_VIDEO, *PKS_DATARANGE_MPEG2_VIDEO;
  2578. typedef struct tagKS_DATARANGE_VIDEO_PALETTE {
  2579. KSDATARANGE DataRange;
  2580. BOOL bFixedSizeSamples; // all samples same size?
  2581. BOOL bTemporalCompression; // all I frames?
  2582. DWORD StreamDescriptionFlags; // KS_VIDEO_DESC_*
  2583. DWORD MemoryAllocationFlags; // KS_VIDEO_ALLOC_*
  2584. KS_VIDEO_STREAM_CONFIG_CAPS ConfigCaps;
  2585. KS_VIDEOINFO VideoInfo; // default format
  2586. } KS_DATARANGE_VIDEO_PALETTE, *PKS_DATARANGE_VIDEO_PALETTE;
  2587. typedef struct tagKS_DATARANGE_VIDEO_VBI {
  2588. KSDATARANGE DataRange;
  2589. BOOL bFixedSizeSamples; // all samples same size?
  2590. BOOL bTemporalCompression; // all I frames?
  2591. DWORD StreamDescriptionFlags; // KS_VIDEO_DESC_*
  2592. DWORD MemoryAllocationFlags; // KS_VIDEO_ALLOC_*
  2593. KS_VIDEO_STREAM_CONFIG_CAPS ConfigCaps;
  2594. KS_VBIINFOHEADER VBIInfoHeader; // default format
  2595. } KS_DATARANGE_VIDEO_VBI, *PKS_DATARANGE_VIDEO_VBI;
  2596. typedef struct tagKS_DATARANGE_ANALOGVIDEO {
  2597. KSDATARANGE DataRange;
  2598. KS_ANALOGVIDEOINFO AnalogVideoInfo;
  2599. } KS_DATARANGE_ANALOGVIDEO, *PKS_DATARANGE_ANALOGVIDEO;
  2600. //===========================================================================
  2601. // StreamDescriptionFlags
  2602. //
  2603. // These define the "purpose" of each video stream
  2604. //===========================================================================
  2605. #define KS_VIDEOSTREAM_PREVIEW 0x0001 // Preview stream
  2606. #define KS_VIDEOSTREAM_CAPTURE 0x0002 // Capture stream
  2607. #define KS_VIDEOSTREAM_VBI 0x0010 // Field1 VBI
  2608. #define KS_VIDEOSTREAM_NABTS 0x0020 // Field1 NABTS
  2609. #define KS_VIDEOSTREAM_CC 0x0100 // Closed Captioning
  2610. #define KS_VIDEOSTREAM_EDS 0x0200 // Extended Data Services
  2611. #define KS_VIDEOSTREAM_TELETEXT 0x0400 // Field1 Teletext only
  2612. #define KS_VIDEOSTREAM_STILL 0x1000 // Still image input
  2613. #define KS_VIDEOSTREAM_IS_VPE 0x8000 // Is a VPE based stream?
  2614. // MemoryAllocationFlags
  2615. #define KS_VIDEO_ALLOC_VPE_SYSTEM 0x0001 // VPE surface in system memory
  2616. #define KS_VIDEO_ALLOC_VPE_DISPLAY 0x0002 // VPE surface in display memory
  2617. #define KS_VIDEO_ALLOC_VPE_AGP 0x0004 // VPE surface in AGP memory
  2618. //////////////////////////////////////////////////////////////
  2619. // Capture driver VBI property sets
  2620. //////////////////////////////////////////////////////////////
  2621. // {F162C607-7B35-496f-AD7F-2DCA3B46B718}
  2622. #define STATIC_KSPROPSETID_VBICAP_PROPERTIES\
  2623. 0xf162c607, 0x7b35, 0x496f, 0xad, 0x7f, 0x2d, 0xca, 0x3b, 0x46, 0xb7, 0x18
  2624. DEFINE_GUIDSTRUCT("F162C607-7B35-496f-AD7F-2DCA3B46B718", KSPROPSETID_VBICAP_PROPERTIES);
  2625. #define KSPROPSETID_VBICAP_PROPERTIES DEFINE_GUIDNAMED(KSPROPSETID_VBICAP_PROPERTIES)
  2626. typedef enum {
  2627. KSPROPERTY_VBICAP_PROPERTIES_PROTECTION = 0x01,
  2628. } KSPROPERTY_VBICAP;
  2629. typedef struct _VBICAP_PROPERTIES_PROTECTION_S {
  2630. KSPROPERTY Property;
  2631. ULONG StreamIndex; // Index of stream
  2632. ULONG Status;
  2633. } VBICAP_PROPERTIES_PROTECTION_S, *PVBICAP_PROPERTIES_PROTECTION_S;
  2634. #define KS_VBICAP_PROTECTION_MV_PRESENT 0x0001L
  2635. #define KS_VBICAP_PROTECTION_MV_HARDWARE 0x0002L
  2636. #define KS_VBICAP_PROTECTION_MV_DETECTED 0x0004L
  2637. /***************************************************************************/
  2638. /* VBI Related GUIDs, structs and properties for codecs(generic, cc, nabts)*/
  2639. /***************************************************************************/
  2640. ///////////////////////////////////////////////////////////////////////////////////////
  2641. // IP/NABTS Protocol Reserved Group IDs - Overall Range 0x800-0x8FF [Decimal 2048-2079]
  2642. // Intervening values(0-F) are used if there are multiple providers at a particular tier
  2643. ///////////////////////////////////////////////////////////////////////////////////////
  2644. // Used by individual content creators in show footage/data
  2645. #define KS_NABTS_GROUPID_ORIGINAL_CONTENT_BASE 0x800
  2646. #define KS_NABTS_GROUPID_ORIGINAL_CONTENT_ADVERTISER_BASE 0x810
  2647. // Used by production company in finished show data
  2648. #define KS_NABTS_GROUPID_PRODUCTION_COMPANY_CONTENT_BASE 0x820
  2649. #define KS_NABTS_GROUPID_PRODUCTION_COMPANY_ADVERTISER_BASE 0x830
  2650. // Used by broadcast syndicates in syndicated show data
  2651. #define KS_NABTS_GROUPID_SYNDICATED_SHOW_CONTENT_BASE 0x840
  2652. #define KS_NABTS_GROUPID_SYNDICATED_SHOW_ADVERTISER_BASE 0x850
  2653. // Used by tv networks in network television data
  2654. #define KS_NABTS_GROUPID_NETWORK_WIDE_CONTENT_BASE 0x860
  2655. #define KS_NABTS_GROUPID_NETWORK_WIDE_ADVERTISER_BASE 0x870
  2656. // Used by telvision stations in local programming data
  2657. #define KS_NABTS_GROUPID_TELEVISION_STATION_CONTENT_BASE 0x880
  2658. #define KS_NABTS_GROUPID_TELEVISION_STATION_ADVERTISER_BASE 0x890
  2659. // Used by cable system in cable head-end originated data
  2660. #define KS_NABTS_GROUPID_LOCAL_CABLE_SYSTEM_CONTENT_BASE 0x8A0
  2661. #define KS_NABTS_GROUPID_LOCAL_CABLE_SYSTEM_ADVERTISER_BASE 0x8B0
  2662. // The values between 0x8C0 - 0x8EF are reserved for future expansion
  2663. // Used by Microsoft for Testing purposes (0x8F0 - 0x8FF)
  2664. #define KS_NABTS_GROUPID_MICROSOFT_RESERVED_TEST_DATA_BASE 0x8F0
  2665. //////////////////////////////////////////////////////////////
  2666. // Stream Format FEC-corrected NABTS bundles
  2667. //////////////////////////////////////////////////////////////
  2668. #define STATIC_KSDATAFORMAT_TYPE_NABTS \
  2669. 0xe757bca0, 0x39ac, 0x11d1, 0xa9, 0xf5, 0x0, 0xc0, 0x4f, 0xbb, 0xde, 0x8f
  2670. DEFINE_GUIDSTRUCT("E757BCA0-39AC-11d1-A9F5-00C04FBBDE8F", KSDATAFORMAT_TYPE_NABTS);
  2671. #define KSDATAFORMAT_TYPE_NABTS DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_NABTS)
  2672. #define STATIC_KSDATAFORMAT_SUBTYPE_NABTS_FEC \
  2673. 0xe757bca1, 0x39ac, 0x11d1, 0xa9, 0xf5, 0x0, 0xc0, 0x4f, 0xbb, 0xde, 0x8f
  2674. DEFINE_GUIDSTRUCT("E757BCA1-39AC-11d1-A9F5-00C04FBBDE8F", KSDATAFORMAT_SUBTYPE_NABTS_FEC);
  2675. #define KSDATAFORMAT_SUBTYPE_NABTS_FEC DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_NABTS_FEC)
  2676. //////////////////////////////////////////////////////////////
  2677. // NABTS Bundle data structure definition
  2678. //////////////////////////////////////////////////////////////
  2679. #define MAX_NABTS_VBI_LINES_PER_FIELD 11
  2680. #define NABTS_LINES_PER_BUNDLE 16
  2681. #define NABTS_PAYLOAD_PER_LINE 28
  2682. #define NABTS_BYTES_PER_LINE 36
  2683. typedef struct _NABTSFEC_BUFFER {
  2684. ULONG dataSize;
  2685. USHORT groupID;
  2686. USHORT Reserved;
  2687. UCHAR data[NABTS_LINES_PER_BUNDLE * NABTS_PAYLOAD_PER_LINE];
  2688. } NABTSFEC_BUFFER, *PNABTSFEC_BUFFER;
  2689. //////////////////////////////////////////////////////////////
  2690. // vbi codec filtering pin properties
  2691. //////////////////////////////////////////////////////////////
  2692. #define STATIC_KSPROPSETID_VBICodecFiltering \
  2693. 0xcafeb0caL, 0x8715, 0x11d0, 0xbd, 0x6a, 0x00, 0x35, 0xc0, 0xed, 0xba, 0xbe
  2694. DEFINE_GUIDSTRUCT("cafeb0ca-8715-11d0-bd6a-0035c0edbabe", KSPROPSETID_VBICodecFiltering);
  2695. #define KSPROPSETID_VBICodecFiltering DEFINE_GUIDNAMED(KSPROPSETID_VBICodecFiltering)
  2696. typedef enum {
  2697. KSPROPERTY_VBICODECFILTERING_SCANLINES_REQUESTED_BIT_ARRAY = 0x01,
  2698. KSPROPERTY_VBICODECFILTERING_SCANLINES_DISCOVERED_BIT_ARRAY,
  2699. KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_REQUESTED_BIT_ARRAY,
  2700. KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_DISCOVERED_BIT_ARRAY,
  2701. KSPROPERTY_VBICODECFILTERING_STATISTICS,
  2702. } KSPROPERTY_VBICODECFILTERING;
  2703. typedef struct _VBICODECFILTERING_SCANLINES {
  2704. DWORD DwordBitArray[32]; // An array of scanline bits 0..1024(32*32)
  2705. } VBICODECFILTERING_SCANLINES, *PVBICODECFILTERING_SCANLINES;
  2706. typedef struct _VBICODECFILTERING_NABTS_SUBSTREAMS {
  2707. DWORD SubstreamMask[128]; // An array of 4096 bits (one for each NABTS GroupID)
  2708. } VBICODECFILTERING_NABTS_SUBSTREAMS, *PVBICODECFILTERING_NABTS_SUBSTREAMS;
  2709. typedef struct _VBICODECFILTERING_CC_SUBSTREAMS {
  2710. DWORD SubstreamMask; // An array of 32 bits (see KS_CC_SUBSTREAM *)
  2711. } VBICODECFILTERING_CC_SUBSTREAMS, *PVBICODECFILTERING_CC_SUBSTREAMS;
  2712. // These KS_CC_SUBSTREAM_* bitmasks are used with VBICODECFILTERING_CC_SUBSTREAMS
  2713. #define KS_CC_SUBSTREAM_ODD 0x0001L // Unfiltered Field 1 Data
  2714. #define KS_CC_SUBSTREAM_EVEN 0x0002L // Unfiltered Field 2 Data
  2715. // The following flags describe CC field 1 substreams: CC1,CC2,TT1,TT2
  2716. #define KS_CC_SUBSTREAM_FIELD1_MASK 0x00F0L
  2717. #define KS_CC_SUBSTREAM_SERVICE_CC1 0x0010L
  2718. #define KS_CC_SUBSTREAM_SERVICE_CC2 0x0020L
  2719. #define KS_CC_SUBSTREAM_SERVICE_T1 0x0040L
  2720. #define KS_CC_SUBSTREAM_SERVICE_T2 0x0080L
  2721. // The following flags describe CC field 2 substreams: CC3,CC4,TT3,TT4,XDS
  2722. #define KS_CC_SUBSTREAM_FIELD2_MASK 0x1F00L
  2723. #define KS_CC_SUBSTREAM_SERVICE_CC3 0x0100L
  2724. #define KS_CC_SUBSTREAM_SERVICE_CC4 0x0200L
  2725. #define KS_CC_SUBSTREAM_SERVICE_T3 0x0400L
  2726. #define KS_CC_SUBSTREAM_SERVICE_T4 0x0800L
  2727. #define KS_CC_SUBSTREAM_SERVICE_XDS 0x1000L
  2728. // Special Note: field 1 or 2 substreams are usually on found on field 1 and 2 respectively
  2729. // If the VBI odd/even polarity is reversed, the correct filtered data will still be found.
  2730. ///////////////////////////////////////////////////////////////////
  2731. // Hardware decoded CC stream format
  2732. ///////////////////////////////////////////////////////////////////
  2733. #define CC_MAX_HW_DECODE_LINES 12
  2734. typedef struct _CC_BYTE_PAIR {
  2735. BYTE Decoded[2];
  2736. USHORT Reserved;
  2737. } CC_BYTE_PAIR, *PCC_BYTE_PAIR;
  2738. typedef struct _CC_HW_FIELD {
  2739. VBICODECFILTERING_SCANLINES ScanlinesRequested;
  2740. ULONG fieldFlags; // KS_VBI_FLAG_FIELD1,2
  2741. LONGLONG PictureNumber;
  2742. CC_BYTE_PAIR Lines[CC_MAX_HW_DECODE_LINES];
  2743. } CC_HW_FIELD, *PCC_HW_FIELD;
  2744. ///////////////////////////////////////////////////////////////////
  2745. // Raw NABTS stream format (TYPE_NABTS, SUBTYPE_NABTS)
  2746. ///////////////////////////////////////////////////////////////////
  2747. // These low-level structures are byte packed( -Zp1 )
  2748. #if !defined( PACK_PRAGMAS_NOT_SUPPORTED )
  2749. #include <pshpack1.h>
  2750. #endif
  2751. typedef struct _NABTS_BUFFER_LINE {
  2752. BYTE Confidence;
  2753. BYTE Bytes[NABTS_BYTES_PER_LINE];
  2754. } NABTS_BUFFER_LINE, *PNABTS_BUFFER_LINE;
  2755. #define NABTS_BUFFER_PICTURENUMBER_SUPPORT 1
  2756. typedef struct _NABTS_BUFFER {
  2757. VBICODECFILTERING_SCANLINES ScanlinesRequested;
  2758. LONGLONG PictureNumber;
  2759. NABTS_BUFFER_LINE NabtsLines[MAX_NABTS_VBI_LINES_PER_FIELD];
  2760. } NABTS_BUFFER, *PNABTS_BUFFER;
  2761. #if !defined( PACK_PRAGMAS_NOT_SUPPORTED )
  2762. #include <poppack.h>
  2763. #endif
  2764. //////////////////////////////////////////////////////////////
  2765. // WST Codec Teletext Media Sample Format
  2766. //////////////////////////////////////////////////////////////
  2767. #define WST_TVTUNER_CHANGE_BEGIN_TUNE 0x1000L // Starting a tuning operation
  2768. #define WST_TVTUNER_CHANGE_END_TUNE 0x2000L // Ending a tuning operation
  2769. #define MAX_WST_VBI_LINES_PER_FIELD 17
  2770. #define WST_BYTES_PER_LINE 42
  2771. typedef struct _WST_BUFFER_LINE {
  2772. BYTE Confidence;
  2773. BYTE Bytes[WST_BYTES_PER_LINE];
  2774. } WST_BUFFER_LINE, *PWST_BUFFER_LINE;
  2775. typedef struct _WST_BUFFER {
  2776. VBICODECFILTERING_SCANLINES ScanlinesRequested;
  2777. WST_BUFFER_LINE WstLines[MAX_WST_VBI_LINES_PER_FIELD];
  2778. } WST_BUFFER, *PWST_BUFFER;
  2779. //
  2780. // Common codec statistics
  2781. //
  2782. typedef struct _VBICODECFILTERING_STATISTICS_COMMON {
  2783. DWORD InputSRBsProcessed; // upstream SRBs received
  2784. DWORD OutputSRBsProcessed; // downstream SRBs sent
  2785. DWORD SRBsIgnored; // SRBs ignored due to no requests
  2786. DWORD InputSRBsMissing; // SRBs dropped upstream
  2787. DWORD OutputSRBsMissing; // Output dropped because no SRB pending
  2788. DWORD OutputFailures; // dropped because of other failure
  2789. DWORD InternalErrors; // could not process due to int. failure
  2790. DWORD ExternalErrors; // could not process due to ext. failure
  2791. DWORD InputDiscontinuities; // discontinuities received
  2792. DWORD DSPFailures; // DSP confidence failure
  2793. DWORD TvTunerChanges; // number of received KS_TVTUNER_CHANGE_BEGIN_TUNE and KS_TVTUNER_CHANGE_END_TUNE pairs.
  2794. DWORD VBIHeaderChanges; // number of received KS_VBI_FLAG_VBIINFOHEADER_CHANGE
  2795. DWORD LineConfidenceAvg; // Average of all DSP confidence results
  2796. DWORD BytesOutput; // Bytes sent downstream
  2797. } VBICODECFILTERING_STATISTICS_COMMON, *PVBICODECFILTERING_STATISTICS_COMMON;
  2798. typedef struct _VBICODECFILTERING_STATISTICS_COMMON_PIN {
  2799. DWORD SRBsProcessed; // SRBs sent/received
  2800. DWORD SRBsIgnored; // SRBs ignored due to filtering
  2801. DWORD SRBsMissing; // SRBs not sent/received
  2802. DWORD InternalErrors; // could not send/receive due to int. failure
  2803. DWORD ExternalErrors; // could not send/receive due to ext. failure
  2804. DWORD Discontinuities; // discontinuities received/sent
  2805. DWORD LineConfidenceAvg; // Average of all DSP confidence results for this pin
  2806. DWORD BytesOutput; // Bytes sent downstream
  2807. } VBICODECFILTERING_STATISTICS_COMMON_PIN, *PVBICODECFILTERING_STATISTICS_COMMON_PIN;
  2808. //
  2809. // Codec-specific statistics - NABTS
  2810. //
  2811. typedef struct _VBICODECFILTERING_STATISTICS_NABTS {
  2812. VBICODECFILTERING_STATISTICS_COMMON Common; // Generic VBI statistics
  2813. DWORD FECBundleBadLines; // Un-FEC-correctable lines
  2814. DWORD FECQueueOverflows; // Number of times FEC queue overflowed
  2815. DWORD FECCorrectedLines; // Lines CSUM corrected by FEC
  2816. DWORD FECUncorrectableLines; // FEC input lines not CSUM correctable
  2817. DWORD BundlesProcessed; // Bundles received from FEC
  2818. DWORD BundlesSent2IP; // Bundles sent to IP driver
  2819. DWORD FilteredLines; // Lines processed and then dropped
  2820. // because no one was interested
  2821. } VBICODECFILTERING_STATISTICS_NABTS, *PVBICODECFILTERING_STATISTICS_NABTS;
  2822. typedef struct _VBICODECFILTERING_STATISTICS_NABTS_PIN {
  2823. VBICODECFILTERING_STATISTICS_COMMON_PIN Common;// Generic VBI pin statistics
  2824. } VBICODECFILTERING_STATISTICS_NABTS_PIN, *PVBICODECFILTERING_STATISTICS_NABTS_PIN;
  2825. //
  2826. // Codec-specific statistics - Closed Caption
  2827. //
  2828. typedef struct _VBICODECFILTERING_STATISTICS_CC {
  2829. VBICODECFILTERING_STATISTICS_COMMON Common; // Generic VBI statistics
  2830. } VBICODECFILTERING_STATISTICS_CC, *PVBICODECFILTERING_STATISTICS_CC;
  2831. typedef struct _VBICODECFILTERING_STATISTICS_CC_PIN {
  2832. VBICODECFILTERING_STATISTICS_COMMON_PIN Common;// Generic VBI pin statistics
  2833. } VBICODECFILTERING_STATISTICS_CC_PIN, *PVBICODECFILTERING_STATISTICS_CC_PIN;
  2834. //
  2835. // Codec-specific statistics - Closed Caption
  2836. //
  2837. typedef struct _VBICODECFILTERING_STATISTICS_TELETEXT {
  2838. VBICODECFILTERING_STATISTICS_COMMON Common; // Generic VBI statistics
  2839. } VBICODECFILTERING_STATISTICS_TELETEXT, *PVBICODECFILTERING_STATISTICS_TELETEXT;
  2840. typedef struct _VBICODECFILTERING_STATISTICS_TELETEXT_PIN {
  2841. VBICODECFILTERING_STATISTICS_COMMON_PIN Common;// Generic VBI pin statistics
  2842. } VBICODECFILTERING_STATISTICS_TELETEXT_PIN, *PVBICODECFILTERING_STATISTICS_TELETEXT_PIN;
  2843. ////////////////////////////////////////////////////////////////////////////
  2844. // VBI codec property structures(based on KSPROPERTY_VBICODECFILTERING enum)
  2845. ////////////////////////////////////////////////////////////////////////////
  2846. // *** Most codecs support this property
  2847. // KSPROPERTY_VBICODECFILTERING_SCANLINES_REQUESTED_BIT_ARRAY
  2848. // KSPROPERTY_VBICODECFILTERING_SCANLINES_DISCOVERED_BIT_ARRAY,
  2849. typedef struct {
  2850. KSPROPERTY Property;
  2851. VBICODECFILTERING_SCANLINES Scanlines;
  2852. } KSPROPERTY_VBICODECFILTERING_SCANLINES_S, *PKSPROPERTY_VBICODECFILTERING_SCANLINES_S;
  2853. // *** NABTS codecs support this property
  2854. // KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_REQUESTED_BIT_ARRAY,
  2855. // KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_DISCOVERED_BIT_ARRAY,
  2856. typedef struct {
  2857. KSPROPERTY Property;
  2858. VBICODECFILTERING_NABTS_SUBSTREAMS Substreams;
  2859. } KSPROPERTY_VBICODECFILTERING_NABTS_SUBSTREAMS_S, *PKSPROPERTY_VBICODECFILTERING_NABTS_SUBSTREAMS_S;
  2860. // *** Closed captioning codecs support this property
  2861. // KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_REQUESTED_BIT_ARRAY,
  2862. // KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_DISCOVERED_BIT_ARRAY,
  2863. typedef struct {
  2864. KSPROPERTY Property;
  2865. VBICODECFILTERING_CC_SUBSTREAMS Substreams;
  2866. } KSPROPERTY_VBICODECFILTERING_CC_SUBSTREAMS_S, *PKSPROPERTY_VBICODECFILTERING_CC_SUBSTREAMS_S;
  2867. // *** Most codecs support these versions of the global and pin properties
  2868. // KSPROPERTY_VBICODECFILTERING_STATISTICS
  2869. typedef struct {
  2870. KSPROPERTY Property;
  2871. VBICODECFILTERING_STATISTICS_COMMON Statistics;
  2872. } KSPROPERTY_VBICODECFILTERING_STATISTICS_COMMON_S, *PKSPROPERTY_VBICODECFILTERING_STATISTICS_COMMON_S;
  2873. typedef struct {
  2874. KSPROPERTY Property;
  2875. VBICODECFILTERING_STATISTICS_COMMON_PIN Statistics;
  2876. } KSPROPERTY_VBICODECFILTERING_STATISTICS_COMMON_PIN_S, *PKSPROPERTY_VBICODECFILTERING_STATISTICS_COMMON_PIN_S;
  2877. // *** NABTS codecs support this version of the global and pin properties
  2878. // KSPROPERTY_VBICODECFILTERING_STATISTICS
  2879. typedef struct {
  2880. KSPROPERTY Property;
  2881. VBICODECFILTERING_STATISTICS_NABTS Statistics;
  2882. } KSPROPERTY_VBICODECFILTERING_STATISTICS_NABTS_S, *PKSPROPERTY_VBICODECFILTERING_STATISTICS_NABTS_S;
  2883. typedef struct {
  2884. KSPROPERTY Property;
  2885. VBICODECFILTERING_STATISTICS_NABTS_PIN Statistics;
  2886. } KSPROPERTY_VBICODECFILTERING_STATISTICS_NABTS_PIN_S, *PKSPROPERTY_VBICODECFILTERING_STATISTICS_NABTS_PIN_S;
  2887. // *** Closed captioning codecs support this version of the global and pin properties
  2888. // KSPROPERTY_VBICODECFILTERING_STATISTICS
  2889. typedef struct {
  2890. KSPROPERTY Property;
  2891. VBICODECFILTERING_STATISTICS_CC Statistics;
  2892. } KSPROPERTY_VBICODECFILTERING_STATISTICS_CC_S, *PKSPROPERTY_VBICODECFILTERING_STATISTICS_CC_S;
  2893. typedef struct {
  2894. KSPROPERTY Property;
  2895. VBICODECFILTERING_STATISTICS_CC_PIN Statistics;
  2896. } KSPROPERTY_VBICODECFILTERING_STATISTICS_CC_PIN_S, *PKSPROPERTY_VBICODECFILTERING_STATISTICS_CC_PIN_S;
  2897. // Standard Pin Names for the video capture filter
  2898. //===========================================================================
  2899. #define STATIC_PINNAME_VIDEO_CAPTURE \
  2900. 0xfb6c4281, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2901. #define STATIC_PINNAME_CAPTURE STATIC_PINNAME_VIDEO_CAPTURE
  2902. DEFINE_GUIDSTRUCT("FB6C4281-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_CAPTURE);
  2903. #define PINNAME_VIDEO_CAPTURE DEFINE_GUIDNAMED(PINNAME_VIDEO_CAPTURE)
  2904. #define PINNAME_CAPTURE PINNAME_VIDEO_CAPTURE
  2905. #define STATIC_PINNAME_VIDEO_CC_CAPTURE \
  2906. 0x1aad8061, 0x12d, 0x11d2, 0xb4, 0xb1, 0x0, 0xa0, 0xd1, 0x2, 0xcf, 0xbe
  2907. #define STATIC_PINNAME_CC_CAPTURE STATIC_PINNAME_VIDEO_CC_CAPTURE
  2908. DEFINE_GUIDSTRUCT("1AAD8061-012D-11d2-B4B1-00A0D102CFBE", PINNAME_VIDEO_CC_CAPTURE);
  2909. #define PINNAME_VIDEO_CC_CAPTURE DEFINE_GUIDNAMED(PINNAME_VIDEO_CC_CAPTURE)
  2910. #define STATIC_PINNAME_VIDEO_NABTS_CAPTURE \
  2911. 0x29703660, 0x498a, 0x11d2, 0xb4, 0xb1, 0x0, 0xa0, 0xd1, 0x2, 0xcf, 0xbe
  2912. #define STATIC_PINNAME_NABTS_CAPTURE STATIC_PINNAME_VIDEO_NABTS_CAPTURE
  2913. DEFINE_GUIDSTRUCT("29703660-498A-11d2-B4B1-00A0D102CFBE", PINNAME_VIDEO_NABTS_CAPTURE);
  2914. #define PINNAME_VIDEO_NABTS_CAPTURE DEFINE_GUIDNAMED(PINNAME_VIDEO_NABTS_CAPTURE)
  2915. #define STATIC_PINNAME_VIDEO_PREVIEW \
  2916. 0xfb6c4282, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2917. #define STATIC_PINNAME_PREVIEW STATIC_PINNAME_VIDEO_PREVIEW
  2918. DEFINE_GUIDSTRUCT("FB6C4282-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_PREVIEW);
  2919. #define PINNAME_VIDEO_PREVIEW DEFINE_GUIDNAMED(PINNAME_VIDEO_PREVIEW)
  2920. #define PINNAME_PREVIEW PINNAME_VIDEO_PREVIEW
  2921. #define STATIC_PINNAME_VIDEO_ANALOGVIDEOIN \
  2922. 0xfb6c4283, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2923. DEFINE_GUIDSTRUCT("FB6C4283-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_ANALOGVIDEOIN);
  2924. #define PINNAME_VIDEO_ANALOGVIDEOIN DEFINE_GUIDNAMED(PINNAME_VIDEO_ANALOGVIDEOIN)
  2925. #define STATIC_PINNAME_VIDEO_VBI \
  2926. 0xfb6c4284, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2927. DEFINE_GUIDSTRUCT("FB6C4284-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_VBI);
  2928. #define PINNAME_VIDEO_VBI DEFINE_GUIDNAMED(PINNAME_VIDEO_VBI)
  2929. #define STATIC_PINNAME_VIDEO_VIDEOPORT \
  2930. 0xfb6c4285, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2931. DEFINE_GUIDSTRUCT("FB6C4285-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_VIDEOPORT);
  2932. #define PINNAME_VIDEO_VIDEOPORT DEFINE_GUIDNAMED(PINNAME_VIDEO_VIDEOPORT)
  2933. #define STATIC_PINNAME_VIDEO_NABTS \
  2934. 0xfb6c4286, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2935. DEFINE_GUIDSTRUCT("FB6C4286-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_NABTS);
  2936. #define PINNAME_VIDEO_NABTS DEFINE_GUIDNAMED(PINNAME_VIDEO_NABTS)
  2937. #define STATIC_PINNAME_VIDEO_EDS \
  2938. 0xfb6c4287, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2939. DEFINE_GUIDSTRUCT("FB6C4287-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_EDS);
  2940. #define PINNAME_VIDEO_EDS DEFINE_GUIDNAMED(PINNAME_VIDEO_EDS)
  2941. #define STATIC_PINNAME_VIDEO_TELETEXT \
  2942. 0xfb6c4288, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2943. DEFINE_GUIDSTRUCT("FB6C4288-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_TELETEXT);
  2944. #define PINNAME_VIDEO_TELETEXT DEFINE_GUIDNAMED(PINNAME_VIDEO_TELETEXT)
  2945. #define STATIC_PINNAME_VIDEO_CC \
  2946. 0xfb6c4289, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2947. DEFINE_GUIDSTRUCT("FB6C4289-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_CC);
  2948. #define PINNAME_VIDEO_CC DEFINE_GUIDNAMED(PINNAME_VIDEO_CC)
  2949. #define STATIC_PINNAME_VIDEO_STILL \
  2950. 0xfb6c428A, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2951. DEFINE_GUIDSTRUCT("FB6C428A-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_STILL);
  2952. #define PINNAME_VIDEO_STILL DEFINE_GUIDNAMED(PINNAME_VIDEO_STILL)
  2953. #define STATIC_PINNAME_VIDEO_TIMECODE \
  2954. 0xfb6c428B, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2955. DEFINE_GUIDSTRUCT("FB6C428B-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_TIMECODE);
  2956. #define PINNAME_VIDEO_TIMECODE DEFINE_GUIDNAMED(PINNAME_VIDEO_TIMECODE)
  2957. #define STATIC_PINNAME_VIDEO_VIDEOPORT_VBI \
  2958. 0xfb6c428C, 0x353, 0x11d1, 0x90, 0x5f, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  2959. DEFINE_GUIDSTRUCT("FB6C428C-0353-11d1-905F-0000C0CC16BA", PINNAME_VIDEO_VIDEOPORT_VBI);
  2960. #define PINNAME_VIDEO_VIDEOPORT_VBI DEFINE_GUIDNAMED(PINNAME_VIDEO_VIDEOPORT_VBI)
  2961. //===========================================================================
  2962. // KSSTREAM_HEADER extensions for digital video
  2963. //===========================================================================
  2964. #define KS_VIDEO_FLAG_FRAME 0x0000L // Frame or Field (default is frame)
  2965. #define KS_VIDEO_FLAG_FIELD1 0x0001L
  2966. #define KS_VIDEO_FLAG_FIELD2 0x0002L
  2967. #define KS_VIDEO_FLAG_I_FRAME 0x0000L // I, B, or P (default is I)
  2968. #define KS_VIDEO_FLAG_P_FRAME 0x0010L
  2969. #define KS_VIDEO_FLAG_B_FRAME 0x0020L
  2970. typedef struct tagKS_FRAME_INFO {
  2971. ULONG ExtendedHeaderSize; // Size of this extended header
  2972. DWORD dwFrameFlags; // Field1, Field2, or Frame
  2973. LONGLONG PictureNumber;
  2974. LONGLONG DropCount;
  2975. // The following are only set when using OverlayMixer
  2976. HANDLE hDirectDraw; // user mode DDraw handle
  2977. HANDLE hSurfaceHandle; // user mode surface handle
  2978. RECT DirectDrawRect; // portion of surface locked
  2979. // Reserved fields, never reference these
  2980. DWORD Reserved1;
  2981. DWORD Reserved2;
  2982. DWORD Reserved3;
  2983. DWORD Reserved4;
  2984. } KS_FRAME_INFO, *PKS_FRAME_INFO;
  2985. //===========================================================================
  2986. // KSSTREAM_HEADER extensions for VBI
  2987. //===========================================================================
  2988. #define KS_VBI_FLAG_FIELD1 0x0001L
  2989. #define KS_VBI_FLAG_FIELD2 0x0002L
  2990. #define KS_VBI_FLAG_MV_PRESENT 0x0100L
  2991. #define KS_VBI_FLAG_MV_HARDWARE 0x0200L
  2992. #define KS_VBI_FLAG_MV_DETECTED 0x0400L
  2993. #define KS_VBI_FLAG_TVTUNER_CHANGE 0x0010L // TvTunerChangeInfo is valid
  2994. #define KS_VBI_FLAG_VBIINFOHEADER_CHANGE 0x0020L // VBIInfoHeader is valid
  2995. typedef struct tagKS_VBI_FRAME_INFO {
  2996. ULONG ExtendedHeaderSize; // Size of this extended header
  2997. DWORD dwFrameFlags; // Field1, Field2, or Frame; & etc
  2998. LONGLONG PictureNumber; // Test only?
  2999. LONGLONG DropCount; // Test only?
  3000. DWORD dwSamplingFrequency;
  3001. KS_TVTUNER_CHANGE_INFO TvTunerChangeInfo;
  3002. KS_VBIINFOHEADER VBIInfoHeader;
  3003. } KS_VBI_FRAME_INFO, *PKS_VBI_FRAME_INFO;
  3004. //===========================================================================
  3005. // Analog video formats, used with:
  3006. // Analog Video Decoders
  3007. // TVTuners
  3008. // Analog Video Encoders
  3009. //
  3010. // XXX_STANDARDS_SUPPORTED returns a bitmask
  3011. //===========================================================================
  3012. typedef enum
  3013. {
  3014. KS_AnalogVideo_None = 0x00000000, // This is a digital sensor
  3015. KS_AnalogVideo_NTSC_M = 0x00000001, // 75 IRE Setup
  3016. KS_AnalogVideo_NTSC_M_J = 0x00000002, // Japan, 0 IRE Setup
  3017. KS_AnalogVideo_NTSC_433 = 0x00000004,
  3018. KS_AnalogVideo_PAL_B = 0x00000010,
  3019. KS_AnalogVideo_PAL_D = 0x00000020,
  3020. KS_AnalogVideo_PAL_G = 0x00000040,
  3021. KS_AnalogVideo_PAL_H = 0x00000080,
  3022. KS_AnalogVideo_PAL_I = 0x00000100,
  3023. KS_AnalogVideo_PAL_M = 0x00000200,
  3024. KS_AnalogVideo_PAL_N = 0x00000400,
  3025. KS_AnalogVideo_PAL_60 = 0x00000800,
  3026. KS_AnalogVideo_SECAM_B = 0x00001000,
  3027. KS_AnalogVideo_SECAM_D = 0x00002000,
  3028. KS_AnalogVideo_SECAM_G = 0x00004000,
  3029. KS_AnalogVideo_SECAM_H = 0x00008000,
  3030. KS_AnalogVideo_SECAM_K = 0x00010000,
  3031. KS_AnalogVideo_SECAM_K1 = 0x00020000,
  3032. KS_AnalogVideo_SECAM_L = 0x00040000,
  3033. KS_AnalogVideo_SECAM_L1 = 0x00080000,
  3034. KS_AnalogVideo_PAL_N_COMBO
  3035. = 0x00100000
  3036. } KS_AnalogVideoStandard;
  3037. #define KS_AnalogVideo_NTSC_Mask 0x00000007
  3038. #define KS_AnalogVideo_PAL_Mask 0x00100FF0
  3039. #define KS_AnalogVideo_SECAM_Mask 0x000FF000
  3040. //===========================================================================
  3041. // Property set definitions
  3042. // The comments show whether a given property is:
  3043. // R : READ only
  3044. // w : WRITE only
  3045. // RW : READ / WRITE
  3046. // O : Optional (return E_UNSUPPORTED if you don't handle this)
  3047. //===========================================================================
  3048. #define STATIC_PROPSETID_ALLOCATOR_CONTROL\
  3049. 0x53171960, 0x148e, 0x11d2, 0x99, 0x79, 0x0, 0x0, 0xc0, 0xcc, 0x16, 0xba
  3050. DEFINE_GUIDSTRUCT("53171960-148E-11d2-9979-0000C0CC16BA", PROPSETID_ALLOCATOR_CONTROL);
  3051. #define PROPSETID_ALLOCATOR_CONTROL DEFINE_GUIDNAMED(PROPSETID_ALLOCATOR_CONTROL)
  3052. typedef enum {
  3053. KSPROPERTY_ALLOCATOR_CONTROL_HONOR_COUNT, // R O (will allocate exactly this number of buffers)
  3054. KSPROPERTY_ALLOCATOR_CONTROL_SURFACE_SIZE, // R O (return 2 DWORDs specifying surface size)
  3055. // W I (informn a capture driver whether interleave capture is possible or
  3056. // not - a value of 1 means that interleaved capture is supported)
  3057. KSPROPERTY_ALLOCATOR_CONTROL_CAPTURE_CAPS,
  3058. // R O (if value == 1, then the ovmixer will turn on the DDVP_INTERLEAVE
  3059. // flag thus allowing interleaved capture of the video)
  3060. KSPROPERTY_ALLOCATOR_CONTROL_CAPTURE_INTERLEAVE,
  3061. } KSPROPERTY_ALLOCATOR_CONTROL;
  3062. typedef struct {
  3063. //KSPROPERTY Property;
  3064. ULONG CX;
  3065. ULONG CY;
  3066. } KSPROPERTY_ALLOCATOR_CONTROL_SURFACE_SIZE_S, *PKSPROPERTY_ALLOCATOR_CONTROL_SURFACE_SIZE_S;
  3067. typedef struct {
  3068. //KSPROPERTY Property;
  3069. ULONG InterleavedCapSupported;
  3070. } KSPROPERTY_ALLOCATOR_CONTROL_CAPTURE_CAPS_S, *PKSPROPERTY_ALLOCATOR_CONTROL_CAPTURE_CAPS_S;
  3071. typedef struct {
  3072. //KSPROPERTY Property;
  3073. ULONG InterleavedCapPossible;
  3074. } KSPROPERTY_ALLOCATOR_CONTROL_CAPTURE_INTERLEAVE_S, *PKSPROPERTY_ALLOCATOR_CONTROL_CAPTURE_INTERLEAVE_S;
  3075. //===========================================================================
  3076. #define STATIC_PROPSETID_VIDCAP_VIDEOPROCAMP\
  3077. 0xC6E13360L, 0x30AC, 0x11d0, 0xa1, 0x8c, 0x00, 0xA0, 0xC9, 0x11, 0x89, 0x56
  3078. DEFINE_GUIDSTRUCT("C6E13360-30AC-11d0-A18C-00A0C9118956", PROPSETID_VIDCAP_VIDEOPROCAMP);
  3079. #define PROPSETID_VIDCAP_VIDEOPROCAMP DEFINE_GUIDNAMED(PROPSETID_VIDCAP_VIDEOPROCAMP)
  3080. typedef enum {
  3081. KSPROPERTY_VIDEOPROCAMP_BRIGHTNESS, // RW O
  3082. KSPROPERTY_VIDEOPROCAMP_CONTRAST, // RW O
  3083. KSPROPERTY_VIDEOPROCAMP_HUE, // RW O
  3084. KSPROPERTY_VIDEOPROCAMP_SATURATION, // RW O
  3085. KSPROPERTY_VIDEOPROCAMP_SHARPNESS, // RW O
  3086. KSPROPERTY_VIDEOPROCAMP_GAMMA, // RW O
  3087. KSPROPERTY_VIDEOPROCAMP_COLORENABLE, // RW O
  3088. KSPROPERTY_VIDEOPROCAMP_WHITEBALANCE, // RW O
  3089. KSPROPERTY_VIDEOPROCAMP_BACKLIGHT_COMPENSATION,// RW O
  3090. KSPROPERTY_VIDEOPROCAMP_GAIN, // RW O
  3091. KSPROPERTY_VIDEOPROCAMP_DIGITAL_MULTIPLIER, // RW O
  3092. KSPROPERTY_VIDEOPROCAMP_DIGITAL_MULTIPLIER_LIMIT,// RW O
  3093. KSPROPERTY_VIDEOPROCAMP_WHITEBALANCE_COMPONENT, // RW O
  3094. KSPROPERTY_VIDEOPROCAMP_POWERLINE_FREQUENCY // RW O
  3095. } KSPROPERTY_VIDCAP_VIDEOPROCAMP;
  3096. typedef struct {
  3097. KSPROPERTY Property;
  3098. LONG Value; // Value to set or get
  3099. ULONG Flags; // KSPROPERTY_VIDEOPROCAMP_FLAGS_*
  3100. ULONG Capabilities; // KSPROPERTY_VIDEOPROCAMP_FLAGS_*
  3101. } KSPROPERTY_VIDEOPROCAMP_S, *PKSPROPERTY_VIDEOPROCAMP_S;
  3102. typedef struct {
  3103. KSP_NODE NodeProperty;
  3104. LONG Value; // Value to set or get
  3105. ULONG Flags; // KSPROPERTY_VIDEOPROCAMP_FLAGS_*
  3106. ULONG Capabilities; // KSPROPERTY_VIDEOPROCAMP_FLAGS_*
  3107. } KSPROPERTY_VIDEOPROCAMP_NODE_S, *PKSPROPERTY_VIDEOPROCAMP_NODE_S;
  3108. typedef struct {
  3109. KSPROPERTY Property;
  3110. LONG Value1;
  3111. ULONG Flags;
  3112. ULONG Capabilities;
  3113. LONG Value2;
  3114. } KSPROPERTY_VIDEOPROCAMP_S2, *PKSPROPERTY_VIDEOPROCAMP_S2;
  3115. typedef struct {
  3116. KSP_NODE NodeProperty;
  3117. LONG Value1;
  3118. ULONG Flags;
  3119. ULONG Capabilities;
  3120. LONG Value2;
  3121. } KSPROPERTY_VIDEOPROCAMP_NODE_S2, *PKSPROPERTY_VIDEOPROCAMP_NODE_S2;
  3122. #define KSPROPERTY_VIDEOPROCAMP_FLAGS_AUTO 0X0001L
  3123. #define KSPROPERTY_VIDEOPROCAMP_FLAGS_MANUAL 0X0002L
  3124. //===========================================================================
  3125. #define STATIC_PROPSETID_VIDCAP_SELECTOR \
  3126. 0x1ABDAECA, 0x68B6, 0x4F83, 0x93, 0x71, 0xB4, 0x13, 0x90, 0x7C, 0x7B, 0x9F
  3127. DEFINE_GUIDSTRUCT("1ABDAECA-68B6-4F83-9371-B413907C7B9F", PROPSETID_VIDCAP_SELECTOR);
  3128. #define PROPSETID_VIDCAP_SELECTOR DEFINE_GUIDNAMED(PROPSETID_VIDCAP_SELECTOR)
  3129. typedef enum {
  3130. KSPROPERTY_SELECTOR_SOURCE_NODE_ID, // RW
  3131. KSPROPERTY_SELECTOR_NUM_SOURCES // R
  3132. } KSPROPERTY_VIDCAP_SELECTOR, *PKSPROPERTY_VIDCAP_SELECTOR;
  3133. typedef struct {
  3134. KSPROPERTY Property;
  3135. LONG Value; // Value to set or get
  3136. ULONG Flags;
  3137. ULONG Capabilities;
  3138. } KSPROPERTY_SELECTOR_S, *PKSPROPERTY_SELECTOR_S;
  3139. typedef struct {
  3140. KSP_NODE NodeProperty;
  3141. LONG Value; // Value to set or get
  3142. ULONG Flags;
  3143. ULONG Capabilities;
  3144. } KSPROPERTY_SELECTOR_NODE_S, *PKSPROPERTY_SELECTOR_NODE_S;
  3145. //===========================================================================
  3146. #define STATIC_PROPSETID_TUNER\
  3147. 0x6a2e0605L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3148. DEFINE_GUIDSTRUCT("6a2e0605-28e4-11d0-a18c-00a0c9118956", PROPSETID_TUNER);
  3149. #define PROPSETID_TUNER DEFINE_GUIDNAMED(PROPSETID_TUNER)
  3150. typedef enum {
  3151. KSPROPERTY_TUNER_CAPS, // R -overall device capabilities
  3152. KSPROPERTY_TUNER_MODE_CAPS, // R -capabilities in this mode
  3153. KSPROPERTY_TUNER_MODE, // RW -set a mode (TV, FM, AM, DSS)
  3154. KSPROPERTY_TUNER_STANDARD, // R -get TV standard (only if TV mode)
  3155. KSPROPERTY_TUNER_FREQUENCY, // RW -set/get frequency
  3156. KSPROPERTY_TUNER_INPUT, // RW -select an input
  3157. KSPROPERTY_TUNER_STATUS, // R -tuning status
  3158. KSPROPERTY_TUNER_IF_MEDIUM // R O-Medium for IF or Transport Pin
  3159. } KSPROPERTY_TUNER;
  3160. typedef enum {
  3161. KSPROPERTY_TUNER_MODE_TV = 0X0001,
  3162. KSPROPERTY_TUNER_MODE_FM_RADIO = 0X0002,
  3163. KSPROPERTY_TUNER_MODE_AM_RADIO = 0X0004,
  3164. KSPROPERTY_TUNER_MODE_DSS = 0X0008,
  3165. KSPROPERTY_TUNER_MODE_ATSC = 0X0010, // also used for DVB-T, DVB-C
  3166. } KSPROPERTY_TUNER_MODES;
  3167. // Describes how the device tunes. Only one of these flags may be set
  3168. // in KSPROPERTY_TUNER_MODE_CAPS_S.Strategy
  3169. // Describe how the driver should attempt to tune:
  3170. // EXACT: just go to the frequency specified (no fine tuning)
  3171. // FINE: (slow) do an exhaustive search for the best signal
  3172. // COARSE: (fast) use larger frequency jumps to just determine if any signal
  3173. typedef enum {
  3174. KS_TUNER_TUNING_EXACT = 1, // No fine tuning
  3175. KS_TUNER_TUNING_FINE, // Fine grained search
  3176. KS_TUNER_TUNING_COARSE, // Coarse search
  3177. }KS_TUNER_TUNING_FLAGS;
  3178. typedef enum {
  3179. KS_TUNER_STRATEGY_PLL = 0X01, // Tune by PLL offset
  3180. KS_TUNER_STRATEGY_SIGNAL_STRENGTH = 0X02, // Tune by signal strength
  3181. KS_TUNER_STRATEGY_DRIVER_TUNES = 0X04, // Driver does fine tuning
  3182. }KS_TUNER_STRATEGY;
  3183. typedef struct {
  3184. KSPROPERTY Property;
  3185. ULONG ModesSupported; // KS_PROPERTY_TUNER_MODES_*
  3186. KSPIN_MEDIUM VideoMedium; // GUID_NULL (no pin), or GUID
  3187. KSPIN_MEDIUM TVAudioMedium; // GUID_NULL (no pin), or GUID
  3188. KSPIN_MEDIUM RadioAudioMedium; // GUID_NULL (no pin), or GUID
  3189. } KSPROPERTY_TUNER_CAPS_S, *PKSPROPERTY_TUNER_CAPS_S;
  3190. typedef struct {
  3191. KSPROPERTY Property;
  3192. KSPIN_MEDIUM IFMedium; // GUID_NULL (no pin), or GUID
  3193. } KSPROPERTY_TUNER_IF_MEDIUM_S, *PKSPROPERTY_TUNER_IF_MEDIUM_S;
  3194. typedef struct {
  3195. KSPROPERTY Property;
  3196. ULONG Mode; // IN: KSPROPERTY_TUNER_MODE
  3197. ULONG StandardsSupported; // KS_AnalogVideo_* (if TV or DSS)
  3198. ULONG MinFrequency; // Hz
  3199. ULONG MaxFrequency; // Hz
  3200. ULONG TuningGranularity; // Hz
  3201. ULONG NumberOfInputs; // count of inputs
  3202. ULONG SettlingTime; // milliSeconds
  3203. ULONG Strategy; // KS_TUNER_STRATEGY
  3204. } KSPROPERTY_TUNER_MODE_CAPS_S, *PKSPROPERTY_TUNER_MODE_CAPS_S;
  3205. typedef struct {
  3206. KSPROPERTY Property;
  3207. ULONG Mode; // IN: KSPROPERTY_TUNER_MODE
  3208. } KSPROPERTY_TUNER_MODE_S, *PKSPROPERTY_TUNER_MODE_S;
  3209. typedef struct {
  3210. KSPROPERTY Property;
  3211. ULONG Frequency; // Hz
  3212. ULONG LastFrequency; // Hz (last known good)
  3213. ULONG TuningFlags; // KS_TUNER_TUNING_FLAGS
  3214. ULONG VideoSubChannel; // DSS
  3215. ULONG AudioSubChannel; // DSS
  3216. ULONG Channel; // VBI decoders
  3217. ULONG Country; // VBI decoders
  3218. } KSPROPERTY_TUNER_FREQUENCY_S, *PKSPROPERTY_TUNER_FREQUENCY_S;
  3219. typedef struct {
  3220. KSPROPERTY Property;
  3221. ULONG Standard; // KS_AnalogVideo_*
  3222. } KSPROPERTY_TUNER_STANDARD_S, *PKSPROPERTY_TUNER_STANDARD_S;
  3223. typedef struct {
  3224. KSPROPERTY Property;
  3225. ULONG InputIndex; // 0 to (n-1) inputs
  3226. } KSPROPERTY_TUNER_INPUT_S, *PKSPROPERTY_TUNER_INPUT_S;
  3227. typedef struct {
  3228. KSPROPERTY Property;
  3229. ULONG CurrentFrequency; // Hz
  3230. ULONG PLLOffset; // if Strategy.KS_TUNER_STRATEGY_PLL
  3231. ULONG SignalStrength; // if Stretegy.KS_TUNER_STRATEGY_SIGNAL_STRENGTH
  3232. ULONG Busy; // TRUE if in the process of tuning
  3233. } KSPROPERTY_TUNER_STATUS_S, *PKSPROPERTY_TUNER_STATUS_S;
  3234. #define STATIC_EVENTSETID_TUNER\
  3235. 0x6a2e0606L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3236. DEFINE_GUIDSTRUCT("6a2e0606-28e4-11d0-a18c-00a0c9118956", EVENTSETID_TUNER);
  3237. #define EVENTSETID_TUNER DEFINE_GUIDNAMED(EVENTSETID_TUNER)
  3238. typedef enum {
  3239. KSEVENT_TUNER_CHANGED
  3240. } KSEVENT_TUNER;
  3241. //===========================================================================
  3242. // USB Video Class Definitions
  3243. #define STATIC_KSNODETYPE_VIDEO_STREAMING \
  3244. 0xDFF229E1L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3245. DEFINE_GUIDSTRUCT("DFF229E1-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_STREAMING);
  3246. #define KSNODETYPE_VIDEO_STREAMING DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_STREAMING)
  3247. #define STATIC_KSNODETYPE_VIDEO_INPUT_TERMINAL \
  3248. 0xDFF229E2L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3249. DEFINE_GUIDSTRUCT("DFF229E2-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_INPUT_TERMINAL);
  3250. #define KSNODETYPE_VIDEO_INPUT_TERMINAL DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_INPUT_TERMINAL)
  3251. #define STATIC_KSNODETYPE_VIDEO_OUTPUT_TERMINAL \
  3252. 0xDFF229E3L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3253. DEFINE_GUIDSTRUCT("DFF229E3-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_OUTPUT_TERMINAL);
  3254. #define KSNODETYPE_VIDEO_OUTPUT_TERMINAL DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_OUTPUT_TERMINAL)
  3255. #define STATIC_KSNODETYPE_VIDEO_SELECTOR \
  3256. 0xDFF229E4L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3257. DEFINE_GUIDSTRUCT("DFF229E4-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_SELECTOR);
  3258. #define KSNODETYPE_VIDEO_SELECTOR DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_SELECTOR)
  3259. #define STATIC_KSNODETYPE_VIDEO_PROCESSING \
  3260. 0xDFF229E5L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3261. DEFINE_GUIDSTRUCT("DFF229E5-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_PROCESSING);
  3262. #define KSNODETYPE_VIDEO_PROCESSING DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_PROCESSING)
  3263. #define STATIC_KSNODETYPE_VIDEO_CAMERA_TERMINAL \
  3264. 0xDFF229E6L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3265. DEFINE_GUIDSTRUCT("DFF229E6-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_CAMERA_TERMINAL);
  3266. #define KSNODETYPE_VIDEO_CAMERA_TERMINAL DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_CAMERA_TERMINAL)
  3267. #define STATIC_KSNODETYPE_VIDEO_INPUT_MTT \
  3268. 0xDFF229E7L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3269. DEFINE_GUIDSTRUCT("DFF229E7-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_INPUT_MTT);
  3270. #define KSNODETYPE_VIDEO_INPUT_MTT DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_INPUT_MTT)
  3271. #define STATIC_KSNODETYPE_VIDEO_OUTPUT_MTT \
  3272. 0xDFF229E8L, 0xF70F, 0x11D0, 0xB9, 0x17, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3273. DEFINE_GUIDSTRUCT("DFF229E8-F70F-11D0-B917-00A0C9223196", KSNODETYPE_VIDEO_OUTPUT_MTT);
  3274. #define KSNODETYPE_VIDEO_OUTPUT_MTT DEFINE_GUIDNAMED(KSNODETYPE_VIDEO_OUTPUT_MTT)
  3275. //===========================================================================
  3276. #define STATIC_PROPSETID_VIDCAP_VIDEOENCODER\
  3277. 0x6a2e0610L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3278. DEFINE_GUIDSTRUCT("6a2e0610-28e4-11d0-a18c-00a0c9118956", PROPSETID_VIDCAP_VIDEOENCODER);
  3279. #define PROPSETID_VIDCAP_VIDEOENCODER DEFINE_GUIDNAMED(PROPSETID_VIDCAP_VIDEOENCODER)
  3280. typedef enum {
  3281. KSPROPERTY_VIDEOENCODER_CAPS, // R
  3282. KSPROPERTY_VIDEOENCODER_STANDARD, // RW
  3283. KSPROPERTY_VIDEOENCODER_COPYPROTECTION, // RW O
  3284. KSPROPERTY_VIDEOENCODER_CC_ENABLE, // RW O
  3285. } KSPROPERTY_VIDCAP_VIDEOENCODER;
  3286. typedef struct {
  3287. KSPROPERTY Property;
  3288. LONG Value; // value to get or set
  3289. ULONG Flags; //
  3290. ULONG Capabilities; //
  3291. } KSPROPERTY_VIDEOENCODER_S, *PKSPROPERTY_VIDEOENCODER_S;
  3292. //===========================================================================
  3293. #define STATIC_PROPSETID_VIDCAP_VIDEODECODER\
  3294. 0xC6E13350L, 0x30AC, 0x11d0, 0xA1, 0x8C, 0x00, 0xA0, 0xC9, 0x11, 0x89, 0x56
  3295. DEFINE_GUIDSTRUCT("C6E13350-30AC-11d0-A18C-00A0C9118956", PROPSETID_VIDCAP_VIDEODECODER);
  3296. #define PROPSETID_VIDCAP_VIDEODECODER DEFINE_GUIDNAMED(PROPSETID_VIDCAP_VIDEODECODER)
  3297. typedef enum {
  3298. KSPROPERTY_VIDEODECODER_CAPS, // R
  3299. KSPROPERTY_VIDEODECODER_STANDARD, // RW
  3300. KSPROPERTY_VIDEODECODER_STATUS, // R
  3301. KSPROPERTY_VIDEODECODER_OUTPUT_ENABLE, // Rw O
  3302. KSPROPERTY_VIDEODECODER_VCR_TIMING, // RW O
  3303. } KSPROPERTY_VIDCAP_VIDEODECODER;
  3304. typedef enum {
  3305. KS_VIDEODECODER_FLAGS_CAN_DISABLE_OUTPUT = 0X0001, // VP Output can tri-stae
  3306. KS_VIDEODECODER_FLAGS_CAN_USE_VCR_LOCKING = 0X0002, // VCR PLL timings
  3307. KS_VIDEODECODER_FLAGS_CAN_INDICATE_LOCKED = 0X0004, // Can indicate valid signal
  3308. }KS_VIDEODECODER_FLAGS;
  3309. typedef struct {
  3310. KSPROPERTY Property;
  3311. ULONG StandardsSupported; // KS_AnalogVideo_*
  3312. ULONG Capabilities; // KS_VIDEODECODER_FLAGS_*
  3313. ULONG SettlingTime; // milliseconds
  3314. ULONG HSyncPerVSync; // Number of HSync Pulses per VSync
  3315. } KSPROPERTY_VIDEODECODER_CAPS_S, *PKSPROPERTY_VIDEODECODER_CAPS_S;
  3316. typedef struct {
  3317. KSPROPERTY Property;
  3318. ULONG NumberOfLines; // 525 or 625 lines detected
  3319. ULONG SignalLocked; // TRUE if signal is locked
  3320. } KSPROPERTY_VIDEODECODER_STATUS_S, *PKSPROPERTY_VIDEODECODER_STATUS_S;
  3321. typedef struct {
  3322. KSPROPERTY Property;
  3323. ULONG Value; // Get or set a value
  3324. } KSPROPERTY_VIDEODECODER_S, *PKSPROPERTY_VIDEODECODER_S;
  3325. #define STATIC_EVENTSETID_VIDEODECODER\
  3326. 0x6a2e0621L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3327. DEFINE_GUIDSTRUCT("6a2e0621-28e4-11d0-a18c-00a0c9118956", EVENTSETID_VIDEODECODER);
  3328. #define EVENTSETID_VIDEODECODER DEFINE_GUIDNAMED(EVENTSETID_VIDEODECODER)
  3329. typedef enum {
  3330. KSEVENT_VIDEODECODER_CHANGED
  3331. } KSEVENT_VIDEODECODER;
  3332. //===========================================================================
  3333. #define STATIC_PROPSETID_VIDCAP_CAMERACONTROL\
  3334. 0xC6E13370L, 0x30AC, 0x11d0, 0xa1, 0x8C, 0x00, 0xA0, 0xC9, 0x11, 0x89, 0x56
  3335. DEFINE_GUIDSTRUCT("C6E13370-30AC-11d0-A18C-00A0C9118956", PROPSETID_VIDCAP_CAMERACONTROL);
  3336. #define PROPSETID_VIDCAP_CAMERACONTROL DEFINE_GUIDNAMED(PROPSETID_VIDCAP_CAMERACONTROL)
  3337. typedef enum {
  3338. KSPROPERTY_CAMERACONTROL_PAN, // RW O
  3339. KSPROPERTY_CAMERACONTROL_TILT, // RW O
  3340. KSPROPERTY_CAMERACONTROL_ROLL, // RW O
  3341. KSPROPERTY_CAMERACONTROL_ZOOM, // RW O
  3342. KSPROPERTY_CAMERACONTROL_EXPOSURE, // RW O
  3343. KSPROPERTY_CAMERACONTROL_IRIS, // RW O
  3344. KSPROPERTY_CAMERACONTROL_FOCUS, // RW O
  3345. KSPROPERTY_CAMERACONTROL_SCANMODE, // RW O
  3346. KSPROPERTY_CAMERACONTROL_PRIVACY, // RW O
  3347. KSPROPERTY_CAMERACONTROL_PANTILT, // RW O
  3348. KSPROPERTY_CAMERACONTROL_PAN_RELATIVE, // RW O
  3349. KSPROPERTY_CAMERACONTROL_TILT_RELATIVE, // RW O
  3350. KSPROPERTY_CAMERACONTROL_ROLL_RELATIVE, // RW O
  3351. KSPROPERTY_CAMERACONTROL_ZOOM_RELATIVE, // RW O
  3352. KSPROPERTY_CAMERACONTROL_EXPOSURE_RELATIVE, // RW O
  3353. KSPROPERTY_CAMERACONTROL_IRIS_RELATIVE, // RW O
  3354. KSPROPERTY_CAMERACONTROL_FOCUS_RELATIVE, // RW O
  3355. KSPROPERTY_CAMERACONTROL_PANTILT_RELATIVE, // RW O
  3356. KSPROPERTY_CAMERACONTROL_FOCAL_LENGTH // R O
  3357. } KSPROPERTY_VIDCAP_CAMERACONTROL;
  3358. typedef struct {
  3359. KSPROPERTY Property;
  3360. LONG Value; // value to get or set
  3361. ULONG Flags; // KSPROPERTY_CAMERACONTROL_FLAGS_*
  3362. ULONG Capabilities; // KSPROPERTY_CAMERACONTROL_FLAGS_*
  3363. } KSPROPERTY_CAMERACONTROL_S, *PKSPROPERTY_CAMERACONTROL_S;
  3364. typedef struct {
  3365. KSP_NODE NodeProperty;
  3366. LONG Value; // value to get or set
  3367. ULONG Flags; // KSPROPERTY_CAMERACONTROL_FLAGS_*
  3368. ULONG Capabilities; // KSPROPERTY_CAMERACONTROL_FLAGS_*
  3369. } KSPROPERTY_CAMERACONTROL_NODE_S, PKSPROPERTY_CAMERACONTROL_NODE_S;
  3370. typedef struct {
  3371. KSPROPERTY Property;
  3372. LONG Value1;
  3373. ULONG Flags;
  3374. ULONG Capabilities;
  3375. LONG Value2;
  3376. } KSPROPERTY_CAMERACONTROL_S2, *PKSPROPERTY_CAMERACONTROL_S2;
  3377. typedef struct {
  3378. KSP_NODE NodeProperty;
  3379. LONG Value1;
  3380. ULONG Flags;
  3381. ULONG Capabilities;
  3382. LONG Value2;
  3383. } KSPROPERTY_CAMERACONTROL_NODE_S2, *PKSPROPERTY_CAMERACONTROL_NODE_S2;
  3384. typedef struct {
  3385. KSPROPERTY Property;
  3386. LONG lOcularFocalLength;
  3387. LONG lObjectiveFocalLengthMin;
  3388. LONG lObjectiveFocalLengthMax;
  3389. } KSPROPERTY_CAMERACONTROL_FOCAL_LENGTH_S, *PKSPROPERTY_CAMERACONTROL_FOCAL_LENGTH_S;
  3390. typedef struct {
  3391. KSNODEPROPERTY NodeProperty;
  3392. LONG lOcularFocalLength;
  3393. LONG lObjectiveFocalLengthMin;
  3394. LONG lObjectiveFocalLengthMax;
  3395. } KSPROPERTY_CAMERACONTROL_NODE_FOCAL_LENGTH_S, *PKSPROPERTY_CAMERACONTROL_NODE_FOCAL_LENGTH_S;
  3396. #define KSPROPERTY_CAMERACONTROL_FLAGS_AUTO 0X0001L
  3397. #define KSPROPERTY_CAMERACONTROL_FLAGS_MANUAL 0X0002L
  3398. #define KSPROPERTY_CAMERACONTROL_FLAGS_ABSOLUTE 0X0000L
  3399. #define KSPROPERTY_CAMERACONTROL_FLAGS_RELATIVE 0X0010L
  3400. #ifndef __EDevCtrl__
  3401. #define __EDevCtrl__
  3402. //===========================================================================
  3403. #define STATIC_PROPSETID_EXT_DEVICE\
  3404. 0xB5730A90L, 0x1A2C, 0x11cf, 0x8c, 0x23, 0x00, 0xAA, 0x00, 0x6B, 0x68, 0x14
  3405. DEFINE_GUIDSTRUCT("B5730A90-1A2C-11cf-8C23-00AA006B6814", PROPSETID_EXT_DEVICE);
  3406. #define PROPSETID_EXT_DEVICE DEFINE_GUIDNAMED(PROPSETID_EXT_DEVICE)
  3407. typedef enum {
  3408. KSPROPERTY_EXTDEVICE_ID, // R
  3409. KSPROPERTY_EXTDEVICE_VERSION, // R
  3410. KSPROPERTY_EXTDEVICE_POWER_STATE, // RW
  3411. KSPROPERTY_EXTDEVICE_PORT, // R
  3412. KSPROPERTY_EXTDEVICE_CAPABILITIES, // R
  3413. } KSPROPERTY_EXTDEVICE;
  3414. typedef struct tagDEVCAPS{
  3415. LONG CanRecord;
  3416. LONG CanRecordStrobe;
  3417. LONG HasAudio;
  3418. LONG HasVideo;
  3419. LONG UsesFiles;
  3420. LONG CanSave;
  3421. LONG DeviceType;
  3422. LONG TCRead;
  3423. LONG TCWrite;
  3424. LONG CTLRead;
  3425. LONG IndexRead;
  3426. LONG Preroll;
  3427. LONG Postroll;
  3428. LONG SyncAcc;
  3429. LONG NormRate;
  3430. LONG CanPreview;
  3431. LONG CanMonitorSrc;
  3432. LONG CanTest;
  3433. LONG VideoIn;
  3434. LONG AudioIn;
  3435. LONG Calibrate;
  3436. LONG SeekType;
  3437. LONG SimulatedHardware;
  3438. } DEVCAPS, *PDEVCAPS;
  3439. typedef struct {
  3440. KSPROPERTY Property;
  3441. union {
  3442. DEVCAPS Capabilities; // Device capabilities
  3443. ULONG DevPort; // 1394, USB, etc.
  3444. ULONG PowerState; // On, standby or off
  3445. WCHAR pawchString[MAX_PATH]; // Version
  3446. DWORD NodeUniqueID[2]; // Unique NodeID
  3447. } u;
  3448. } KSPROPERTY_EXTDEVICE_S, *PKSPROPERTY_EXTDEVICE_S;
  3449. //===========================================================================
  3450. #define STATIC_PROPSETID_EXT_TRANSPORT\
  3451. 0xA03CD5F0L, 0x3045, 0x11cf, 0x8c, 0x44, 0x00, 0xAA, 0x00, 0x6B, 0x68, 0x14
  3452. DEFINE_GUIDSTRUCT("A03CD5F0-3045-11cf-8C44-00AA006B6814", PROPSETID_EXT_TRANSPORT);
  3453. #define PROPSETID_EXT_TRANSPORT DEFINE_GUIDNAMED(PROPSETID_EXT_TRANSPORT)
  3454. typedef enum {
  3455. KSPROPERTY_EXTXPORT_CAPABILITIES, // (R) Transport specific capability
  3456. KSPROPERTY_EXTXPORT_INPUT_SIGNAL_MODE, // (RW) Input signal: e.g. dvsd/NTSC/PAL, dvsl/NTSC/PAL, MPEG2-TS etc
  3457. KSPROPERTY_EXTXPORT_OUTPUT_SIGNAL_MODE, // (RW) Output signal: e.g. dvsd/NTSC/PAL, dvsl/NTSC/PAL, MPEG2-TS etc
  3458. KSPROPERTY_EXTXPORT_LOAD_MEDIUM, // (RW) Eject, open tray, close tray
  3459. KSPROPERTY_EXTXPORT_MEDIUM_INFO, // (R) Cassettte type, tape grade and write protection
  3460. KSPROPERTY_EXTXPORT_STATE, // (RW) Current transport mode and state
  3461. KSPROPERTY_EXTXPORT_STATE_NOTIFY, // (RW) Notify of transport mode and state change
  3462. KSPROPERTY_EXTXPORT_TIMECODE_SEARCH, // (W) Search to a specific timecode on a tape
  3463. KSPROPERTY_EXTXPORT_ATN_SEARCH, // (W) Search to a specific absolute track number (ATN) on a tape
  3464. KSPROPERTY_EXTXPORT_RTC_SEARCH, // (W) Search to a specific relative time counter (RTC) on a tape
  3465. KSPROPERTY_RAW_AVC_CMD, // (RW) Issue a raw AVC commnad
  3466. } KSPROPERTY_EXTXPORT;
  3467. typedef struct tagTRANSPORTSTATUS{
  3468. LONG Mode;
  3469. LONG LastError;
  3470. LONG RecordInhibit;
  3471. LONG ServoLock;
  3472. LONG MediaPresent;
  3473. LONG MediaLength;
  3474. LONG MediaSize;
  3475. LONG MediaTrackCount;
  3476. LONG MediaTrackLength;
  3477. LONG MediaTrackSide;
  3478. LONG MediaType;
  3479. LONG LinkMode;
  3480. LONG NotifyOn;
  3481. } TRANSPORTSTATUS, *PTRANSPORTSTATUS;
  3482. typedef struct tagTRANSPORTBASICPARMS{
  3483. LONG TimeFormat;
  3484. LONG TimeReference;
  3485. LONG Superimpose;
  3486. LONG EndStopAction;
  3487. LONG RecordFormat;
  3488. LONG StepFrames;
  3489. LONG SetpField;
  3490. LONG Preroll;
  3491. LONG RecPreroll;
  3492. LONG Postroll;
  3493. LONG EditDelay;
  3494. LONG PlayTCDelay;
  3495. LONG RecTCDelay;
  3496. LONG EditField;
  3497. LONG FrameServo;
  3498. LONG ColorFrameServo;
  3499. LONG ServoRef;
  3500. LONG WarnGenlock;
  3501. LONG SetTracking;
  3502. TCHAR VolumeName[40];
  3503. LONG Ballistic[20];
  3504. LONG Speed;
  3505. LONG CounterFormat;
  3506. LONG TunerChannel;
  3507. LONG TunerNumber;
  3508. LONG TimerEvent;
  3509. LONG TimerStartDay;
  3510. LONG TimerStartTime;
  3511. LONG TimerStopDay;
  3512. LONG TimerStopTime;
  3513. } TRANSPORTBASICPARMS, *PTRANSPORTBASICPARMS;
  3514. typedef struct tagTRANSPORTVIDEOPARMS{
  3515. LONG OutputMode;
  3516. LONG Input;
  3517. } TRANSPORTVIDEOPARMS, *PTRANSPORTVIDEOPARMS;
  3518. typedef struct tagTRANSPORTAUDIOPARMS{
  3519. LONG EnableOutput;
  3520. LONG EnableRecord;
  3521. LONG EnableSelsync;
  3522. LONG Input;
  3523. LONG MonitorSource;
  3524. } TRANSPORTAUDIOPARMS, *PTRANSPORTAUDIOPARMS;
  3525. typedef struct {
  3526. BOOL MediaPresent;
  3527. ULONG MediaType;
  3528. BOOL RecordInhibit;
  3529. } MEDIUM_INFO, *PMEDIUM_INFO;
  3530. typedef struct {
  3531. ULONG Mode;
  3532. ULONG State;
  3533. } TRANSPORT_STATE, *PTRANSPORT_STATE;
  3534. typedef struct {
  3535. KSPROPERTY Property;
  3536. union {
  3537. ULONG Capabilities;
  3538. ULONG SignalMode;
  3539. ULONG LoadMedium;
  3540. MEDIUM_INFO MediumInfo;
  3541. TRANSPORT_STATE XPrtState;
  3542. struct {
  3543. BYTE frame;
  3544. BYTE second;
  3545. BYTE minute;
  3546. BYTE hour;
  3547. } Timecode;
  3548. DWORD dwTimecode;
  3549. DWORD dwAbsTrackNumber;
  3550. struct {
  3551. ULONG PayloadSize;
  3552. BYTE Payload[512];
  3553. } RawAVC;
  3554. } u;
  3555. } KSPROPERTY_EXTXPORT_S, *PKSPROPERTY_EXTXPORT_S;
  3556. typedef struct {
  3557. KSP_NODE NodeProperty;
  3558. union {
  3559. ULONG Capabilities;
  3560. ULONG SignalMode;
  3561. ULONG LoadMedium;
  3562. MEDIUM_INFO MediumInfo;
  3563. TRANSPORT_STATE XPrtState;
  3564. struct {
  3565. BYTE frame;
  3566. BYTE second;
  3567. BYTE minute;
  3568. BYTE hour;
  3569. } Timecode;
  3570. DWORD dwTimecode;
  3571. DWORD dwAbsTrackNumber;
  3572. struct {
  3573. ULONG PayloadSize;
  3574. BYTE Payload[512];
  3575. } RawAVC;
  3576. } u;
  3577. } KSPROPERTY_EXTXPORT_NODE_S, *PKSPROPERTY_EXTXPORT_NODE_S;
  3578. //===========================================================================
  3579. #define STATIC_PROPSETID_TIMECODE_READER\
  3580. 0x9B496CE1L, 0x811B, 0x11cf, 0x8C, 0x77, 0x00, 0xAA, 0x00, 0x6B, 0x68, 0x14
  3581. DEFINE_GUIDSTRUCT("9B496CE1-811B-11cf-8C77-00AA006B6814", PROPSETID_TIMECODE_READER);
  3582. #define PROPSETID_TIMECODE_READER DEFINE_GUIDNAMED(PROPSETID_TIMECODE_READER)
  3583. typedef enum {
  3584. KSPROPERTY_TIMECODE_READER, // (R) Timecode for the current tape position
  3585. KSPROPERTY_ATN_READER, // (R) Absolute track number for the current tape position
  3586. KSPROPERTY_RTC_READER, // (R) Relative time counter for the current tape position
  3587. } KSPROPERTY_TIMECODE;
  3588. #ifndef TIMECODE_DEFINED
  3589. #define TIMECODE_DEFINED
  3590. typedef union _timecode {
  3591. struct {
  3592. WORD wFrameRate;
  3593. WORD wFrameFract;
  3594. DWORD dwFrames;
  3595. };
  3596. DWORDLONG qw;
  3597. } TIMECODE;
  3598. typedef TIMECODE *PTIMECODE;
  3599. typedef struct tagTIMECODE_SAMPLE {
  3600. LONGLONG qwTick;
  3601. TIMECODE timecode;
  3602. DWORD dwUser;
  3603. DWORD dwFlags;
  3604. } TIMECODE_SAMPLE;
  3605. typedef TIMECODE_SAMPLE *PTIMECODE_SAMPLE;
  3606. #endif /* TIMECODE_DEFINED */
  3607. typedef struct {
  3608. KSPROPERTY Property;
  3609. TIMECODE_SAMPLE TimecodeSamp;
  3610. } KSPROPERTY_TIMECODE_S, *PKSPROPERTY_TIMECODE_S;
  3611. typedef struct {
  3612. KSP_NODE NodeProperty;
  3613. TIMECODE_SAMPLE TimecodeSamp;
  3614. } KSPROPERTY_TIMECODE_NODE_S, *PKSPROPERTY_TIMECODE_NODE_S;
  3615. //===========================================================================
  3616. #define STATIC_KSEVENTSETID_EXTDEV_Command\
  3617. 0x109c7988L, 0xb3cb, 0x11d2, 0xb4, 0x8e, 0x00, 0x60, 0x97, 0xb3, 0x39, 0x1b
  3618. DEFINE_GUIDSTRUCT("109c7988-b3cb-11d2-b48e-006097b3391b", KSEVENTSETID_EXTDEV_Command);
  3619. #define KSEVENTSETID_EXTDEV_Command DEFINE_GUIDNAMED(KSEVENTSETID_EXTDEV_Command)
  3620. typedef enum {
  3621. KSEVENT_EXTDEV_COMMAND_NOTIFY_INTERIM_READY, // Final response is ready for notify command
  3622. KSEVENT_EXTDEV_COMMAND_CONTROL_INTERIM_READY, // Final response is ready for control command.
  3623. KSEVENT_EXTDEV_COMMAND_BUSRESET, // A bus reset has occured.
  3624. KSEVENT_EXTDEV_TIMECODE_UPDATE, // Timecode has changed.
  3625. KSEVENT_EXTDEV_OPERATION_MODE_UPDATE, // Operting mode (VCR,Camera, etc.) has changed.
  3626. KSEVENT_EXTDEV_TRANSPORT_STATE_UPDATE, // Transport state has changed.
  3627. KSEVENT_EXTDEV_NOTIFY_REMOVAL, // Device was surprise removal.
  3628. KSEVENT_EXTDEV_NOTIFY_MEDIUM_CHANGE, // Tape medium is removed or added.
  3629. } KSEVENT_DEVCMD;
  3630. #endif // __EDevCtrl__
  3631. //===========================================================================
  3632. #define STATIC_PROPSETID_VIDCAP_CROSSBAR\
  3633. 0x6a2e0640L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3634. DEFINE_GUIDSTRUCT("6a2e0640-28e4-11d0-a18c-00a0c9118956", PROPSETID_VIDCAP_CROSSBAR);
  3635. #define PROPSETID_VIDCAP_CROSSBAR DEFINE_GUIDNAMED(PROPSETID_VIDCAP_CROSSBAR)
  3636. typedef enum {
  3637. KSPROPERTY_CROSSBAR_CAPS, // R
  3638. KSPROPERTY_CROSSBAR_PININFO, // R
  3639. KSPROPERTY_CROSSBAR_CAN_ROUTE, // R
  3640. KSPROPERTY_CROSSBAR_ROUTE, // RW
  3641. } KSPROPERTY_VIDCAP_CROSSBAR;
  3642. typedef struct {
  3643. KSPROPERTY Property;
  3644. ULONG NumberOfInputs; // the number of audio and video input pins
  3645. ULONG NumberOfOutputs; // the number of audio and video output pins
  3646. } KSPROPERTY_CROSSBAR_CAPS_S, *PKSPROPERTY_CROSSBAR_CAPS_S;
  3647. typedef struct {
  3648. KSPROPERTY Property;
  3649. KSPIN_DATAFLOW Direction; // KSPIN_DATAFLOW_IN or KSPIN_DATAFLOW_OUT?
  3650. ULONG Index; // Which pin to return data for?
  3651. ULONG PinType; // KS_PhysConn_Video_* or KS_PhysConn_Audio_*
  3652. ULONG RelatedPinIndex; // For video pins, this is the related audio pin
  3653. KSPIN_MEDIUM Medium; // Identifies the hardware connection
  3654. } KSPROPERTY_CROSSBAR_PININFO_S, *PKSPROPERTY_CROSSBAR_PININFO_S;
  3655. typedef struct {
  3656. KSPROPERTY Property;
  3657. ULONG IndexInputPin; // Zero based index of the input pin
  3658. ULONG IndexOutputPin; // Zero based index of the output pin
  3659. ULONG CanRoute; // returns non-zero on CAN_ROUTE if routing is possible
  3660. } KSPROPERTY_CROSSBAR_ROUTE_S, *PKSPROPERTY_CROSSBAR_ROUTE_S;
  3661. #define STATIC_EVENTSETID_CROSSBAR\
  3662. 0x6a2e0641L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3663. DEFINE_GUIDSTRUCT("6a2e0641-28e4-11d0-a18c-00a0c9118956", EVENTSETID_CROSSBAR);
  3664. #define EVENTSETID_CROSSBAR DEFINE_GUIDNAMED(EVENTSETID_CROSSBAR)
  3665. typedef enum {
  3666. KSEVENT_CROSSBAR_CHANGED
  3667. } KSEVENT_CROSSBAR;
  3668. // The following IDs should match the AM equivalents
  3669. typedef enum {
  3670. KS_PhysConn_Video_Tuner = 1,
  3671. KS_PhysConn_Video_Composite,
  3672. KS_PhysConn_Video_SVideo,
  3673. KS_PhysConn_Video_RGB,
  3674. KS_PhysConn_Video_YRYBY,
  3675. KS_PhysConn_Video_SerialDigital,
  3676. KS_PhysConn_Video_ParallelDigital,
  3677. KS_PhysConn_Video_SCSI,
  3678. KS_PhysConn_Video_AUX,
  3679. KS_PhysConn_Video_1394,
  3680. KS_PhysConn_Video_USB,
  3681. KS_PhysConn_Video_VideoDecoder,
  3682. KS_PhysConn_Video_VideoEncoder,
  3683. KS_PhysConn_Video_SCART,
  3684. KS_PhysConn_Audio_Tuner = 4096,
  3685. KS_PhysConn_Audio_Line,
  3686. KS_PhysConn_Audio_Mic,
  3687. KS_PhysConn_Audio_AESDigital,
  3688. KS_PhysConn_Audio_SPDIFDigital,
  3689. KS_PhysConn_Audio_SCSI,
  3690. KS_PhysConn_Audio_AUX,
  3691. KS_PhysConn_Audio_1394,
  3692. KS_PhysConn_Audio_USB,
  3693. KS_PhysConn_Audio_AudioDecoder,
  3694. } KS_PhysicalConnectorType;
  3695. //===========================================================================
  3696. #define STATIC_PROPSETID_VIDCAP_TVAUDIO\
  3697. 0x6a2e0650L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3698. DEFINE_GUIDSTRUCT("6a2e0650-28e4-11d0-a18c-00a0c9118956", PROPSETID_VIDCAP_TVAUDIO);
  3699. #define PROPSETID_VIDCAP_TVAUDIO DEFINE_GUIDNAMED(PROPSETID_VIDCAP_TVAUDIO)
  3700. typedef enum {
  3701. KSPROPERTY_TVAUDIO_CAPS, // R
  3702. KSPROPERTY_TVAUDIO_MODE, // RW
  3703. KSPROPERTY_TVAUDIO_CURRENTLY_AVAILABLE_MODES // R
  3704. } KSPROPERTY_VIDCAP_TVAUDIO;
  3705. #define KS_TVAUDIO_MODE_MONO 0x0001 // Mono
  3706. #define KS_TVAUDIO_MODE_STEREO 0x0002 // Stereo
  3707. #define KS_TVAUDIO_MODE_LANG_A 0x0010 // Primary language
  3708. #define KS_TVAUDIO_MODE_LANG_B 0x0020 // 2nd avail language
  3709. #define KS_TVAUDIO_MODE_LANG_C 0x0040 // 3rd avail language
  3710. typedef struct {
  3711. KSPROPERTY Property;
  3712. ULONG Capabilities; // Bitmask of KS_TVAUDIO_MODE_*
  3713. KSPIN_MEDIUM InputMedium;
  3714. KSPIN_MEDIUM OutputMedium;
  3715. } KSPROPERTY_TVAUDIO_CAPS_S, *PKSPROPERTY_TVAUDIO_CAPS_S;
  3716. typedef struct {
  3717. KSPROPERTY Property;
  3718. ULONG Mode; // KS_TVAUDIO_MODE_*
  3719. } KSPROPERTY_TVAUDIO_S, *PKSPROPERTY_TVAUDIO_S;
  3720. #define STATIC_KSEVENTSETID_VIDCAP_TVAUDIO\
  3721. 0x6a2e0651L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3722. DEFINE_GUIDSTRUCT("6a2e0651-28e4-11d0-a18c-00a0c9118956", KSEVENTSETID_VIDCAP_TVAUDIO);
  3723. #define KSEVENTSETID_VIDCAP_TVAUDIO DEFINE_GUIDNAMED(KSEVENTSETID_VIDCAP_TVAUDIO)
  3724. typedef enum {
  3725. KSEVENT_TVAUDIO_CHANGED,
  3726. } KSEVENT_TVAUDIO;
  3727. //===========================================================================
  3728. #define STATIC_PROPSETID_VIDCAP_VIDEOCOMPRESSION\
  3729. 0xC6E13343L, 0x30AC, 0x11d0, 0xA1, 0x8C, 0x00, 0xA0, 0xC9, 0x11, 0x89, 0x56
  3730. DEFINE_GUIDSTRUCT("C6E13343-30AC-11d0-A18C-00A0C9118956", PROPSETID_VIDCAP_VIDEOCOMPRESSION);
  3731. #define PROPSETID_VIDCAP_VIDEOCOMPRESSION DEFINE_GUIDNAMED(PROPSETID_VIDCAP_VIDEOCOMPRESSION)
  3732. typedef enum {
  3733. KSPROPERTY_VIDEOCOMPRESSION_GETINFO, // R
  3734. KSPROPERTY_VIDEOCOMPRESSION_KEYFRAME_RATE, // RW
  3735. KSPROPERTY_VIDEOCOMPRESSION_PFRAMES_PER_KEYFRAME, // RW
  3736. KSPROPERTY_VIDEOCOMPRESSION_QUALITY, // RW
  3737. KSPROPERTY_VIDEOCOMPRESSION_OVERRIDE_KEYFRAME, // W
  3738. KSPROPERTY_VIDEOCOMPRESSION_OVERRIDE_FRAME_SIZE, // W
  3739. KSPROPERTY_VIDEOCOMPRESSION_WINDOWSIZE, // RW
  3740. } KSPROPERTY_VIDCAP_VIDEOCOMPRESSION;
  3741. typedef enum {
  3742. KS_CompressionCaps_CanQuality = 1,
  3743. KS_CompressionCaps_CanCrunch = 2,
  3744. KS_CompressionCaps_CanKeyFrame = 4,
  3745. KS_CompressionCaps_CanBFrame = 8,
  3746. KS_CompressionCaps_CanWindow = 0x10,
  3747. } KS_CompressionCaps;
  3748. typedef struct {
  3749. KSPROPERTY Property;
  3750. // Note, no VersionString!
  3751. // Note, no DescriptionString!
  3752. ULONG StreamIndex; // zero based index of stream
  3753. LONG DefaultKeyFrameRate; // Key frame rate
  3754. LONG DefaultPFrameRate; // Predeicted frames per Key frame
  3755. LONG DefaultQuality; // 0 to 10000
  3756. LONG NumberOfQualitySettings; // How many discreet quality settings?
  3757. LONG Capabilities; // KS_CompressionCaps_*
  3758. } KSPROPERTY_VIDEOCOMPRESSION_GETINFO_S, *PKSPROPERTY_VIDEOCOMPRESSION_GETINFO_S;
  3759. typedef struct {
  3760. KSPROPERTY Property;
  3761. ULONG StreamIndex; // zero based index of stream
  3762. LONG Value; // value to get or set
  3763. } KSPROPERTY_VIDEOCOMPRESSION_S, *PKSPROPERTY_VIDEOCOMPRESSION_S;
  3764. //===========================================================================
  3765. // MEDIASUBTYPE_Overlay
  3766. #define STATIC_KSDATAFORMAT_SUBTYPE_OVERLAY\
  3767. 0xe436eb7fL, 0x524f, 0x11ce, 0x9f, 0x53, 0x00, 0x20, 0xaf, 0x0b, 0xa7, 0x70
  3768. DEFINE_GUIDSTRUCT("e436eb7f-524f-11ce-9f53-0020af0ba770", KSDATAFORMAT_SUBTYPE_OVERLAY);
  3769. #define KSDATAFORMAT_SUBTYPE_OVERLAY DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_OVERLAY)
  3770. #define STATIC_KSPROPSETID_OverlayUpdate\
  3771. 0x490EA5CFL, 0x7681, 0x11D1, 0xA2, 0x1C, 0x00, 0xA0, 0xC9, 0x22, 0x31, 0x96
  3772. DEFINE_GUIDSTRUCT("490EA5CF-7681-11D1-A21C-00A0C9223196", KSPROPSETID_OverlayUpdate);
  3773. #define KSPROPSETID_OverlayUpdate DEFINE_GUIDNAMED(KSPROPSETID_OverlayUpdate)
  3774. typedef enum {
  3775. KSPROPERTY_OVERLAYUPDATE_INTERESTS,
  3776. KSPROPERTY_OVERLAYUPDATE_CLIPLIST = 0x1,
  3777. KSPROPERTY_OVERLAYUPDATE_PALETTE = 0x2,
  3778. KSPROPERTY_OVERLAYUPDATE_COLORKEY = 0x4,
  3779. KSPROPERTY_OVERLAYUPDATE_VIDEOPOSITION = 0x8,
  3780. KSPROPERTY_OVERLAYUPDATE_DISPLAYCHANGE = 0x10,
  3781. KSPROPERTY_OVERLAYUPDATE_COLORREF = 0x10000000
  3782. } KSPROPERTY_OVERLAYUPDATE;
  3783. typedef struct {
  3784. ULONG PelsWidth;
  3785. ULONG PelsHeight;
  3786. ULONG BitsPerPel;
  3787. WCHAR DeviceID[1];
  3788. } KSDISPLAYCHANGE, *PKSDISPLAYCHANGE;
  3789. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_INTERESTS(Handler)\
  3790. DEFINE_KSPROPERTY_ITEM(\
  3791. KSPROPERTY_OVERLAYUPDATE_INTERESTS,\
  3792. (Handler),\
  3793. sizeof(KSPROPERTY),\
  3794. sizeof(ULONG),\
  3795. NULL, NULL, 0, NULL, NULL, 0)
  3796. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_PALETTE(Handler)\
  3797. DEFINE_KSPROPERTY_ITEM(\
  3798. KSPROPERTY_OVERLAYUPDATE_PALETTE,\
  3799. NULL,\
  3800. sizeof(KSPROPERTY),\
  3801. 0,\
  3802. (Handler),\
  3803. NULL, 0, NULL, NULL, 0)
  3804. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_COLORKEY(Handler)\
  3805. DEFINE_KSPROPERTY_ITEM(\
  3806. KSPROPERTY_OVERLAYUPDATE_COLORKEY,\
  3807. NULL,\
  3808. sizeof(KSPROPERTY),\
  3809. sizeof(COLORKEY),\
  3810. (Handler),\
  3811. NULL, 0, NULL, NULL, 0)
  3812. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_CLIPLIST(Handler)\
  3813. DEFINE_KSPROPERTY_ITEM(\
  3814. KSPROPERTY_OVERLAYUPDATE_CLIPLIST,\
  3815. NULL,\
  3816. sizeof(KSPROPERTY),\
  3817. 2 * sizeof(RECT) + sizeof(RGNDATAHEADER),\
  3818. (Handler),\
  3819. NULL, 0, NULL, NULL, 0)
  3820. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_VIDEOPOSITION(Handler)\
  3821. DEFINE_KSPROPERTY_ITEM(\
  3822. KSPROPERTY_OVERLAYUPDATE_VIDEOPOSITION,\
  3823. NULL,\
  3824. sizeof(KSPROPERTY),\
  3825. 2 * sizeof(RECT),\
  3826. (Handler),\
  3827. NULL, 0, NULL, NULL, 0)
  3828. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_DISPLAYCHANGE(Handler)\
  3829. DEFINE_KSPROPERTY_ITEM(\
  3830. KSPROPERTY_OVERLAYUPDATE_DISPLAYCHANGE,\
  3831. NULL,\
  3832. sizeof(KSPROPERTY),\
  3833. sizeof(KSDISPLAYCHANGE),\
  3834. (Handler),\
  3835. NULL, 0, NULL, NULL, 0)
  3836. #define DEFINE_KSPROPERTY_ITEM_OVERLAYUPDATE_COLORREF(Handler)\
  3837. DEFINE_KSPROPERTY_ITEM(\
  3838. KSPROPERTY_OVERLAYUPDATE_COLORREF,\
  3839. (Handler),\
  3840. sizeof(KSPROPERTY),\
  3841. sizeof(COLORREF),\
  3842. NULL,\
  3843. NULL, 0, NULL, NULL, 0)
  3844. //===========================================================================
  3845. #define STATIC_PROPSETID_VIDCAP_VIDEOCONTROL\
  3846. 0x6a2e0670L, 0x28e4, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3847. DEFINE_GUIDSTRUCT("6a2e0670-28e4-11d0-a18c-00a0c9118956", PROPSETID_VIDCAP_VIDEOCONTROL);
  3848. #define PROPSETID_VIDCAP_VIDEOCONTROL DEFINE_GUIDNAMED(PROPSETID_VIDCAP_VIDEOCONTROL)
  3849. typedef enum {
  3850. KSPROPERTY_VIDEOCONTROL_CAPS, // R
  3851. KSPROPERTY_VIDEOCONTROL_ACTUAL_FRAME_RATE, // R O
  3852. KSPROPERTY_VIDEOCONTROL_FRAME_RATES, // R O
  3853. KSPROPERTY_VIDEOCONTROL_MODE, // RWO
  3854. } KSPROPERTY_VIDCAP_VIDEOCONTROL;
  3855. typedef enum {
  3856. KS_VideoControlFlag_FlipHorizontal = 0x0001,
  3857. KS_VideoControlFlag_FlipVertical = 0x0002,
  3858. KS_Obsolete_VideoControlFlag_ExternalTriggerEnable = 0x0010, // ***WARNING *** Flag msimatch with DSHOW.
  3859. KS_Obsolete_VideoControlFlag_Trigger = 0x0020, // ***WARNING *** Flag msimatch with DSHOW.
  3860. KS_VideoControlFlag_ExternalTriggerEnable = 0x0004,
  3861. KS_VideoControlFlag_Trigger = 0x0008,
  3862. } KS_VideoControlFlags;
  3863. typedef struct {
  3864. KSPROPERTY Property;
  3865. ULONG StreamIndex;
  3866. ULONG VideoControlCaps; // KS_VideoControlFlags_*
  3867. } KSPROPERTY_VIDEOCONTROL_CAPS_S, *PKSPROPERTY_VIDEOCONTROL_CAPS_S;
  3868. typedef struct {
  3869. KSPROPERTY Property;
  3870. ULONG StreamIndex;
  3871. LONG Mode; // KS_VideoControlFlags_*
  3872. } KSPROPERTY_VIDEOCONTROL_MODE_S, *PKSPROPERTY_VIDEOCONTROL_MODE_S;
  3873. typedef struct {
  3874. KSPROPERTY Property;
  3875. ULONG StreamIndex; // Index of stream
  3876. ULONG RangeIndex; // Index of range
  3877. SIZE Dimensions; // Size of image
  3878. LONGLONG CurrentActualFrameRate; // Only correct if pin is open
  3879. LONGLONG CurrentMaxAvailableFrameRate; // Max Rate temporarily limited on USB or 1394?
  3880. } KSPROPERTY_VIDEOCONTROL_ACTUAL_FRAME_RATE_S, *PKSPROPERTY_VIDEOCONTROL_ACTUAL_FRAME_RATE_S;
  3881. // KSPROPERTY_VIDEOCONTROL_FRAME_RATES returns a list of available frame rates in 100 nS units
  3882. typedef struct {
  3883. KSPROPERTY Property;
  3884. ULONG StreamIndex; // Index of stream
  3885. ULONG RangeIndex; // Index of range
  3886. SIZE Dimensions; // Size of image
  3887. } KSPROPERTY_VIDEOCONTROL_FRAME_RATES_S, *PKSPROPERTY_VIDEOCONTROL_FRAME_RATES_S;
  3888. //===========================================================================
  3889. #define STATIC_PROPSETID_VIDCAP_DROPPEDFRAMES\
  3890. 0xC6E13344L, 0x30AC, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0xc9, 0x11, 0x89, 0x56
  3891. DEFINE_GUIDSTRUCT("C6E13344-30AC-11d0-A18C-00A0C9118956", PROPSETID_VIDCAP_DROPPEDFRAMES);
  3892. #define PROPSETID_VIDCAP_DROPPEDFRAMES DEFINE_GUIDNAMED(PROPSETID_VIDCAP_DROPPEDFRAMES)
  3893. typedef enum {
  3894. KSPROPERTY_DROPPEDFRAMES_CURRENT // R
  3895. } KSPROPERTY_VIDCAP_DROPPEDFRAMES;
  3896. typedef struct {
  3897. KSPROPERTY Property;
  3898. LONGLONG PictureNumber; // Current Picture Number
  3899. LONGLONG DropCount; // Count of frames dropped
  3900. ULONG AverageFrameSize; // Average size of frames captured
  3901. } KSPROPERTY_DROPPEDFRAMES_CURRENT_S, *PKSPROPERTY_DROPPEDFRAMES_CURRENT_S;
  3902. //===========================================================================
  3903. // VPE
  3904. #define STATIC_KSPROPSETID_VPConfig\
  3905. 0xbc29a660L, 0x30e3, 0x11d0, 0x9e, 0x69, 0x00, 0xc0, 0x4f, 0xd7, 0xc1, 0x5b
  3906. DEFINE_GUIDSTRUCT("bc29a660-30e3-11d0-9e69-00c04fd7c15b", KSPROPSETID_VPConfig);
  3907. #define KSPROPSETID_VPConfig DEFINE_GUIDNAMED(KSPROPSETID_VPConfig)
  3908. #define STATIC_KSPROPSETID_VPVBIConfig\
  3909. 0xec529b00L, 0x1a1f, 0x11d1, 0xba, 0xd9, 0x0, 0x60, 0x97, 0x44, 0x11, 0x1a
  3910. DEFINE_GUIDSTRUCT("ec529b00-1a1f-11d1-bad9-00609744111a", KSPROPSETID_VPVBIConfig);
  3911. #define KSPROPSETID_VPVBIConfig DEFINE_GUIDNAMED(KSPROPSETID_VPVBIConfig)
  3912. // Both of the above property sets use the same list of properties below
  3913. typedef enum {
  3914. KSPROPERTY_VPCONFIG_NUMCONNECTINFO,
  3915. KSPROPERTY_VPCONFIG_GETCONNECTINFO,
  3916. KSPROPERTY_VPCONFIG_SETCONNECTINFO,
  3917. KSPROPERTY_VPCONFIG_VPDATAINFO,
  3918. KSPROPERTY_VPCONFIG_MAXPIXELRATE,
  3919. KSPROPERTY_VPCONFIG_INFORMVPINPUT,
  3920. KSPROPERTY_VPCONFIG_NUMVIDEOFORMAT,
  3921. KSPROPERTY_VPCONFIG_GETVIDEOFORMAT,
  3922. KSPROPERTY_VPCONFIG_SETVIDEOFORMAT,
  3923. KSPROPERTY_VPCONFIG_INVERTPOLARITY,
  3924. KSPROPERTY_VPCONFIG_DECIMATIONCAPABILITY, // E_NOTIMPL for VBI
  3925. KSPROPERTY_VPCONFIG_SCALEFACTOR, // E_NOTIMPL for VBI
  3926. KSPROPERTY_VPCONFIG_DDRAWHANDLE,
  3927. KSPROPERTY_VPCONFIG_VIDEOPORTID,
  3928. KSPROPERTY_VPCONFIG_DDRAWSURFACEHANDLE,
  3929. KSPROPERTY_VPCONFIG_SURFACEPARAMS
  3930. } KSPROPERTY_VPCONFIG;
  3931. //=========================
  3932. // IBasicAudio
  3933. //
  3934. #define STATIC_CLSID_KsIBasicAudioInterfaceHandler\
  3935. 0xb9f8ac3e, 0x0f71, 0x11d2, 0xb7, 0x2c, 0x00, 0xc0, 0x4f, 0xb6, 0xbd, 0x3d
  3936. DEFINE_GUIDSTRUCT("b9f8ac3e-0f71-11d2-b72c-00c04fb6bd3d", CLSID_KsIBasicAudioInterfaceHandler);
  3937. #define CLSID_KsIBasicAudioInterfaceHandler DEFINE_GUIDNAMED(CLSID_KsIBasicAudioInterfaceHandler)
  3938. #if defined(__IVPType__)
  3939. typedef struct {
  3940. AMVPSIZE Size;
  3941. DWORD MaxPixelsPerSecond;
  3942. DWORD Reserved;
  3943. } KSVPMAXPIXELRATE, *PKSVPMAXPIXELRATE;
  3944. typedef struct {
  3945. KSPROPERTY Property;
  3946. AMVPSIZE Size;
  3947. } KSVPSIZE_PROP, *PKSVPSIZE_PROP;
  3948. typedef struct {
  3949. DWORD dwPitch;
  3950. DWORD dwXOrigin;
  3951. DWORD dwYOrigin;
  3952. } KSVPSURFACEPARAMS, *PKSVPSURFACEPARAMS;
  3953. #else // !defined(__IVPType__)
  3954. #if !defined(__DDRAW_INCLUDED__)
  3955. //==========================================================================
  3956. // The following definitions must be in sync with DDraw.h in DirectX SDK
  3957. //==========================================================================
  3958. /*
  3959. * The FourCC code is valid.
  3960. */
  3961. #define DDPF_FOURCC 0x00000004l
  3962. typedef struct _DDPIXELFORMAT
  3963. {
  3964. DWORD dwSize; // size of structure
  3965. DWORD dwFlags; // pixel format flags
  3966. DWORD dwFourCC; // (FOURCC code)
  3967. union
  3968. {
  3969. DWORD dwRGBBitCount; // how many bits per pixel (BD_1,2,4,8,16,24,32)
  3970. DWORD dwYUVBitCount; // how many bits per pixel (BD_4,8,16,24,32)
  3971. DWORD dwZBufferBitDepth; // how many bits for z buffers (BD_8,16,24,32)
  3972. DWORD dwAlphaBitDepth; // how many bits for alpha channels (BD_1,2,4,8)
  3973. };
  3974. union
  3975. {
  3976. DWORD dwRBitMask; // mask for red bit
  3977. DWORD dwYBitMask; // mask for Y bits
  3978. };
  3979. union
  3980. {
  3981. DWORD dwGBitMask; // mask for green bits
  3982. DWORD dwUBitMask; // mask for U bits
  3983. };
  3984. union
  3985. {
  3986. DWORD dwBBitMask; // mask for blue bits
  3987. DWORD dwVBitMask; // mask for V bits
  3988. };
  3989. union
  3990. {
  3991. DWORD dwRGBAlphaBitMask; // mask for alpha channel
  3992. DWORD dwYUVAlphaBitMask; // mask for alpha channel
  3993. DWORD dwRGBZBitMask; // mask for Z channel
  3994. DWORD dwYUVZBitMask; // mask for Z channel
  3995. };
  3996. } DDPIXELFORMAT, * LPDDPIXELFORMAT;
  3997. #endif // !defined(__DDRAW_INCLUDED__)
  3998. //==========================================================================
  3999. // End of DDraw.h header info
  4000. //==========================================================================
  4001. //==========================================================================
  4002. // The following definitions must be in sync with DVP.h in DirectX SDK
  4003. //==========================================================================
  4004. #if !defined(__DVP_INCLUDED__)
  4005. typedef struct _DDVIDEOPORTCONNECT {
  4006. DWORD dwSize; // size of the DDVIDEOPORTCONNECT structure
  4007. DWORD dwPortWidth; // Width of the video port
  4008. GUID guidTypeID; // Description of video port connection
  4009. DWORD dwFlags; // Connection flags
  4010. DWORD dwReserved1; // Reserved, set to zero.
  4011. } DDVIDEOPORTCONNECT, * LPDDVIDEOPORTCONNECT;
  4012. #define DDVPTYPE_E_HREFH_VREFH \
  4013. 0x54F39980L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8
  4014. #define DDVPTYPE_E_HREFL_VREFL \
  4015. 0xE09C77E0L,0xDA60,0x11CF,0x9B,0x06,0x00,0xA0,0xC9,0x03,0xA3,0xB8
  4016. #endif // !defined(__DVP_INCLUDED__)
  4017. //==========================================================================
  4018. // End of DVP.h header info
  4019. //==========================================================================
  4020. //==========================================================================
  4021. // The following definitions must be in sync with VPType.h in AM 2.0 SDK
  4022. //==========================================================================
  4023. // pixel aspect ratios corresponding to a 720x480 NTSC image or a 720x576 image
  4024. typedef enum // AMPixAspectRatio
  4025. {
  4026. KS_PixAspectRatio_NTSC4x3,
  4027. KS_PixAspectRatio_NTSC16x9,
  4028. KS_PixAspectRatio_PAL4x3,
  4029. KS_PixAspectRatio_PAL16x9,
  4030. } KS_AMPixAspectRatio ;
  4031. typedef enum // AMVP_SELECTFORMATBY
  4032. {
  4033. KS_AMVP_DO_NOT_CARE,
  4034. KS_AMVP_BEST_BANDWIDTH,
  4035. KS_AMVP_INPUT_SAME_AS_OUTPUT
  4036. } KS_AMVP_SELECTFORMATBY;
  4037. typedef enum // AMVP_MODE
  4038. {
  4039. KS_AMVP_MODE_WEAVE,
  4040. KS_AMVP_MODE_BOBINTERLEAVED,
  4041. KS_AMVP_MODE_BOBNONINTERLEAVED,
  4042. KS_AMVP_MODE_SKIPEVEN,
  4043. KS_AMVP_MODE_SKIPODD
  4044. } KS_AMVP_MODE ;
  4045. typedef struct tagKS_AMVPDIMINFO // AMVPDIMINFO
  4046. {
  4047. DWORD dwFieldWidth ; // [out] field width
  4048. DWORD dwFieldHeight ; // [out] field height
  4049. DWORD dwVBIWidth ; // [out] VBI data width
  4050. DWORD dwVBIHeight ; // [out] VBI data height
  4051. RECT rcValidRegion ; // [out] valid rect for data cropping
  4052. } KS_AMVPDIMINFO, *PKS_AMVPDIMINFO ;
  4053. typedef struct tagKS_AMVPDATAINFO // AMVPDATAINFO
  4054. {
  4055. DWORD dwSize; // Size of the struct
  4056. DWORD dwMicrosecondsPerField; // Time taken by each field
  4057. KS_AMVPDIMINFO amvpDimInfo; // Dimensional Information
  4058. DWORD dwPictAspectRatioX; // Pict aspect ratio in X dimn
  4059. DWORD dwPictAspectRatioY; // Pict aspect ratio in Y dimn
  4060. BOOL bEnableDoubleClock; // Videoport should enable double clocking
  4061. BOOL bEnableVACT; // Videoport should use an external VACT signal
  4062. BOOL bDataIsInterlaced; // Indicates that the signal is interlaced
  4063. LONG lHalfLinesOdd; // number of halflines in the odd field
  4064. BOOL bFieldPolarityInverted; // Device inverts the polarity by default
  4065. DWORD dwNumLinesInVREF; // Number of lines of data in VREF
  4066. LONG lHalfLinesEven; // number of halflines in the even field
  4067. DWORD dwReserved1; // Reserved for future use
  4068. } KS_AMVPDATAINFO, *PKS_AMVPDATAINFO;
  4069. typedef struct tagKS_AMVPSIZE // AMVPSIZE
  4070. {
  4071. DWORD dwWidth ; // [in] width in pixels
  4072. DWORD dwHeight ; // [in] height in pixels
  4073. } KS_AMVPSIZE, *PKS_AMVPSIZE ;
  4074. //==========================================================================
  4075. // End of VPType.h header info
  4076. //==========================================================================
  4077. typedef struct {
  4078. KS_AMVPSIZE Size;
  4079. DWORD MaxPixelsPerSecond;
  4080. DWORD Reserved;
  4081. } KSVPMAXPIXELRATE, *PKSVPMAXPIXELRATE;
  4082. typedef struct {
  4083. KSPROPERTY Property;
  4084. KS_AMVPSIZE Size;
  4085. } KSVPSIZE_PROP, *PKSVPSIZE_PROP;
  4086. typedef struct {
  4087. DWORD dwPitch;
  4088. DWORD dwXOrigin;
  4089. DWORD dwYOrigin;
  4090. } KSVPSURFACEPARAMS, *PKSVPSURFACEPARAMS;
  4091. #endif // !defined(__IVPType__)
  4092. //
  4093. // IVPNotify event notification
  4094. //
  4095. #define STATIC_KSEVENTSETID_VPNotify\
  4096. 0x20c5598eL, 0xd3c8, 0x11d0, 0x8d, 0xfc, 0x00, 0xc0, 0x4f, 0xd7, 0xc0, 0x8b
  4097. DEFINE_GUIDSTRUCT("20c5598e-d3c8-11d0-8dfc-00c04fd7c08b", KSEVENTSETID_VPNotify);
  4098. #define KSEVENTSETID_VPNotify DEFINE_GUIDNAMED(KSEVENTSETID_VPNotify)
  4099. typedef enum {
  4100. KSEVENT_VPNOTIFY_FORMATCHANGE,
  4101. } KSEVENT_VPNOTIFY;
  4102. //
  4103. // VIDCAPTOSTI event notification
  4104. //
  4105. #define STATIC_KSEVENTSETID_VIDCAPTOSTI\
  4106. 0xdb47de20, 0xf628, 0x11d1, 0xba, 0x41, 0x0, 0xa0, 0xc9, 0xd, 0x2b, 0x5
  4107. DEFINE_GUIDSTRUCT("DB47DE20-F628-11d1-BA41-00A0C90D2B05", KSEVENTSETID_VIDCAPTOSTI);
  4108. #define KSEVENTSETID_VIDCAPNotify DEFINE_GUIDNAMED(KSEVENTSETID_VIDCAPTOSTI)
  4109. typedef enum {
  4110. KSEVENT_VIDCAPTOSTI_EXT_TRIGGER,
  4111. KSEVENT_VIDCAP_AUTO_UPDATE,
  4112. KSEVENT_VIDCAP_SEARCH
  4113. } KSEVENT_VIDCAPTOSTI;
  4114. //
  4115. // Extension Unit Properties
  4116. //
  4117. typedef enum {
  4118. KSPROPERTY_EXTENSION_UNIT_INFO, // (R)
  4119. KSPROPERTY_EXTENSION_UNIT_CONTROL, // (RW)
  4120. KSPROPERTY_EXTENSION_UNIT_PASS_THROUGH = 0xffff, // (RW)
  4121. } KSPROPERTY_EXTENSION_UNIT, *PKSPROPERTY_EXTENSION_UNIT;
  4122. //
  4123. // IVPVBINotify event notification
  4124. //
  4125. #define STATIC_KSEVENTSETID_VPVBINotify\
  4126. 0xec529b01L, 0x1a1f, 0x11d1, 0xba, 0xd9, 0x0, 0x60, 0x97, 0x44, 0x11, 0x1a
  4127. DEFINE_GUIDSTRUCT("ec529b01-1a1f-11d1-bad9-00609744111a", KSEVENTSETID_VPVBINotify);
  4128. #define KSEVENTSETID_VPVBINotify DEFINE_GUIDNAMED(KSEVENTSETID_VPVBINotify)
  4129. typedef enum {
  4130. KSEVENT_VPVBINOTIFY_FORMATCHANGE,
  4131. } KSEVENT_VPVBINOTIFY;
  4132. //
  4133. // closed caption information
  4134. //
  4135. #define STATIC_KSDATAFORMAT_TYPE_AUXLine21Data \
  4136. 0x670aea80L, 0x3a82, 0x11d0, 0xb7, 0x9b, 0x00, 0xaa, 0x00, 0x37, 0x67, 0xa7
  4137. DEFINE_GUIDSTRUCT("670aea80-3a82-11d0-b79b-00aa003767a7", KSDATAFORMAT_TYPE_AUXLine21Data);
  4138. #define KSDATAFORMAT_TYPE_AUXLine21Data DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_AUXLine21Data)
  4139. #define STATIC_KSDATAFORMAT_SUBTYPE_Line21_BytePair \
  4140. 0x6e8d4a22L, 0x310c, 0x11d0, 0xb7, 0x9a, 0x00, 0xaa, 0x00, 0x37, 0x67, 0xa7
  4141. DEFINE_GUIDSTRUCT("6e8d4a22-310c-11d0-b79a-00aa003767a7", KSDATAFORMAT_SUBTYPE_Line21_BytePair);
  4142. #define KSDATAFORMAT_SUBTYPE_Line21_BytePair DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_Line21_BytePair)
  4143. #define STATIC_KSDATAFORMAT_SUBTYPE_Line21_GOPPacket \
  4144. 0x6e8d4a23L, 0x310c, 0x11d0, 0xb7, 0x9a, 0x00, 0xaa, 0x00, 0x37, 0x67, 0xa7
  4145. DEFINE_GUIDSTRUCT("6e8d4a23-310c-11d0-b79a-00aa003767a7", KSDATAFORMAT_SUBTYPE_Line21_GOPPacket);
  4146. #define KSDATAFORMAT_SUBTYPE_Line21_GOPPacket DEFINE_GUIDNAMED(KSDATAFORMAT_SUBTYPE_Line21_GOPPacket)
  4147. typedef struct _KSGOP_USERDATA {
  4148. ULONG sc;
  4149. ULONG reserved1;
  4150. BYTE cFields;
  4151. CHAR l21Data[3];
  4152. } KSGOP_USERDATA, *PKSGOP_USERDATA;
  4153. //
  4154. // DVD encrypted PACK format type definition
  4155. //
  4156. #define STATIC_KSDATAFORMAT_TYPE_DVD_ENCRYPTED_PACK\
  4157. 0xed0b916a, 0x044d, 0x11d1, 0xaa, 0x78, 0x00, 0xc0, 0x4f, 0xc3, 0x1d, 0x60
  4158. DEFINE_GUIDSTRUCT("ed0b916a-044d-11d1-aa78-00c04fc31d60", KSDATAFORMAT_TYPE_DVD_ENCRYPTED_PACK);
  4159. #define KSDATAFORMAT_TYPE_DVD_ENCRYPTED_PACK DEFINE_GUIDNAMED(KSDATAFORMAT_TYPE_DVD_ENCRYPTED_PACK)
  4160. #define KS_AM_UseNewCSSKey 0x1
  4161. // -----------------------------------------------------------------------
  4162. // KS_AM_KSPROPSETID_TSRateChange property set definitions for time stamp
  4163. // rate changes.
  4164. // -----------------------------------------------------------------------
  4165. #define STATIC_KSPROPSETID_TSRateChange\
  4166. 0xa503c5c0, 0x1d1d, 0x11d1, 0xad, 0x80, 0x44, 0x45, 0x53, 0x54, 0x0, 0x0
  4167. DEFINE_GUIDSTRUCT("A503C5C0-1D1D-11D1-AD80-444553540000", KSPROPSETID_TSRateChange);
  4168. #define KSPROPSETID_TSRateChange DEFINE_GUIDNAMED(KSPROPSETID_TSRateChange)
  4169. typedef enum {
  4170. KS_AM_RATE_SimpleRateChange=1, // rw, use KS_AM_SimpleRateChange
  4171. KS_AM_RATE_ExactRateChange=2, // rw, use KS_AM_ExactRateChange
  4172. KS_AM_RATE_MaxFullDataRate=3, // r, use KS_AM_MaxFullDataRate
  4173. KS_AM_RATE_Step=4 // w, use KS_AM_Step
  4174. } KS_AM_PROPERTY_TS_RATE_CHANGE;
  4175. typedef struct {
  4176. // this is the simplest mechanism to set a time stamp rate change on
  4177. // a filter (simplest for the person setting the rate change, harder
  4178. // for the filter doing the rate change).
  4179. REFERENCE_TIME StartTime; //stream time at which to start this rate
  4180. LONG Rate; //new rate * 10000 (decimal)
  4181. } KS_AM_SimpleRateChange, *PKS_AM_SimpleRateChange;
  4182. typedef struct {
  4183. REFERENCE_TIME OutputZeroTime; //input TS that maps to zero output TS
  4184. LONG Rate; //new rate * 10000 (decimal)
  4185. } KS_AM_ExactRateChange, *PKS_AM_ExactRateChange;
  4186. typedef LONG KS_AM_MaxFullDataRate; //rate * 10000 (decimal)
  4187. typedef DWORD KS_AM_Step; // number of frame to step
  4188. //===========================================================================
  4189. //ENCODER API DEFINITIONS
  4190. //===========================================================================
  4191. #define STATIC_KSCATEGORY_ENCODER \
  4192. 0x19689bf6, 0xc384, 0x48fd, 0xad, 0x51, 0x90, 0xe5, 0x8c, 0x79, 0xf7, 0xb
  4193. DEFINE_GUIDSTRUCT("19689BF6-C384-48fd-AD51-90E58C79F70B", KSCATEGORY_ENCODER);
  4194. #define KSCATEGORY_ENCODER DEFINE_GUIDNAMED(KSCATEGORY_ENCODER)
  4195. #define STATIC_KSCATEGORY_MULTIPLEXER \
  4196. 0x7a5de1d3, 0x1a1, 0x452c, 0xb4, 0x81, 0x4f, 0xa2, 0xb9, 0x62, 0x71, 0xe8
  4197. DEFINE_GUIDSTRUCT("7A5DE1D3-01A1-452c-B481-4FA2B96271E8", KSCATEGORY_MULTIPLEXER);
  4198. #define KSCATEGORY_MULTIPLEXER DEFINE_GUIDNAMED(KSCATEGORY_MULTIPLEXER)
  4199. #ifndef __ENCODER_API_GUIDS__
  4200. #define __ENCODER_API_GUIDS__
  4201. #define STATIC_ENCAPIPARAM_BITRATE \
  4202. 0x49cc4c43, 0xca83, 0x4ad4, 0xa9, 0xaf, 0xf3, 0x69, 0x6a, 0xf6, 0x66, 0xdf
  4203. DEFINE_GUIDSTRUCT("49CC4C43-CA83-4ad4-A9AF-F3696AF666DF", ENCAPIPARAM_BITRATE);
  4204. #define ENCAPIPARAM_BITRATE DEFINE_GUIDNAMED(ENCAPIPARAM_BITRATE)
  4205. #define STATIC_ENCAPIPARAM_PEAK_BITRATE \
  4206. 0x703f16a9, 0x3d48, 0x44a1, 0xb0, 0x77, 0x1, 0x8d, 0xff, 0x91, 0x5d, 0x19
  4207. DEFINE_GUIDSTRUCT("703F16A9-3D48-44a1-B077-018DFF915D19", ENCAPIPARAM_PEAK_BITRATE);
  4208. #define ENCAPIPARAM_PEAK_BITRATE DEFINE_GUIDNAMED(ENCAPIPARAM_PEAK_BITRATE)
  4209. #define STATIC_ENCAPIPARAM_BITRATE_MODE \
  4210. 0xee5fb25c, 0xc713, 0x40d1, 0x9d, 0x58, 0xc0, 0xd7, 0x24, 0x1e, 0x25, 0xf
  4211. DEFINE_GUIDSTRUCT("EE5FB25C-C713-40d1-9D58-C0D7241E250F", ENCAPIPARAM_BITRATE_MODE);
  4212. #define ENCAPIPARAM_BITRATE_MODE DEFINE_GUIDNAMED(ENCAPIPARAM_BITRATE_MODE)
  4213. #define STATIC_CODECAPI_CHANGELISTS \
  4214. 0x62b12acf, 0xf6b0, 0x47d9, 0x94, 0x56, 0x96, 0xf2, 0x2c, 0x4e, 0x0b, 0x9d
  4215. DEFINE_GUIDSTRUCT("62B12ACF-F6B0-47D9-9456-96F22C4E0B9D", CODECAPI_CHANGELISTS );
  4216. #define CODECAPI_CHANGELISTS DEFINE_GUIDNAMED(CODECAPI_CHANGELISTS )
  4217. #define STATIC_CODECAPI_VIDEO_ENCODER \
  4218. 0x7112e8e1, 0x3d03, 0x47ef, 0x8e, 0x60, 0x03, 0xf1, 0xcf, 0x53, 0x73, 0x01
  4219. DEFINE_GUIDSTRUCT("7112E8E1-3D03-47EF-8E60-03F1CF537301", CODECAPI_VIDEO_ENCODER );
  4220. #define CODECAPI_VIDEO_ENCODER DEFINE_GUIDNAMED(CODECAPI_VIDEO_ENCODER )
  4221. #define STATIC_CODECAPI_AUDIO_ENCODER \
  4222. 0xb9d19a3e, 0xf897, 0x429c, 0xbc, 0x46, 0x81, 0x38, 0xb7, 0x27, 0x2b, 0x2d
  4223. DEFINE_GUIDSTRUCT("B9D19A3E-F897-429C-BC46-8138B7272B2D", CODECAPI_AUDIO_ENCODER );
  4224. #define CODECAPI_AUDIO_ENCODER DEFINE_GUIDNAMED(CODECAPI_AUDIO_ENCODER )
  4225. #define STATIC_CODECAPI_SETALLDEFAULTS \
  4226. 0x6c5e6a7c, 0xacf8, 0x4f55, 0xa9, 0x99, 0x1a, 0x62, 0x81, 0x09, 0x05, 0x1b
  4227. DEFINE_GUIDSTRUCT("6C5E6A7C-ACF8-4F55-A999-1A628109051B", CODECAPI_SETALLDEFAULTS );
  4228. #define CODECAPI_SETALLDEFAULTS DEFINE_GUIDNAMED(CODECAPI_SETALLDEFAULTS )
  4229. #define STATIC_CODECAPI_ALLSETTINGS \
  4230. 0x6a577e92, 0x83e1, 0x4113, 0xad, 0xc2, 0x4f, 0xce, 0xc3, 0x2f, 0x83, 0xa1
  4231. DEFINE_GUIDSTRUCT("6A577E92-83E1-4113-ADC2-4FCEC32F83A1", CODECAPI_ALLSETTINGS );
  4232. #define CODECAPI_ALLSETTINGS DEFINE_GUIDNAMED(CODECAPI_ALLSETTINGS )
  4233. #define STATIC_CODECAPI_SUPPORTSEVENTS \
  4234. 0x0581af97, 0x7693, 0x4dbd, 0x9d, 0xca, 0x3f, 0x9e, 0xbd, 0x65, 0x85, 0xa1
  4235. DEFINE_GUIDSTRUCT("0581AF97-7693-4DBD-9DCA-3F9EBD6585A1", CODECAPI_SUPPORTSEVENTS );
  4236. #define CODECAPI_SUPPORTSEVENTS DEFINE_GUIDNAMED(CODECAPI_SUPPORTSEVENTS )
  4237. #define STATIC_CODECAPI_CURRENTCHANGELIST \
  4238. 0x1cb14e83, 0x7d72, 0x4657, 0x83, 0xfd, 0x47, 0xa2, 0xc5, 0xb9, 0xd1, 0x3d
  4239. DEFINE_GUIDSTRUCT("1CB14E83-7D72-4657-83FD-47A2C5B9D13D", CODECAPI_CURRENTCHANGELIST );
  4240. #define CODECAPI_CURRENTCHANGELIST DEFINE_GUIDNAMED(CODECAPI_CURRENTCHANGELIST )
  4241. #endif // __ENCODER_API_GUIDS__
  4242. #ifndef __ENCODER_API_DEFINES__
  4243. #define __ENCODER_API_DEFINES__
  4244. typedef enum {
  4245. //
  4246. // Bit rate used for encoding is constant
  4247. //
  4248. ConstantBitRate = 0,
  4249. //
  4250. // Bit rate used for encoding is variable with the specified bitrate used
  4251. // as a guaranteed average over a specified window. The default window
  4252. // size is considered to be 5 minutes.
  4253. //
  4254. VariableBitRateAverage,
  4255. //
  4256. // Bit rate used for encoding is variable with the specified bitrate used
  4257. // as an average with a peak not to exceed the specified peak bitrate over
  4258. // a specified window. The default window size is considered to be 500ms
  4259. // (classically one GOP).
  4260. //
  4261. VariableBitRatePeak
  4262. } VIDEOENCODER_BITRATE_MODE;
  4263. #endif // __ENCODER_API_DEFINES__
  4264. #endif // !defined(_KSMEDIA_)