dxva2api.h 66 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589
  1. /*** Autogenerated by WIDL 7.7 from include/dxva2api.idl - Do not edit ***/
  2. #ifdef _WIN32
  3. #ifndef __REQUIRED_RPCNDR_H_VERSION__
  4. #define __REQUIRED_RPCNDR_H_VERSION__ 475
  5. #endif
  6. #include <rpc.h>
  7. #include <rpcndr.h>
  8. #endif
  9. #ifndef COM_NO_WINDOWS_H
  10. #include <windows.h>
  11. #include <ole2.h>
  12. #endif
  13. #ifndef __dxva2api_h__
  14. #define __dxva2api_h__
  15. /* Forward declarations */
  16. #ifndef __IDirect3DDeviceManager9_FWD_DEFINED__
  17. #define __IDirect3DDeviceManager9_FWD_DEFINED__
  18. typedef interface IDirect3DDeviceManager9 IDirect3DDeviceManager9;
  19. #ifdef __cplusplus
  20. interface IDirect3DDeviceManager9;
  21. #endif /* __cplusplus */
  22. #endif
  23. #ifndef __IDirectXVideoAccelerationService_FWD_DEFINED__
  24. #define __IDirectXVideoAccelerationService_FWD_DEFINED__
  25. typedef interface IDirectXVideoAccelerationService IDirectXVideoAccelerationService;
  26. #ifdef __cplusplus
  27. interface IDirectXVideoAccelerationService;
  28. #endif /* __cplusplus */
  29. #endif
  30. #ifndef __IDirectXVideoDecoderService_FWD_DEFINED__
  31. #define __IDirectXVideoDecoderService_FWD_DEFINED__
  32. typedef interface IDirectXVideoDecoderService IDirectXVideoDecoderService;
  33. #ifdef __cplusplus
  34. interface IDirectXVideoDecoderService;
  35. #endif /* __cplusplus */
  36. #endif
  37. #ifndef __IDirectXVideoDecoder_FWD_DEFINED__
  38. #define __IDirectXVideoDecoder_FWD_DEFINED__
  39. typedef interface IDirectXVideoDecoder IDirectXVideoDecoder;
  40. #ifdef __cplusplus
  41. interface IDirectXVideoDecoder;
  42. #endif /* __cplusplus */
  43. #endif
  44. #ifndef __IDirectXVideoProcessorService_FWD_DEFINED__
  45. #define __IDirectXVideoProcessorService_FWD_DEFINED__
  46. typedef interface IDirectXVideoProcessorService IDirectXVideoProcessorService;
  47. #ifdef __cplusplus
  48. interface IDirectXVideoProcessorService;
  49. #endif /* __cplusplus */
  50. #endif
  51. #ifndef __IDirectXVideoProcessor_FWD_DEFINED__
  52. #define __IDirectXVideoProcessor_FWD_DEFINED__
  53. typedef interface IDirectXVideoProcessor IDirectXVideoProcessor;
  54. #ifdef __cplusplus
  55. interface IDirectXVideoProcessor;
  56. #endif /* __cplusplus */
  57. #endif
  58. #ifndef __IDirectXVideoMemoryConfiguration_FWD_DEFINED__
  59. #define __IDirectXVideoMemoryConfiguration_FWD_DEFINED__
  60. typedef interface IDirectXVideoMemoryConfiguration IDirectXVideoMemoryConfiguration;
  61. #ifdef __cplusplus
  62. interface IDirectXVideoMemoryConfiguration;
  63. #endif /* __cplusplus */
  64. #endif
  65. /* Headers for imported files */
  66. #include <unknwn.h>
  67. #ifdef __cplusplus
  68. extern "C" {
  69. #endif
  70. #if 0
  71. typedef DWORD IDirect3DDevice9;
  72. typedef DWORD IDirect3DSurface9;
  73. typedef DWORD D3DFORMAT;
  74. typedef DWORD D3DPOOL;
  75. #endif
  76. DEFINE_GUID(DXVA2_ModeMPEG2_MoComp, 0xe6a9f44b, 0x61b0,0x4563, 0x9e,0xa4,0x63,0xd2,0xa3,0xc6,0xfe,0x66);
  77. #define DXVA2_ModeMPEG2_MOCOMP DXVA2_ModeMPEG2_MoComp
  78. DEFINE_GUID(DXVA2_ModeMPEG2_IDCT, 0xbf22ad00, 0x03ea,0x4690, 0x80,0x77,0x47,0x33,0x46,0x20,0x9b,0x7e);
  79. DEFINE_GUID(DXVA2_ModeMPEG2_VLD, 0xee27417f, 0x5e28,0x4e65, 0xbe,0xea,0x1d,0x26,0xb5,0x08,0xad,0xc9);
  80. DEFINE_GUID(DXVA2_ModeMPEG1_VLD, 0x6f3ec719, 0x3735,0x42cc, 0x80,0x63,0x65,0xcc,0x3c,0xb3,0x66,0x16);
  81. DEFINE_GUID(DXVA2_ModeMPEG2and1_VLD, 0x86695f12, 0x340e,0x4f04, 0x9f,0xd3,0x92,0x53,0xdd,0x32,0x74,0x60);
  82. DEFINE_GUID(DXVA2_ModeH264_A, 0x1b81be64, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  83. #define DXVA2_ModeH264_MoComp_NoFGT DXVA2_ModeH264_A
  84. DEFINE_GUID(DXVA2_ModeH264_B, 0x1b81be65, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  85. #define DXVA2_ModeH264_MoComp_FGT DXVA2_ModeH264_B
  86. DEFINE_GUID(DXVA2_ModeH264_C, 0x1b81be66, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  87. #define DXVA2_ModeH264_IDCT_NoFGT DXVA2_ModeH264_C
  88. DEFINE_GUID(DXVA2_ModeH264_D, 0x1b81be67, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  89. #define DXVA2_ModeH264_IDCT_FGT DXVA2_ModeH264_D
  90. DEFINE_GUID(DXVA2_ModeH264_E, 0x1b81be68, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  91. #define DXVA2_ModeH264_VLD_NoFGT DXVA2_ModeH264_E
  92. DEFINE_GUID(DXVA2_ModeH264_F, 0x1b81be69, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  93. #define DXVA2_ModeH264_VLD_FGT DXVA2_ModeH264_F
  94. DEFINE_GUID(DXVA2_ModeH264_VLD_WithFMOASO_NoFGT, 0xd5f04ff9, 0x3418,0x45d8, 0x95,0x61,0x32,0xa7,0x6a,0xae,0x2d,0xdd);
  95. DEFINE_GUID(DXVA2_ModeH264_VLD_Stereo_Progressive_NoFGT, 0xd79be8da, 0x0cf1,0x4c81, 0xb8,0x2a,0x69,0xa4,0xe2,0x36,0xf4,0x3d);
  96. DEFINE_GUID(DXVA2_ModeH264_VLD_Stereo_NoFGT, 0xf9aaccbb, 0xc2b6,0x4cfc, 0x87,0x79,0x57,0x07,0xb1,0x76,0x05,0x52);
  97. DEFINE_GUID(DXVA2_ModeH264_VLD_Multiview_NoFGT, 0x705b9d82, 0x76cf,0x49d6, 0xb7,0xe6,0xac,0x88,0x72,0xdb,0x01,0x3c);
  98. DEFINE_GUID(DXVA2_ModeWMV8_A, 0x1b81be80, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  99. #define DXVA2_ModeWMV8_PostProc DXVA2_ModeWMV8_A
  100. DEFINE_GUID(DXVA2_ModeWMV8_B, 0x1b81be81, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  101. #define DXVA2_ModeWMV8_MoComp DXVA2_ModeWMV8_B
  102. DEFINE_GUID(DXVA2_ModeWMV9_A, 0x1b81be90, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  103. #define DXVA2_ModeWMV9_PostProc DXVA2_ModeWMV9_A
  104. DEFINE_GUID(DXVA2_ModeWMV9_B, 0x1b81be91, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  105. #define DXVA2_ModeWMV9_MoComp DXVA2_ModeWMV9_B
  106. DEFINE_GUID(DXVA2_ModeWMV9_C, 0x1b81be94, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  107. #define DXVA2_ModeWMV9_IDCT DXVA2_ModeWMV9_C
  108. DEFINE_GUID(DXVA2_ModeVC1_A, 0x1b81beA0, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  109. #define DXVA2_ModeVC1_PostProc DXVA2_ModeVC1_A
  110. DEFINE_GUID(DXVA2_ModeVC1_B, 0x1b81beA1, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  111. #define DXVA2_ModeVC1_MoComp DXVA2_ModeVC1_B
  112. DEFINE_GUID(DXVA2_ModeVC1_C, 0x1b81beA2, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  113. #define DXVA2_ModeVC1_IDCT DXVA2_ModeVC1_C
  114. DEFINE_GUID(DXVA2_ModeVC1_D, 0x1b81beA3, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  115. #define DXVA2_ModeVC1_VLD DXVA2_ModeVC1_D
  116. DEFINE_GUID(DXVA2_ModeVC1_D2010, 0x1b81bea4, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  117. DEFINE_GUID(DXVA2_NoEncrypt, 0x1b81bed0, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
  118. DEFINE_GUID(DXVA2_VideoProcProgressiveDevice, 0x5a54a0c9, 0xc7ec,0x4bd9, 0x8e,0xde,0xf3,0xc7,0x5d,0xc4,0x39,0x3b);
  119. DEFINE_GUID(DXVA2_VideoProcBobDevice, 0x335aa36e, 0x7884,0x43a4, 0x9c,0x91,0x7f,0x87,0xfa,0xf3,0xe3,0x7e);
  120. DEFINE_GUID(DXVA2_VideoProcSoftwareDevice, 0x4553d47f, 0xee7e,0x4e3f, 0x94,0x75,0xdb,0xf1,0x37,0x6c,0x48,0x10);
  121. DEFINE_GUID(DXVA2_ModeMPEG4pt2_VLD_Simple, 0xefd64d74, 0xc9e8,0x41d7, 0xa5,0xe9,0xe9,0xb0,0xe3,0x9f,0xa3,0x19);
  122. DEFINE_GUID(DXVA2_ModeMPEG4pt2_VLD_AdvSimple_NoGMC, 0xed418a9f, 0x010d,0x4eda, 0x9a,0xe3,0x9a,0x65,0x35,0x8d,0x8d,0x2e);
  123. DEFINE_GUID(DXVA2_ModeMPEG4pt2_VLD_AdvSimple_GMC, 0xab998b5b, 0x4258,0x44a9, 0x9f,0xeb,0x94,0xe5,0x97,0xa6,0xba,0xae);
  124. DEFINE_GUID(DXVA2_ModeHEVC_VLD_Main, 0x5b11d51b, 0x2f4c,0x4452, 0xbc,0xc3,0x09,0xf2,0xa1,0x16,0x0c,0xc0);
  125. DEFINE_GUID(DXVA2_ModeHEVC_VLD_Main10, 0x107af0e0, 0xef1a,0x4d19, 0xab,0xa8,0x67,0xa1,0x63,0x07,0x3d,0x13);
  126. DEFINE_GUID(DXVA2_ModeVP9_VLD_Profile0, 0x463707f8, 0xa1d0,0x4585, 0x87,0x6d,0x83,0xaa,0x6d,0x60,0xb8,0x9e);
  127. DEFINE_GUID(DXVA2_ModeVP9_VLD_10bit_Profile2, 0xa4c749ef, 0x6ecf,0x48aa, 0x84,0x48,0x50,0xa7,0xa1,0x16,0x5f,0xf7);
  128. DEFINE_GUID(DXVA2_ModeVP8_VLD, 0x90b899ea, 0x3a62,0x4705, 0x88,0xb3,0x8d,0xf0,0x4b,0x27,0x44,0xe7);
  129. #ifndef REFERENCE_TIME_DEFINED
  130. #define REFERENCE_TIME_DEFINED
  131. typedef LONGLONG REFERENCE_TIME;
  132. #endif
  133. #define DXVA2_E_NOT_INITIALIZED ((HRESULT)0x80041000)
  134. #define DXVA2_E_NEW_VIDEO_DEVICE ((HRESULT)0x80041001)
  135. #define DXVA2_E_VIDEO_DEVICE_LOCKED ((HRESULT)0x80041002)
  136. #define DXVA2_E_NOT_AVAILABLE ((HRESULT)0x80041003)
  137. enum {
  138. DXVA2_PictureParametersBufferType = 0,
  139. DXVA2_MacroBlockControlBufferType = 1,
  140. DXVA2_ResidualDifferenceBufferType = 2,
  141. DXVA2_DeblockingControlBufferType = 3,
  142. DXVA2_InverseQuantizationMatrixBufferType = 4,
  143. DXVA2_SliceControlBufferType = 5,
  144. DXVA2_BitStreamDateBufferType = 6,
  145. DXVA2_MotionVectorBuffer = 7,
  146. DXVA2_FilmGrainBuffer = 8
  147. };
  148. enum {
  149. DXVA2_VideoDecoderRenderTarget = 0,
  150. DXVA2_VideoProcessorRenderTarget = 1,
  151. DXVA2_VideoSoftwareRenderTarget = 2
  152. };
  153. typedef struct _DXVA2_ExtendedFormat {
  154. __C89_NAMELESS union {
  155. __C89_NAMELESS struct {
  156. UINT SampleFormat : 8;
  157. UINT VideoChromaSubsampling : 4;
  158. UINT NominalRange : 3;
  159. UINT VideoTransferMatrix : 3;
  160. UINT VideoLighting : 4;
  161. UINT VideoPrimaries : 5;
  162. UINT VideoTransferFunction : 5;
  163. } __C89_NAMELESSSTRUCTNAME;
  164. UINT value;
  165. } __C89_NAMELESSUNIONNAME;
  166. } DXVA2_ExtendedFormat;
  167. typedef enum _DXVA2_SampleFormat {
  168. DXVA2_SampleFormatMask = 0xff,
  169. DXVA2_SampleUnknown = 0,
  170. DXVA2_SampleProgressiveFrame = 2,
  171. DXVA2_SampleFieldInterleavedEvenFirst = 3,
  172. DXVA2_SampleFieldInterleavedOddFirst = 4,
  173. DXVA2_SampleFieldSingleEven = 5,
  174. DXVA2_SampleFieldSingleOdd = 6,
  175. DXVA2_SampleSubStream = 7
  176. } DXVA2_SampleFormat;
  177. typedef enum _DXVA2_VideoChromaSubSampling {
  178. DXVA2_VideoChromaSubsamplingMask = 0xf,
  179. DXVA2_VideoChromaSubsampling_Unknown = 0,
  180. DXVA2_VideoChromaSubsampling_ProgressiveChroma = 0x8,
  181. DXVA2_VideoChromaSubsampling_Horizontally_Cosited = 0x4,
  182. DXVA2_VideoChromaSubsampling_Vertically_Cosited = 0x2,
  183. DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes = 0x1,
  184. DXVA2_VideoChromaSubsampling_MPEG2 = DXVA2_VideoChromaSubsampling_Horizontally_Cosited | DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes,
  185. DXVA2_VideoChromaSubsampling_MPEG1 = DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes,
  186. DXVA2_VideoChromaSubsampling_DV_PAL = DXVA2_VideoChromaSubsampling_Horizontally_Cosited | DXVA2_VideoChromaSubsampling_Vertically_Cosited,
  187. DXVA2_VideoChromaSubsampling_Cosited = (DXVA2_VideoChromaSubsampling_Horizontally_Cosited | DXVA2_VideoChromaSubsampling_Vertically_Cosited) | DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes
  188. } DXVA2_VideoChromaSubSampling;
  189. typedef enum _DXVA2_NominalRange {
  190. DXVA2_NominalRangeMask = 0x7,
  191. DXVA2_NominalRange_Unknown = 0,
  192. DXVA2_NominalRange_Normal = 1,
  193. DXVA2_NominalRange_Wide = 2,
  194. DXVA2_NominalRange_0_255 = 1,
  195. DXVA2_NominalRange_16_235 = 2,
  196. DXVA2_NominalRange_48_208 = 3
  197. } DXVA2_NominalRange;
  198. typedef enum _DXVA2_VideoTransferMatrix {
  199. DXVA2_VideoTransferMatrixMask = 0x7,
  200. DXVA2_VideoTransferMatrix_Unknown = 0,
  201. DXVA2_VideoTransferMatrix_BT709 = 1,
  202. DXVA2_VideoTransferMatrix_BT601 = 2,
  203. DXVA2_VideoTransferMatrix_SMPTE240M = 3
  204. } DXVA2_VideoTransferMatrix;
  205. typedef enum _DXVA2_VideoLighting {
  206. DXVA2_VideoLightingMask = 0xf,
  207. DXVA2_VideoLighting_Unknown = 0,
  208. DXVA2_VideoLighting_bright = 1,
  209. DXVA2_VideoLighting_office = 2,
  210. DXVA2_VideoLighting_dim = 3,
  211. DXVA2_VideoLighting_dark = 4
  212. } DXVA2_VideoLighting;
  213. typedef enum _DXVA2_VideoPrimaries {
  214. DXVA2_VideoPrimariesMask = 0x1f,
  215. DXVA2_VideoPrimaries_Unknown = 0,
  216. DXVA2_VideoPrimaries_reserved = 1,
  217. DXVA2_VideoPrimaries_BT709 = 2,
  218. DXVA2_VideoPrimaries_BT470_2_SysM = 3,
  219. DXVA2_VideoPrimaries_BT470_2_SysBG = 4,
  220. DXVA2_VideoPrimaries_SMPTE170M = 5,
  221. DXVA2_VideoPrimaries_SMPTE240M = 6,
  222. DXVA2_VideoPrimaries_EBU3213 = 7,
  223. DXVA2_VideoPrimaries_SMPTE_C = 8
  224. } DXVA2_VideoPrimaries;
  225. typedef enum _DXVA2_VideoTransferFunction {
  226. DXVA2_VideoTransFuncMask = 0x1f,
  227. DXVA2_VideoTransFunc_Unknown = 0,
  228. DXVA2_VideoTransFunc_10 = 1,
  229. DXVA2_VideoTransFunc_18 = 2,
  230. DXVA2_VideoTransFunc_20 = 3,
  231. DXVA2_VideoTransFunc_22 = 4,
  232. DXVA2_VideoTransFunc_709 = 5,
  233. DXVA2_VideoTransFunc_240M = 6,
  234. DXVA2_VideoTransFunc_sRGB = 7,
  235. DXVA2_VideoTransFunc_28 = 8
  236. } DXVA2_VideoTransferFunction;
  237. #define DXVA2_VideoTransFunc_22_709 DXVA2_VideoTransFunc_709
  238. #define DXVA2_VideoTransFunc_22_240M DXVA2_VideoTransFunc_240M
  239. #define DXVA2_VideoTransFunc_22_8bit_sRGB DXVA2_VideoTransFunc_sRGB
  240. typedef struct _DXVA2_Frequency {
  241. UINT Numerator;
  242. UINT Denominator;
  243. } DXVA2_Frequency;
  244. typedef struct _DXVA2_ConfigPictureDecode {
  245. GUID guidConfigBitstreamEncryption;
  246. GUID guidConfigMBcontrolEncryption;
  247. GUID guidConfigResidDiffEncryption;
  248. UINT ConfigBitstreamRaw;
  249. UINT ConfigMBcontrolRasterOrder;
  250. UINT ConfigResidDiffHost;
  251. UINT ConfigSpatialResid8;
  252. UINT ConfigResid8Subtraction;
  253. UINT ConfigSpatialHost8or9Clipping;
  254. UINT ConfigSpatialResidInterleaved;
  255. UINT ConfigIntraResidUnsigned;
  256. UINT ConfigResidDiffAccelerator;
  257. UINT ConfigHostInverseScan;
  258. UINT ConfigSpecificIDCT;
  259. UINT Config4GroupedCoefs;
  260. UINT ConfigMinRenderTargetBuffCount;
  261. USHORT ConfigDecoderSpecific;
  262. } DXVA2_ConfigPictureDecode;
  263. typedef struct _DXVA2_VideoDesc {
  264. UINT SampleWidth;
  265. UINT SampleHeight;
  266. DXVA2_ExtendedFormat SampleFormat;
  267. D3DFORMAT Format;
  268. DXVA2_Frequency InputSampleFreq;
  269. DXVA2_Frequency OutputFrameFreq;
  270. UINT UABProtectionLevel;
  271. UINT Reserved;
  272. } DXVA2_VideoDesc;
  273. enum {
  274. DXVA2_DeinterlaceTech_Unknown = 0x0,
  275. DXVA2_DeinterlaceTech_BOBLineReplicate = 0x1,
  276. DXVA2_DeinterlaceTech_BOBVerticalStretch = 0x2,
  277. DXVA2_DeinterlaceTech_BOBVerticalStretch4Tap = 0x4,
  278. DXVA2_DeinterlaceTech_MedianFiltering = 0x8,
  279. DXVA2_DeinterlaceTech_EdgeFiltering = 0x10,
  280. DXVA2_DeinterlaceTech_FieldAdaptive = 0x20,
  281. DXVA2_DeinterlaceTech_PixelAdaptive = 0x40,
  282. DXVA2_DeinterlaceTech_MotionVectorSteered = 0x80,
  283. DXVA2_DeinterlaceTech_InverseTelecine = 0x100,
  284. DXVA2_DeinterlaceTech_Mask = 0x1ff
  285. };
  286. enum {
  287. DXVA2_NoiseFilterLumaLevel = 1,
  288. DXVA2_NoiseFilterLumaThreshold = 2,
  289. DXVA2_NoiseFilterLumaRadius = 3,
  290. DXVA2_NoiseFilterChromaLevel = 4,
  291. DXVA2_NoiseFilterChromaThreshold = 5,
  292. DXVA2_NoiseFilterChromaRadius = 6,
  293. DXVA2_DetailFilterLumaLevel = 7,
  294. DXVA2_DetailFilterLumaThreshold = 8,
  295. DXVA2_DetailFilterLumaRadius = 9,
  296. DXVA2_DetailFilterChromaLevel = 10,
  297. DXVA2_DetailFilterChromaThreshold = 11,
  298. DXVA2_DetailFilterChromaRadius = 12
  299. };
  300. enum {
  301. DXVA2_NoiseFilterTech_Unsupported = 0,
  302. DXVA2_NoiseFilterTech_Unknown = 0x1,
  303. DXVA2_NoiseFilterTech_Median = 0x2,
  304. DXVA2_NoiseFilterTech_Temporal = 0x4,
  305. DXVA2_NoiseFilterTech_BlockNoise = 0x8,
  306. DXVA2_NoiseFilterTech_MosquitoNoise = 0x10,
  307. DXVA2_NoiseFilterTech_Mask = 0x1f
  308. };
  309. enum {
  310. DXVA2_DetailFilterTech_Unsupported = 0,
  311. DXVA2_DetailFilterTech_Unknown = 0x1,
  312. DXVA2_DetailFilterTech_Edge = 0x2,
  313. DXVA2_DetailFilterTech_Sharpening = 0x4,
  314. DXVA2_DetailFilterTech_Mask = 0x7
  315. };
  316. enum {
  317. DXVA2_ProcAmp_None = 0x0,
  318. DXVA2_ProcAmp_Brightness = 0x1,
  319. DXVA2_ProcAmp_Contrast = 0x2,
  320. DXVA2_ProcAmp_Hue = 0x4,
  321. DXVA2_ProcAmp_Saturation = 0x8,
  322. DXVA2_ProcAmp_Mask = 0xf
  323. };
  324. enum {
  325. DXVA2_VideoProcess_None = 0x0,
  326. DXVA2_VideoProcess_YUV2RGB = 0x1,
  327. DXVA2_VideoProcess_StretchX = 0x2,
  328. DXVA2_VideoProcess_StretchY = 0x4,
  329. DXVA2_VideoProcess_AlphaBlend = 0x8,
  330. DXVA2_VideoProcess_SubRects = 0x10,
  331. DXVA2_VideoProcess_SubStreams = 0x20,
  332. DXVA2_VideoProcess_SubStreamsExtended = 0x40,
  333. DXVA2_VideoProcess_YUV2RGBExtended = 0x80,
  334. DXVA2_VideoProcess_AlphaBlendExtended = 0x100,
  335. DXVA2_VideoProcess_Constriction = 0x200,
  336. DXVA2_VideoProcess_NoiseFilter = 0x400,
  337. DXVA2_VideoProcess_DetailFilter = 0x800,
  338. DXVA2_VideoProcess_PlanarAlpha = 0x1000,
  339. DXVA2_VideoProcess_LinearScaling = 0x2000,
  340. DXVA2_VideoProcess_GammaCompensated = 0x4000,
  341. DXVA2_VideoProcess_MaintainsOriginalFieldData = 0x8000,
  342. DXVA2_VideoProcess_Mask = 0xffff
  343. };
  344. enum {
  345. DXVA2_VPDev_HardwareDevice = 0x1,
  346. DXVA2_VPDev_EmulatedDXVA1 = 0x2,
  347. DXVA2_VPDev_SoftwareDevice = 0x4,
  348. DXVA2_VPDev_Mask = 0x7
  349. };
  350. enum {
  351. DXVA2_SampleData_RFF = 0x1,
  352. DXVA2_SampleData_TFF = 0x2,
  353. DXVA2_SampleData_RFF_TFF_Present = 0x4,
  354. DXVA2_SampleData_Mask = 0xffff
  355. };
  356. enum {
  357. DXVA2_DestData_RFF = 0x1,
  358. DXVA2_DestData_TFF = 0x2,
  359. DXVA2_DestData_RFF_TFF_Present = 0x4,
  360. DXVA2_DestData_Mask = 0xffff
  361. };
  362. typedef struct _DXVA2_DecodeBufferDesc {
  363. DWORD CompressedBufferType;
  364. UINT BufferIndex;
  365. UINT DataOffset;
  366. UINT DataSize;
  367. UINT FirstMBaddress;
  368. UINT NumMBsInBuffer;
  369. UINT Width;
  370. UINT Height;
  371. UINT Stride;
  372. UINT ReservedBits;
  373. PVOID pvPVPState;
  374. } DXVA2_DecodeBufferDesc;
  375. typedef struct _DXVA2_AES_CTR_IV {
  376. UINT64 IV;
  377. UINT64 Count;
  378. } DXVA2_AES_CTR_IV;
  379. typedef struct _DXVA2_DecodeExtensionData {
  380. UINT Function;
  381. PVOID pPrivateInputData;
  382. UINT PrivateInputDataSize;
  383. PVOID pPrivateOutputData;
  384. UINT PrivateOutputDataSize;
  385. } DXVA2_DecodeExtensionData;
  386. typedef struct _DXVA2_DecodeExecuteParams {
  387. UINT NumCompBuffers;
  388. DXVA2_DecodeBufferDesc *pCompressedBuffers;
  389. DXVA2_DecodeExtensionData *pExtensionData;
  390. } DXVA2_DecodeExecuteParams;
  391. typedef struct _DXVA2_VideoProcessorCaps {
  392. UINT DeviceCaps;
  393. D3DPOOL InputPool;
  394. UINT NumForwardRefSamples;
  395. UINT NumBackwardRefSamples;
  396. UINT Reserved;
  397. UINT DeinterlaceTechnology;
  398. UINT ProcAmpControlCaps;
  399. UINT VideoProcessorOperations;
  400. UINT NoiseFilterTechnology;
  401. UINT DetailFilterTechnology;
  402. } DXVA2_VideoProcessorCaps;
  403. typedef struct _DXVA2_Fixed32 {
  404. __C89_NAMELESS union {
  405. __C89_NAMELESS struct {
  406. USHORT Fraction;
  407. SHORT Value;
  408. } __C89_NAMELESSSTRUCTNAME;
  409. LONG ll;
  410. } __C89_NAMELESSUNIONNAME;
  411. } DXVA2_Fixed32;
  412. typedef struct _DXVA2_ValueRange {
  413. DXVA2_Fixed32 MinValue;
  414. DXVA2_Fixed32 MaxValue;
  415. DXVA2_Fixed32 DefaultValue;
  416. DXVA2_Fixed32 StepSize;
  417. } DXVA2_ValueRange;
  418. typedef struct _DXVA2_AYUVSample8 {
  419. UCHAR Cr;
  420. UCHAR Cb;
  421. UCHAR Y;
  422. UCHAR Alpha;
  423. } DXVA2_AYUVSample8;
  424. typedef struct _DXVA2_AYUVSample16 {
  425. USHORT Cr;
  426. USHORT Cb;
  427. USHORT Y;
  428. USHORT Alpha;
  429. } DXVA2_AYUVSample16;
  430. typedef struct _DXVA2_ProcAmpValues {
  431. DXVA2_Fixed32 Brightness;
  432. DXVA2_Fixed32 Contrast;
  433. DXVA2_Fixed32 Hue;
  434. DXVA2_Fixed32 Saturation;
  435. } DXVA2_ProcAmpValues;
  436. typedef struct _DXVA2_FilterValues {
  437. DXVA2_Fixed32 Level;
  438. DXVA2_Fixed32 Threshold;
  439. DXVA2_Fixed32 Radius;
  440. } DXVA2_FilterValues;
  441. typedef struct _DXVA2_VideoProcessBltParams {
  442. REFERENCE_TIME TargetFrame;
  443. RECT TargetRect;
  444. SIZE ConstrictionSize;
  445. UINT StreamingFlags;
  446. DXVA2_AYUVSample16 BackgroundColor;
  447. DXVA2_ExtendedFormat DestFormat;
  448. DXVA2_ProcAmpValues ProcAmpValues;
  449. DXVA2_Fixed32 Alpha;
  450. DXVA2_FilterValues NoiseFilterLuma;
  451. DXVA2_FilterValues NoiseFilterChroma;
  452. DXVA2_FilterValues DetailFilterLuma;
  453. DXVA2_FilterValues DetailFilterChroma;
  454. DWORD DestData;
  455. } DXVA2_VideoProcessBltParams;
  456. #ifdef _D3D9_H_
  457. typedef struct _DXVA2_VideoSample {
  458. REFERENCE_TIME Start;
  459. REFERENCE_TIME End;
  460. DXVA2_ExtendedFormat SampleFormat;
  461. IDirect3DSurface9 *SrcSurface;
  462. RECT SrcRect;
  463. RECT DstRect;
  464. DXVA2_AYUVSample8 Pal[16];
  465. DXVA2_Fixed32 PlanarAlpha;
  466. DWORD SampleData;
  467. } DXVA2_VideoSample;
  468. typedef enum __WIDL_dxva2api_generated_name_0000000C {
  469. DXVA2_SurfaceType_DecoderRenderTarget = 0,
  470. DXVA2_SurfaceType_ProcessorRenderTarget = 1,
  471. DXVA2_SurfaceType_D3DRenderTargetTexture = 2
  472. } DXVA2_SurfaceType;
  473. #ifndef __IDirect3DDeviceManager9_FWD_DEFINED__
  474. #define __IDirect3DDeviceManager9_FWD_DEFINED__
  475. typedef interface IDirect3DDeviceManager9 IDirect3DDeviceManager9;
  476. #ifdef __cplusplus
  477. interface IDirect3DDeviceManager9;
  478. #endif /* __cplusplus */
  479. #endif
  480. #ifndef __IDirectXVideoAccelerationService_FWD_DEFINED__
  481. #define __IDirectXVideoAccelerationService_FWD_DEFINED__
  482. typedef interface IDirectXVideoAccelerationService IDirectXVideoAccelerationService;
  483. #ifdef __cplusplus
  484. interface IDirectXVideoAccelerationService;
  485. #endif /* __cplusplus */
  486. #endif
  487. #ifndef __IDirectXVideoDecoderService_FWD_DEFINED__
  488. #define __IDirectXVideoDecoderService_FWD_DEFINED__
  489. typedef interface IDirectXVideoDecoderService IDirectXVideoDecoderService;
  490. #ifdef __cplusplus
  491. interface IDirectXVideoDecoderService;
  492. #endif /* __cplusplus */
  493. #endif
  494. #ifndef __IDirectXVideoProcessorService_FWD_DEFINED__
  495. #define __IDirectXVideoProcessorService_FWD_DEFINED__
  496. typedef interface IDirectXVideoProcessorService IDirectXVideoProcessorService;
  497. #ifdef __cplusplus
  498. interface IDirectXVideoProcessorService;
  499. #endif /* __cplusplus */
  500. #endif
  501. #ifndef __IDirectXVideoDecoder_FWD_DEFINED__
  502. #define __IDirectXVideoDecoder_FWD_DEFINED__
  503. typedef interface IDirectXVideoDecoder IDirectXVideoDecoder;
  504. #ifdef __cplusplus
  505. interface IDirectXVideoDecoder;
  506. #endif /* __cplusplus */
  507. #endif
  508. #ifndef __IDirectXVideoProcessor_FWD_DEFINED__
  509. #define __IDirectXVideoProcessor_FWD_DEFINED__
  510. typedef interface IDirectXVideoProcessor IDirectXVideoProcessor;
  511. #ifdef __cplusplus
  512. interface IDirectXVideoProcessor;
  513. #endif /* __cplusplus */
  514. #endif
  515. /*****************************************************************************
  516. * IDirect3DDeviceManager9 interface
  517. */
  518. #ifndef __IDirect3DDeviceManager9_INTERFACE_DEFINED__
  519. #define __IDirect3DDeviceManager9_INTERFACE_DEFINED__
  520. DEFINE_GUID(IID_IDirect3DDeviceManager9, 0xa0cade0f, 0x06d5, 0x4cf4, 0xa1,0xc7, 0xf3,0xcd,0xd7,0x25,0xaa,0x75);
  521. #if defined(__cplusplus) && !defined(CINTERFACE)
  522. MIDL_INTERFACE("a0cade0f-06d5-4cf4-a1c7-f3cdd725aa75")
  523. IDirect3DDeviceManager9 : public IUnknown
  524. {
  525. virtual HRESULT STDMETHODCALLTYPE ResetDevice(
  526. IDirect3DDevice9 *pDevice,
  527. UINT resetToken) = 0;
  528. virtual HRESULT STDMETHODCALLTYPE OpenDeviceHandle(
  529. HANDLE *phDevice) = 0;
  530. virtual HRESULT STDMETHODCALLTYPE CloseDeviceHandle(
  531. HANDLE hDevice) = 0;
  532. virtual HRESULT STDMETHODCALLTYPE TestDevice(
  533. HANDLE hDevice) = 0;
  534. virtual HRESULT STDMETHODCALLTYPE LockDevice(
  535. HANDLE hDevice,
  536. IDirect3DDevice9 **ppDevice,
  537. WINBOOL fBlock) = 0;
  538. virtual HRESULT STDMETHODCALLTYPE UnlockDevice(
  539. HANDLE hDevice,
  540. WINBOOL fSaveState) = 0;
  541. virtual HRESULT STDMETHODCALLTYPE GetVideoService(
  542. HANDLE hDevice,
  543. REFIID riid,
  544. void **ppService) = 0;
  545. };
  546. #ifdef __CRT_UUID_DECL
  547. __CRT_UUID_DECL(IDirect3DDeviceManager9, 0xa0cade0f, 0x06d5, 0x4cf4, 0xa1,0xc7, 0xf3,0xcd,0xd7,0x25,0xaa,0x75)
  548. #endif
  549. #else
  550. typedef struct IDirect3DDeviceManager9Vtbl {
  551. BEGIN_INTERFACE
  552. /*** IUnknown methods ***/
  553. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  554. IDirect3DDeviceManager9 *This,
  555. REFIID riid,
  556. void **ppvObject);
  557. ULONG (STDMETHODCALLTYPE *AddRef)(
  558. IDirect3DDeviceManager9 *This);
  559. ULONG (STDMETHODCALLTYPE *Release)(
  560. IDirect3DDeviceManager9 *This);
  561. /*** IDirect3DDeviceManager9 methods ***/
  562. HRESULT (STDMETHODCALLTYPE *ResetDevice)(
  563. IDirect3DDeviceManager9 *This,
  564. IDirect3DDevice9 *pDevice,
  565. UINT resetToken);
  566. HRESULT (STDMETHODCALLTYPE *OpenDeviceHandle)(
  567. IDirect3DDeviceManager9 *This,
  568. HANDLE *phDevice);
  569. HRESULT (STDMETHODCALLTYPE *CloseDeviceHandle)(
  570. IDirect3DDeviceManager9 *This,
  571. HANDLE hDevice);
  572. HRESULT (STDMETHODCALLTYPE *TestDevice)(
  573. IDirect3DDeviceManager9 *This,
  574. HANDLE hDevice);
  575. HRESULT (STDMETHODCALLTYPE *LockDevice)(
  576. IDirect3DDeviceManager9 *This,
  577. HANDLE hDevice,
  578. IDirect3DDevice9 **ppDevice,
  579. WINBOOL fBlock);
  580. HRESULT (STDMETHODCALLTYPE *UnlockDevice)(
  581. IDirect3DDeviceManager9 *This,
  582. HANDLE hDevice,
  583. WINBOOL fSaveState);
  584. HRESULT (STDMETHODCALLTYPE *GetVideoService)(
  585. IDirect3DDeviceManager9 *This,
  586. HANDLE hDevice,
  587. REFIID riid,
  588. void **ppService);
  589. END_INTERFACE
  590. } IDirect3DDeviceManager9Vtbl;
  591. interface IDirect3DDeviceManager9 {
  592. CONST_VTBL IDirect3DDeviceManager9Vtbl* lpVtbl;
  593. };
  594. #ifdef COBJMACROS
  595. #ifndef WIDL_C_INLINE_WRAPPERS
  596. /*** IUnknown methods ***/
  597. #define IDirect3DDeviceManager9_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  598. #define IDirect3DDeviceManager9_AddRef(This) (This)->lpVtbl->AddRef(This)
  599. #define IDirect3DDeviceManager9_Release(This) (This)->lpVtbl->Release(This)
  600. /*** IDirect3DDeviceManager9 methods ***/
  601. #define IDirect3DDeviceManager9_ResetDevice(This,pDevice,resetToken) (This)->lpVtbl->ResetDevice(This,pDevice,resetToken)
  602. #define IDirect3DDeviceManager9_OpenDeviceHandle(This,phDevice) (This)->lpVtbl->OpenDeviceHandle(This,phDevice)
  603. #define IDirect3DDeviceManager9_CloseDeviceHandle(This,hDevice) (This)->lpVtbl->CloseDeviceHandle(This,hDevice)
  604. #define IDirect3DDeviceManager9_TestDevice(This,hDevice) (This)->lpVtbl->TestDevice(This,hDevice)
  605. #define IDirect3DDeviceManager9_LockDevice(This,hDevice,ppDevice,fBlock) (This)->lpVtbl->LockDevice(This,hDevice,ppDevice,fBlock)
  606. #define IDirect3DDeviceManager9_UnlockDevice(This,hDevice,fSaveState) (This)->lpVtbl->UnlockDevice(This,hDevice,fSaveState)
  607. #define IDirect3DDeviceManager9_GetVideoService(This,hDevice,riid,ppService) (This)->lpVtbl->GetVideoService(This,hDevice,riid,ppService)
  608. #else
  609. /*** IUnknown methods ***/
  610. static FORCEINLINE HRESULT IDirect3DDeviceManager9_QueryInterface(IDirect3DDeviceManager9* This,REFIID riid,void **ppvObject) {
  611. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  612. }
  613. static FORCEINLINE ULONG IDirect3DDeviceManager9_AddRef(IDirect3DDeviceManager9* This) {
  614. return This->lpVtbl->AddRef(This);
  615. }
  616. static FORCEINLINE ULONG IDirect3DDeviceManager9_Release(IDirect3DDeviceManager9* This) {
  617. return This->lpVtbl->Release(This);
  618. }
  619. /*** IDirect3DDeviceManager9 methods ***/
  620. static FORCEINLINE HRESULT IDirect3DDeviceManager9_ResetDevice(IDirect3DDeviceManager9* This,IDirect3DDevice9 *pDevice,UINT resetToken) {
  621. return This->lpVtbl->ResetDevice(This,pDevice,resetToken);
  622. }
  623. static FORCEINLINE HRESULT IDirect3DDeviceManager9_OpenDeviceHandle(IDirect3DDeviceManager9* This,HANDLE *phDevice) {
  624. return This->lpVtbl->OpenDeviceHandle(This,phDevice);
  625. }
  626. static FORCEINLINE HRESULT IDirect3DDeviceManager9_CloseDeviceHandle(IDirect3DDeviceManager9* This,HANDLE hDevice) {
  627. return This->lpVtbl->CloseDeviceHandle(This,hDevice);
  628. }
  629. static FORCEINLINE HRESULT IDirect3DDeviceManager9_TestDevice(IDirect3DDeviceManager9* This,HANDLE hDevice) {
  630. return This->lpVtbl->TestDevice(This,hDevice);
  631. }
  632. static FORCEINLINE HRESULT IDirect3DDeviceManager9_LockDevice(IDirect3DDeviceManager9* This,HANDLE hDevice,IDirect3DDevice9 **ppDevice,WINBOOL fBlock) {
  633. return This->lpVtbl->LockDevice(This,hDevice,ppDevice,fBlock);
  634. }
  635. static FORCEINLINE HRESULT IDirect3DDeviceManager9_UnlockDevice(IDirect3DDeviceManager9* This,HANDLE hDevice,WINBOOL fSaveState) {
  636. return This->lpVtbl->UnlockDevice(This,hDevice,fSaveState);
  637. }
  638. static FORCEINLINE HRESULT IDirect3DDeviceManager9_GetVideoService(IDirect3DDeviceManager9* This,HANDLE hDevice,REFIID riid,void **ppService) {
  639. return This->lpVtbl->GetVideoService(This,hDevice,riid,ppService);
  640. }
  641. #endif
  642. #endif
  643. #endif
  644. #endif /* __IDirect3DDeviceManager9_INTERFACE_DEFINED__ */
  645. /*****************************************************************************
  646. * IDirectXVideoAccelerationService interface
  647. */
  648. #ifndef __IDirectXVideoAccelerationService_INTERFACE_DEFINED__
  649. #define __IDirectXVideoAccelerationService_INTERFACE_DEFINED__
  650. DEFINE_GUID(IID_IDirectXVideoAccelerationService, 0xfc51a550, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02);
  651. #if defined(__cplusplus) && !defined(CINTERFACE)
  652. MIDL_INTERFACE("fc51a550-d5e7-11d9-af55-00054e43ff02")
  653. IDirectXVideoAccelerationService : public IUnknown
  654. {
  655. virtual HRESULT STDMETHODCALLTYPE CreateSurface(
  656. UINT width,
  657. UINT height,
  658. UINT backBuffers,
  659. D3DFORMAT format,
  660. D3DPOOL pool,
  661. DWORD usage,
  662. DWORD dxvaType,
  663. IDirect3DSurface9 **ppSurface,
  664. HANDLE *pSharedHandle) = 0;
  665. };
  666. #ifdef __CRT_UUID_DECL
  667. __CRT_UUID_DECL(IDirectXVideoAccelerationService, 0xfc51a550, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02)
  668. #endif
  669. #else
  670. typedef struct IDirectXVideoAccelerationServiceVtbl {
  671. BEGIN_INTERFACE
  672. /*** IUnknown methods ***/
  673. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  674. IDirectXVideoAccelerationService *This,
  675. REFIID riid,
  676. void **ppvObject);
  677. ULONG (STDMETHODCALLTYPE *AddRef)(
  678. IDirectXVideoAccelerationService *This);
  679. ULONG (STDMETHODCALLTYPE *Release)(
  680. IDirectXVideoAccelerationService *This);
  681. /*** IDirectXVideoAccelerationService methods ***/
  682. HRESULT (STDMETHODCALLTYPE *CreateSurface)(
  683. IDirectXVideoAccelerationService *This,
  684. UINT width,
  685. UINT height,
  686. UINT backBuffers,
  687. D3DFORMAT format,
  688. D3DPOOL pool,
  689. DWORD usage,
  690. DWORD dxvaType,
  691. IDirect3DSurface9 **ppSurface,
  692. HANDLE *pSharedHandle);
  693. END_INTERFACE
  694. } IDirectXVideoAccelerationServiceVtbl;
  695. interface IDirectXVideoAccelerationService {
  696. CONST_VTBL IDirectXVideoAccelerationServiceVtbl* lpVtbl;
  697. };
  698. #ifdef COBJMACROS
  699. #ifndef WIDL_C_INLINE_WRAPPERS
  700. /*** IUnknown methods ***/
  701. #define IDirectXVideoAccelerationService_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  702. #define IDirectXVideoAccelerationService_AddRef(This) (This)->lpVtbl->AddRef(This)
  703. #define IDirectXVideoAccelerationService_Release(This) (This)->lpVtbl->Release(This)
  704. /*** IDirectXVideoAccelerationService methods ***/
  705. #define IDirectXVideoAccelerationService_CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle) (This)->lpVtbl->CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle)
  706. #else
  707. /*** IUnknown methods ***/
  708. static FORCEINLINE HRESULT IDirectXVideoAccelerationService_QueryInterface(IDirectXVideoAccelerationService* This,REFIID riid,void **ppvObject) {
  709. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  710. }
  711. static FORCEINLINE ULONG IDirectXVideoAccelerationService_AddRef(IDirectXVideoAccelerationService* This) {
  712. return This->lpVtbl->AddRef(This);
  713. }
  714. static FORCEINLINE ULONG IDirectXVideoAccelerationService_Release(IDirectXVideoAccelerationService* This) {
  715. return This->lpVtbl->Release(This);
  716. }
  717. /*** IDirectXVideoAccelerationService methods ***/
  718. static FORCEINLINE HRESULT IDirectXVideoAccelerationService_CreateSurface(IDirectXVideoAccelerationService* This,UINT width,UINT height,UINT backBuffers,D3DFORMAT format,D3DPOOL pool,DWORD usage,DWORD dxvaType,IDirect3DSurface9 **ppSurface,HANDLE *pSharedHandle) {
  719. return This->lpVtbl->CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle);
  720. }
  721. #endif
  722. #endif
  723. #endif
  724. #endif /* __IDirectXVideoAccelerationService_INTERFACE_DEFINED__ */
  725. /*****************************************************************************
  726. * IDirectXVideoDecoderService interface
  727. */
  728. #ifndef __IDirectXVideoDecoderService_INTERFACE_DEFINED__
  729. #define __IDirectXVideoDecoderService_INTERFACE_DEFINED__
  730. DEFINE_GUID(IID_IDirectXVideoDecoderService, 0xfc51a551, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02);
  731. #if defined(__cplusplus) && !defined(CINTERFACE)
  732. MIDL_INTERFACE("fc51a551-d5e7-11d9-af55-00054e43ff02")
  733. IDirectXVideoDecoderService : public IDirectXVideoAccelerationService
  734. {
  735. virtual HRESULT STDMETHODCALLTYPE GetDecoderDeviceGuids(
  736. UINT *count,
  737. GUID **pGuids) = 0;
  738. virtual HRESULT STDMETHODCALLTYPE GetDecoderRenderTargets(
  739. REFGUID guid,
  740. UINT *pCount,
  741. D3DFORMAT **pFormats) = 0;
  742. virtual HRESULT STDMETHODCALLTYPE GetDecoderConfigurations(
  743. REFGUID guid,
  744. const DXVA2_VideoDesc *pVideoDesc,
  745. void *pReserved,
  746. UINT *pCount,
  747. DXVA2_ConfigPictureDecode **ppConfigs) = 0;
  748. virtual HRESULT STDMETHODCALLTYPE CreateVideoDecoder(
  749. REFGUID guid,
  750. const DXVA2_VideoDesc *pVideoDesc,
  751. const DXVA2_ConfigPictureDecode *pConfig,
  752. IDirect3DSurface9 **ppDecoderRenderTargets,
  753. UINT NumSurfaces,
  754. IDirectXVideoDecoder **ppDecode) = 0;
  755. };
  756. #ifdef __CRT_UUID_DECL
  757. __CRT_UUID_DECL(IDirectXVideoDecoderService, 0xfc51a551, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02)
  758. #endif
  759. #else
  760. typedef struct IDirectXVideoDecoderServiceVtbl {
  761. BEGIN_INTERFACE
  762. /*** IUnknown methods ***/
  763. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  764. IDirectXVideoDecoderService *This,
  765. REFIID riid,
  766. void **ppvObject);
  767. ULONG (STDMETHODCALLTYPE *AddRef)(
  768. IDirectXVideoDecoderService *This);
  769. ULONG (STDMETHODCALLTYPE *Release)(
  770. IDirectXVideoDecoderService *This);
  771. /*** IDirectXVideoAccelerationService methods ***/
  772. HRESULT (STDMETHODCALLTYPE *CreateSurface)(
  773. IDirectXVideoDecoderService *This,
  774. UINT width,
  775. UINT height,
  776. UINT backBuffers,
  777. D3DFORMAT format,
  778. D3DPOOL pool,
  779. DWORD usage,
  780. DWORD dxvaType,
  781. IDirect3DSurface9 **ppSurface,
  782. HANDLE *pSharedHandle);
  783. /*** IDirectXVideoDecoderService methods ***/
  784. HRESULT (STDMETHODCALLTYPE *GetDecoderDeviceGuids)(
  785. IDirectXVideoDecoderService *This,
  786. UINT *count,
  787. GUID **pGuids);
  788. HRESULT (STDMETHODCALLTYPE *GetDecoderRenderTargets)(
  789. IDirectXVideoDecoderService *This,
  790. REFGUID guid,
  791. UINT *pCount,
  792. D3DFORMAT **pFormats);
  793. HRESULT (STDMETHODCALLTYPE *GetDecoderConfigurations)(
  794. IDirectXVideoDecoderService *This,
  795. REFGUID guid,
  796. const DXVA2_VideoDesc *pVideoDesc,
  797. void *pReserved,
  798. UINT *pCount,
  799. DXVA2_ConfigPictureDecode **ppConfigs);
  800. HRESULT (STDMETHODCALLTYPE *CreateVideoDecoder)(
  801. IDirectXVideoDecoderService *This,
  802. REFGUID guid,
  803. const DXVA2_VideoDesc *pVideoDesc,
  804. const DXVA2_ConfigPictureDecode *pConfig,
  805. IDirect3DSurface9 **ppDecoderRenderTargets,
  806. UINT NumSurfaces,
  807. IDirectXVideoDecoder **ppDecode);
  808. END_INTERFACE
  809. } IDirectXVideoDecoderServiceVtbl;
  810. interface IDirectXVideoDecoderService {
  811. CONST_VTBL IDirectXVideoDecoderServiceVtbl* lpVtbl;
  812. };
  813. #ifdef COBJMACROS
  814. #ifndef WIDL_C_INLINE_WRAPPERS
  815. /*** IUnknown methods ***/
  816. #define IDirectXVideoDecoderService_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  817. #define IDirectXVideoDecoderService_AddRef(This) (This)->lpVtbl->AddRef(This)
  818. #define IDirectXVideoDecoderService_Release(This) (This)->lpVtbl->Release(This)
  819. /*** IDirectXVideoAccelerationService methods ***/
  820. #define IDirectXVideoDecoderService_CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle) (This)->lpVtbl->CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle)
  821. /*** IDirectXVideoDecoderService methods ***/
  822. #define IDirectXVideoDecoderService_GetDecoderDeviceGuids(This,count,pGuids) (This)->lpVtbl->GetDecoderDeviceGuids(This,count,pGuids)
  823. #define IDirectXVideoDecoderService_GetDecoderRenderTargets(This,guid,pCount,pFormats) (This)->lpVtbl->GetDecoderRenderTargets(This,guid,pCount,pFormats)
  824. #define IDirectXVideoDecoderService_GetDecoderConfigurations(This,guid,pVideoDesc,pReserved,pCount,ppConfigs) (This)->lpVtbl->GetDecoderConfigurations(This,guid,pVideoDesc,pReserved,pCount,ppConfigs)
  825. #define IDirectXVideoDecoderService_CreateVideoDecoder(This,guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumSurfaces,ppDecode) (This)->lpVtbl->CreateVideoDecoder(This,guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumSurfaces,ppDecode)
  826. #else
  827. /*** IUnknown methods ***/
  828. static FORCEINLINE HRESULT IDirectXVideoDecoderService_QueryInterface(IDirectXVideoDecoderService* This,REFIID riid,void **ppvObject) {
  829. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  830. }
  831. static FORCEINLINE ULONG IDirectXVideoDecoderService_AddRef(IDirectXVideoDecoderService* This) {
  832. return This->lpVtbl->AddRef(This);
  833. }
  834. static FORCEINLINE ULONG IDirectXVideoDecoderService_Release(IDirectXVideoDecoderService* This) {
  835. return This->lpVtbl->Release(This);
  836. }
  837. /*** IDirectXVideoAccelerationService methods ***/
  838. static FORCEINLINE HRESULT IDirectXVideoDecoderService_CreateSurface(IDirectXVideoDecoderService* This,UINT width,UINT height,UINT backBuffers,D3DFORMAT format,D3DPOOL pool,DWORD usage,DWORD dxvaType,IDirect3DSurface9 **ppSurface,HANDLE *pSharedHandle) {
  839. return This->lpVtbl->CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle);
  840. }
  841. /*** IDirectXVideoDecoderService methods ***/
  842. static FORCEINLINE HRESULT IDirectXVideoDecoderService_GetDecoderDeviceGuids(IDirectXVideoDecoderService* This,UINT *count,GUID **pGuids) {
  843. return This->lpVtbl->GetDecoderDeviceGuids(This,count,pGuids);
  844. }
  845. static FORCEINLINE HRESULT IDirectXVideoDecoderService_GetDecoderRenderTargets(IDirectXVideoDecoderService* This,REFGUID guid,UINT *pCount,D3DFORMAT **pFormats) {
  846. return This->lpVtbl->GetDecoderRenderTargets(This,guid,pCount,pFormats);
  847. }
  848. static FORCEINLINE HRESULT IDirectXVideoDecoderService_GetDecoderConfigurations(IDirectXVideoDecoderService* This,REFGUID guid,const DXVA2_VideoDesc *pVideoDesc,void *pReserved,UINT *pCount,DXVA2_ConfigPictureDecode **ppConfigs) {
  849. return This->lpVtbl->GetDecoderConfigurations(This,guid,pVideoDesc,pReserved,pCount,ppConfigs);
  850. }
  851. static FORCEINLINE HRESULT IDirectXVideoDecoderService_CreateVideoDecoder(IDirectXVideoDecoderService* This,REFGUID guid,const DXVA2_VideoDesc *pVideoDesc,const DXVA2_ConfigPictureDecode *pConfig,IDirect3DSurface9 **ppDecoderRenderTargets,UINT NumSurfaces,IDirectXVideoDecoder **ppDecode) {
  852. return This->lpVtbl->CreateVideoDecoder(This,guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumSurfaces,ppDecode);
  853. }
  854. #endif
  855. #endif
  856. #endif
  857. #endif /* __IDirectXVideoDecoderService_INTERFACE_DEFINED__ */
  858. /*****************************************************************************
  859. * IDirectXVideoDecoder interface
  860. */
  861. #ifndef __IDirectXVideoDecoder_INTERFACE_DEFINED__
  862. #define __IDirectXVideoDecoder_INTERFACE_DEFINED__
  863. DEFINE_GUID(IID_IDirectXVideoDecoder, 0xf2b0810a, 0xfd00, 0x43c9, 0x91,0x8c, 0xdf,0x94,0xe2,0xd8,0xef,0x7d);
  864. #if defined(__cplusplus) && !defined(CINTERFACE)
  865. MIDL_INTERFACE("f2b0810a-fd00-43c9-918c-df94e2d8ef7d")
  866. IDirectXVideoDecoder : public IUnknown
  867. {
  868. virtual HRESULT STDMETHODCALLTYPE GetVideoDecoderService(
  869. IDirectXVideoDecoderService **ppService) = 0;
  870. virtual HRESULT STDMETHODCALLTYPE GetCreationParameters(
  871. GUID *pDeviceGuid,
  872. DXVA2_VideoDesc *pVideoDesc,
  873. DXVA2_ConfigPictureDecode *pConfig,
  874. IDirect3DSurface9 ***pDecoderRenderTargets,
  875. UINT *pNumSurfaces) = 0;
  876. virtual HRESULT STDMETHODCALLTYPE GetBuffer(
  877. UINT BufferType,
  878. void **ppBuffer,
  879. UINT *pBufferSize) = 0;
  880. virtual HRESULT STDMETHODCALLTYPE ReleaseBuffer(
  881. UINT BufferType) = 0;
  882. virtual HRESULT STDMETHODCALLTYPE BeginFrame(
  883. IDirect3DSurface9 *pRenderTarget,
  884. void *pvPVPData) = 0;
  885. virtual HRESULT STDMETHODCALLTYPE EndFrame(
  886. HANDLE *pHandleComplete) = 0;
  887. virtual HRESULT STDMETHODCALLTYPE Execute(
  888. const DXVA2_DecodeExecuteParams *pExecuteParams) = 0;
  889. };
  890. #ifdef __CRT_UUID_DECL
  891. __CRT_UUID_DECL(IDirectXVideoDecoder, 0xf2b0810a, 0xfd00, 0x43c9, 0x91,0x8c, 0xdf,0x94,0xe2,0xd8,0xef,0x7d)
  892. #endif
  893. #else
  894. typedef struct IDirectXVideoDecoderVtbl {
  895. BEGIN_INTERFACE
  896. /*** IUnknown methods ***/
  897. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  898. IDirectXVideoDecoder *This,
  899. REFIID riid,
  900. void **ppvObject);
  901. ULONG (STDMETHODCALLTYPE *AddRef)(
  902. IDirectXVideoDecoder *This);
  903. ULONG (STDMETHODCALLTYPE *Release)(
  904. IDirectXVideoDecoder *This);
  905. /*** IDirectXVideoDecoder methods ***/
  906. HRESULT (STDMETHODCALLTYPE *GetVideoDecoderService)(
  907. IDirectXVideoDecoder *This,
  908. IDirectXVideoDecoderService **ppService);
  909. HRESULT (STDMETHODCALLTYPE *GetCreationParameters)(
  910. IDirectXVideoDecoder *This,
  911. GUID *pDeviceGuid,
  912. DXVA2_VideoDesc *pVideoDesc,
  913. DXVA2_ConfigPictureDecode *pConfig,
  914. IDirect3DSurface9 ***pDecoderRenderTargets,
  915. UINT *pNumSurfaces);
  916. HRESULT (STDMETHODCALLTYPE *GetBuffer)(
  917. IDirectXVideoDecoder *This,
  918. UINT BufferType,
  919. void **ppBuffer,
  920. UINT *pBufferSize);
  921. HRESULT (STDMETHODCALLTYPE *ReleaseBuffer)(
  922. IDirectXVideoDecoder *This,
  923. UINT BufferType);
  924. HRESULT (STDMETHODCALLTYPE *BeginFrame)(
  925. IDirectXVideoDecoder *This,
  926. IDirect3DSurface9 *pRenderTarget,
  927. void *pvPVPData);
  928. HRESULT (STDMETHODCALLTYPE *EndFrame)(
  929. IDirectXVideoDecoder *This,
  930. HANDLE *pHandleComplete);
  931. HRESULT (STDMETHODCALLTYPE *Execute)(
  932. IDirectXVideoDecoder *This,
  933. const DXVA2_DecodeExecuteParams *pExecuteParams);
  934. END_INTERFACE
  935. } IDirectXVideoDecoderVtbl;
  936. interface IDirectXVideoDecoder {
  937. CONST_VTBL IDirectXVideoDecoderVtbl* lpVtbl;
  938. };
  939. #ifdef COBJMACROS
  940. #ifndef WIDL_C_INLINE_WRAPPERS
  941. /*** IUnknown methods ***/
  942. #define IDirectXVideoDecoder_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  943. #define IDirectXVideoDecoder_AddRef(This) (This)->lpVtbl->AddRef(This)
  944. #define IDirectXVideoDecoder_Release(This) (This)->lpVtbl->Release(This)
  945. /*** IDirectXVideoDecoder methods ***/
  946. #define IDirectXVideoDecoder_GetVideoDecoderService(This,ppService) (This)->lpVtbl->GetVideoDecoderService(This,ppService)
  947. #define IDirectXVideoDecoder_GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces) (This)->lpVtbl->GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces)
  948. #define IDirectXVideoDecoder_GetBuffer(This,BufferType,ppBuffer,pBufferSize) (This)->lpVtbl->GetBuffer(This,BufferType,ppBuffer,pBufferSize)
  949. #define IDirectXVideoDecoder_ReleaseBuffer(This,BufferType) (This)->lpVtbl->ReleaseBuffer(This,BufferType)
  950. #define IDirectXVideoDecoder_BeginFrame(This,pRenderTarget,pvPVPData) (This)->lpVtbl->BeginFrame(This,pRenderTarget,pvPVPData)
  951. #define IDirectXVideoDecoder_EndFrame(This,pHandleComplete) (This)->lpVtbl->EndFrame(This,pHandleComplete)
  952. #define IDirectXVideoDecoder_Execute(This,pExecuteParams) (This)->lpVtbl->Execute(This,pExecuteParams)
  953. #else
  954. /*** IUnknown methods ***/
  955. static FORCEINLINE HRESULT IDirectXVideoDecoder_QueryInterface(IDirectXVideoDecoder* This,REFIID riid,void **ppvObject) {
  956. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  957. }
  958. static FORCEINLINE ULONG IDirectXVideoDecoder_AddRef(IDirectXVideoDecoder* This) {
  959. return This->lpVtbl->AddRef(This);
  960. }
  961. static FORCEINLINE ULONG IDirectXVideoDecoder_Release(IDirectXVideoDecoder* This) {
  962. return This->lpVtbl->Release(This);
  963. }
  964. /*** IDirectXVideoDecoder methods ***/
  965. static FORCEINLINE HRESULT IDirectXVideoDecoder_GetVideoDecoderService(IDirectXVideoDecoder* This,IDirectXVideoDecoderService **ppService) {
  966. return This->lpVtbl->GetVideoDecoderService(This,ppService);
  967. }
  968. static FORCEINLINE HRESULT IDirectXVideoDecoder_GetCreationParameters(IDirectXVideoDecoder* This,GUID *pDeviceGuid,DXVA2_VideoDesc *pVideoDesc,DXVA2_ConfigPictureDecode *pConfig,IDirect3DSurface9 ***pDecoderRenderTargets,UINT *pNumSurfaces) {
  969. return This->lpVtbl->GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces);
  970. }
  971. static FORCEINLINE HRESULT IDirectXVideoDecoder_GetBuffer(IDirectXVideoDecoder* This,UINT BufferType,void **ppBuffer,UINT *pBufferSize) {
  972. return This->lpVtbl->GetBuffer(This,BufferType,ppBuffer,pBufferSize);
  973. }
  974. static FORCEINLINE HRESULT IDirectXVideoDecoder_ReleaseBuffer(IDirectXVideoDecoder* This,UINT BufferType) {
  975. return This->lpVtbl->ReleaseBuffer(This,BufferType);
  976. }
  977. static FORCEINLINE HRESULT IDirectXVideoDecoder_BeginFrame(IDirectXVideoDecoder* This,IDirect3DSurface9 *pRenderTarget,void *pvPVPData) {
  978. return This->lpVtbl->BeginFrame(This,pRenderTarget,pvPVPData);
  979. }
  980. static FORCEINLINE HRESULT IDirectXVideoDecoder_EndFrame(IDirectXVideoDecoder* This,HANDLE *pHandleComplete) {
  981. return This->lpVtbl->EndFrame(This,pHandleComplete);
  982. }
  983. static FORCEINLINE HRESULT IDirectXVideoDecoder_Execute(IDirectXVideoDecoder* This,const DXVA2_DecodeExecuteParams *pExecuteParams) {
  984. return This->lpVtbl->Execute(This,pExecuteParams);
  985. }
  986. #endif
  987. #endif
  988. #endif
  989. #endif /* __IDirectXVideoDecoder_INTERFACE_DEFINED__ */
  990. /*****************************************************************************
  991. * IDirectXVideoProcessorService interface
  992. */
  993. #ifndef __IDirectXVideoProcessorService_INTERFACE_DEFINED__
  994. #define __IDirectXVideoProcessorService_INTERFACE_DEFINED__
  995. DEFINE_GUID(IID_IDirectXVideoProcessorService, 0xfc51a552, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02);
  996. #if defined(__cplusplus) && !defined(CINTERFACE)
  997. MIDL_INTERFACE("fc51a552-d5e7-11d9-af55-00054e43ff02")
  998. IDirectXVideoProcessorService : public IDirectXVideoAccelerationService
  999. {
  1000. virtual HRESULT STDMETHODCALLTYPE RegisterVideoProcessorSoftwareDevice(
  1001. void *pCallbacks) = 0;
  1002. virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorDeviceGuids(
  1003. const DXVA2_VideoDesc *pVideoDesc,
  1004. UINT *pCount,
  1005. GUID **pGuids) = 0;
  1006. virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorRenderTargets(
  1007. REFGUID VideoProcDeviceGuid,
  1008. const DXVA2_VideoDesc *pVideoDesc,
  1009. UINT *pCount,
  1010. D3DFORMAT **pFormats) = 0;
  1011. virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorSubStreamFormats(
  1012. REFGUID VideoProcDeviceGuid,
  1013. const DXVA2_VideoDesc *pVideoDesc,
  1014. D3DFORMAT RenderTargetFormat,
  1015. UINT *pCount,
  1016. D3DFORMAT **pFormats) = 0;
  1017. virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorCaps(
  1018. REFGUID VideoProcDeviceGuid,
  1019. const DXVA2_VideoDesc *pVideoDesc,
  1020. D3DFORMAT RenderTargetFormat,
  1021. DXVA2_VideoProcessorCaps *pCaps) = 0;
  1022. virtual HRESULT STDMETHODCALLTYPE GetProcAmpRange(
  1023. REFGUID VideoProcDeviceGuid,
  1024. const DXVA2_VideoDesc *pVideoDesc,
  1025. D3DFORMAT RenderTargetFormat,
  1026. UINT ProcAmpCap,
  1027. DXVA2_ValueRange *pRange) = 0;
  1028. virtual HRESULT STDMETHODCALLTYPE GetFilterPropertyRange(
  1029. REFGUID VideoProcDeviceGuid,
  1030. const DXVA2_VideoDesc *pVideoDesc,
  1031. D3DFORMAT renderTargetFormat,
  1032. UINT FilterSetting,
  1033. DXVA2_ValueRange *pRange) = 0;
  1034. virtual HRESULT STDMETHODCALLTYPE CreateVideoProcessor(
  1035. REFGUID VideoProcDeviceGuid,
  1036. const DXVA2_VideoDesc *pVideoDesc,
  1037. D3DFORMAT RenderTargetFormat,
  1038. UINT MaxNumSubStreams,
  1039. IDirectXVideoProcessor **ppVidProcess) = 0;
  1040. };
  1041. #ifdef __CRT_UUID_DECL
  1042. __CRT_UUID_DECL(IDirectXVideoProcessorService, 0xfc51a552, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02)
  1043. #endif
  1044. #else
  1045. typedef struct IDirectXVideoProcessorServiceVtbl {
  1046. BEGIN_INTERFACE
  1047. /*** IUnknown methods ***/
  1048. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  1049. IDirectXVideoProcessorService *This,
  1050. REFIID riid,
  1051. void **ppvObject);
  1052. ULONG (STDMETHODCALLTYPE *AddRef)(
  1053. IDirectXVideoProcessorService *This);
  1054. ULONG (STDMETHODCALLTYPE *Release)(
  1055. IDirectXVideoProcessorService *This);
  1056. /*** IDirectXVideoAccelerationService methods ***/
  1057. HRESULT (STDMETHODCALLTYPE *CreateSurface)(
  1058. IDirectXVideoProcessorService *This,
  1059. UINT width,
  1060. UINT height,
  1061. UINT backBuffers,
  1062. D3DFORMAT format,
  1063. D3DPOOL pool,
  1064. DWORD usage,
  1065. DWORD dxvaType,
  1066. IDirect3DSurface9 **ppSurface,
  1067. HANDLE *pSharedHandle);
  1068. /*** IDirectXVideoProcessorService methods ***/
  1069. HRESULT (STDMETHODCALLTYPE *RegisterVideoProcessorSoftwareDevice)(
  1070. IDirectXVideoProcessorService *This,
  1071. void *pCallbacks);
  1072. HRESULT (STDMETHODCALLTYPE *GetVideoProcessorDeviceGuids)(
  1073. IDirectXVideoProcessorService *This,
  1074. const DXVA2_VideoDesc *pVideoDesc,
  1075. UINT *pCount,
  1076. GUID **pGuids);
  1077. HRESULT (STDMETHODCALLTYPE *GetVideoProcessorRenderTargets)(
  1078. IDirectXVideoProcessorService *This,
  1079. REFGUID VideoProcDeviceGuid,
  1080. const DXVA2_VideoDesc *pVideoDesc,
  1081. UINT *pCount,
  1082. D3DFORMAT **pFormats);
  1083. HRESULT (STDMETHODCALLTYPE *GetVideoProcessorSubStreamFormats)(
  1084. IDirectXVideoProcessorService *This,
  1085. REFGUID VideoProcDeviceGuid,
  1086. const DXVA2_VideoDesc *pVideoDesc,
  1087. D3DFORMAT RenderTargetFormat,
  1088. UINT *pCount,
  1089. D3DFORMAT **pFormats);
  1090. HRESULT (STDMETHODCALLTYPE *GetVideoProcessorCaps)(
  1091. IDirectXVideoProcessorService *This,
  1092. REFGUID VideoProcDeviceGuid,
  1093. const DXVA2_VideoDesc *pVideoDesc,
  1094. D3DFORMAT RenderTargetFormat,
  1095. DXVA2_VideoProcessorCaps *pCaps);
  1096. HRESULT (STDMETHODCALLTYPE *GetProcAmpRange)(
  1097. IDirectXVideoProcessorService *This,
  1098. REFGUID VideoProcDeviceGuid,
  1099. const DXVA2_VideoDesc *pVideoDesc,
  1100. D3DFORMAT RenderTargetFormat,
  1101. UINT ProcAmpCap,
  1102. DXVA2_ValueRange *pRange);
  1103. HRESULT (STDMETHODCALLTYPE *GetFilterPropertyRange)(
  1104. IDirectXVideoProcessorService *This,
  1105. REFGUID VideoProcDeviceGuid,
  1106. const DXVA2_VideoDesc *pVideoDesc,
  1107. D3DFORMAT renderTargetFormat,
  1108. UINT FilterSetting,
  1109. DXVA2_ValueRange *pRange);
  1110. HRESULT (STDMETHODCALLTYPE *CreateVideoProcessor)(
  1111. IDirectXVideoProcessorService *This,
  1112. REFGUID VideoProcDeviceGuid,
  1113. const DXVA2_VideoDesc *pVideoDesc,
  1114. D3DFORMAT RenderTargetFormat,
  1115. UINT MaxNumSubStreams,
  1116. IDirectXVideoProcessor **ppVidProcess);
  1117. END_INTERFACE
  1118. } IDirectXVideoProcessorServiceVtbl;
  1119. interface IDirectXVideoProcessorService {
  1120. CONST_VTBL IDirectXVideoProcessorServiceVtbl* lpVtbl;
  1121. };
  1122. #ifdef COBJMACROS
  1123. #ifndef WIDL_C_INLINE_WRAPPERS
  1124. /*** IUnknown methods ***/
  1125. #define IDirectXVideoProcessorService_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  1126. #define IDirectXVideoProcessorService_AddRef(This) (This)->lpVtbl->AddRef(This)
  1127. #define IDirectXVideoProcessorService_Release(This) (This)->lpVtbl->Release(This)
  1128. /*** IDirectXVideoAccelerationService methods ***/
  1129. #define IDirectXVideoProcessorService_CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle) (This)->lpVtbl->CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle)
  1130. /*** IDirectXVideoProcessorService methods ***/
  1131. #define IDirectXVideoProcessorService_RegisterVideoProcessorSoftwareDevice(This,pCallbacks) (This)->lpVtbl->RegisterVideoProcessorSoftwareDevice(This,pCallbacks)
  1132. #define IDirectXVideoProcessorService_GetVideoProcessorDeviceGuids(This,pVideoDesc,pCount,pGuids) (This)->lpVtbl->GetVideoProcessorDeviceGuids(This,pVideoDesc,pCount,pGuids)
  1133. #define IDirectXVideoProcessorService_GetVideoProcessorRenderTargets(This,VideoProcDeviceGuid,pVideoDesc,pCount,pFormats) (This)->lpVtbl->GetVideoProcessorRenderTargets(This,VideoProcDeviceGuid,pVideoDesc,pCount,pFormats)
  1134. #define IDirectXVideoProcessorService_GetVideoProcessorSubStreamFormats(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCount,pFormats) (This)->lpVtbl->GetVideoProcessorSubStreamFormats(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCount,pFormats)
  1135. #define IDirectXVideoProcessorService_GetVideoProcessorCaps(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCaps) (This)->lpVtbl->GetVideoProcessorCaps(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCaps)
  1136. #define IDirectXVideoProcessorService_GetProcAmpRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,ProcAmpCap,pRange) (This)->lpVtbl->GetProcAmpRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,ProcAmpCap,pRange)
  1137. #define IDirectXVideoProcessorService_GetFilterPropertyRange(This,VideoProcDeviceGuid,pVideoDesc,renderTargetFormat,FilterSetting,pRange) (This)->lpVtbl->GetFilterPropertyRange(This,VideoProcDeviceGuid,pVideoDesc,renderTargetFormat,FilterSetting,pRange)
  1138. #define IDirectXVideoProcessorService_CreateVideoProcessor(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,MaxNumSubStreams,ppVidProcess) (This)->lpVtbl->CreateVideoProcessor(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,MaxNumSubStreams,ppVidProcess)
  1139. #else
  1140. /*** IUnknown methods ***/
  1141. static FORCEINLINE HRESULT IDirectXVideoProcessorService_QueryInterface(IDirectXVideoProcessorService* This,REFIID riid,void **ppvObject) {
  1142. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  1143. }
  1144. static FORCEINLINE ULONG IDirectXVideoProcessorService_AddRef(IDirectXVideoProcessorService* This) {
  1145. return This->lpVtbl->AddRef(This);
  1146. }
  1147. static FORCEINLINE ULONG IDirectXVideoProcessorService_Release(IDirectXVideoProcessorService* This) {
  1148. return This->lpVtbl->Release(This);
  1149. }
  1150. /*** IDirectXVideoAccelerationService methods ***/
  1151. static FORCEINLINE HRESULT IDirectXVideoProcessorService_CreateSurface(IDirectXVideoProcessorService* This,UINT width,UINT height,UINT backBuffers,D3DFORMAT format,D3DPOOL pool,DWORD usage,DWORD dxvaType,IDirect3DSurface9 **ppSurface,HANDLE *pSharedHandle) {
  1152. return This->lpVtbl->CreateSurface(This,width,height,backBuffers,format,pool,usage,dxvaType,ppSurface,pSharedHandle);
  1153. }
  1154. /*** IDirectXVideoProcessorService methods ***/
  1155. static FORCEINLINE HRESULT IDirectXVideoProcessorService_RegisterVideoProcessorSoftwareDevice(IDirectXVideoProcessorService* This,void *pCallbacks) {
  1156. return This->lpVtbl->RegisterVideoProcessorSoftwareDevice(This,pCallbacks);
  1157. }
  1158. static FORCEINLINE HRESULT IDirectXVideoProcessorService_GetVideoProcessorDeviceGuids(IDirectXVideoProcessorService* This,const DXVA2_VideoDesc *pVideoDesc,UINT *pCount,GUID **pGuids) {
  1159. return This->lpVtbl->GetVideoProcessorDeviceGuids(This,pVideoDesc,pCount,pGuids);
  1160. }
  1161. static FORCEINLINE HRESULT IDirectXVideoProcessorService_GetVideoProcessorRenderTargets(IDirectXVideoProcessorService* This,REFGUID VideoProcDeviceGuid,const DXVA2_VideoDesc *pVideoDesc,UINT *pCount,D3DFORMAT **pFormats) {
  1162. return This->lpVtbl->GetVideoProcessorRenderTargets(This,VideoProcDeviceGuid,pVideoDesc,pCount,pFormats);
  1163. }
  1164. static FORCEINLINE HRESULT IDirectXVideoProcessorService_GetVideoProcessorSubStreamFormats(IDirectXVideoProcessorService* This,REFGUID VideoProcDeviceGuid,const DXVA2_VideoDesc *pVideoDesc,D3DFORMAT RenderTargetFormat,UINT *pCount,D3DFORMAT **pFormats) {
  1165. return This->lpVtbl->GetVideoProcessorSubStreamFormats(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCount,pFormats);
  1166. }
  1167. static FORCEINLINE HRESULT IDirectXVideoProcessorService_GetVideoProcessorCaps(IDirectXVideoProcessorService* This,REFGUID VideoProcDeviceGuid,const DXVA2_VideoDesc *pVideoDesc,D3DFORMAT RenderTargetFormat,DXVA2_VideoProcessorCaps *pCaps) {
  1168. return This->lpVtbl->GetVideoProcessorCaps(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCaps);
  1169. }
  1170. static FORCEINLINE HRESULT IDirectXVideoProcessorService_GetProcAmpRange(IDirectXVideoProcessorService* This,REFGUID VideoProcDeviceGuid,const DXVA2_VideoDesc *pVideoDesc,D3DFORMAT RenderTargetFormat,UINT ProcAmpCap,DXVA2_ValueRange *pRange) {
  1171. return This->lpVtbl->GetProcAmpRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,ProcAmpCap,pRange);
  1172. }
  1173. static FORCEINLINE HRESULT IDirectXVideoProcessorService_GetFilterPropertyRange(IDirectXVideoProcessorService* This,REFGUID VideoProcDeviceGuid,const DXVA2_VideoDesc *pVideoDesc,D3DFORMAT renderTargetFormat,UINT FilterSetting,DXVA2_ValueRange *pRange) {
  1174. return This->lpVtbl->GetFilterPropertyRange(This,VideoProcDeviceGuid,pVideoDesc,renderTargetFormat,FilterSetting,pRange);
  1175. }
  1176. static FORCEINLINE HRESULT IDirectXVideoProcessorService_CreateVideoProcessor(IDirectXVideoProcessorService* This,REFGUID VideoProcDeviceGuid,const DXVA2_VideoDesc *pVideoDesc,D3DFORMAT RenderTargetFormat,UINT MaxNumSubStreams,IDirectXVideoProcessor **ppVidProcess) {
  1177. return This->lpVtbl->CreateVideoProcessor(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,MaxNumSubStreams,ppVidProcess);
  1178. }
  1179. #endif
  1180. #endif
  1181. #endif
  1182. #endif /* __IDirectXVideoProcessorService_INTERFACE_DEFINED__ */
  1183. /*****************************************************************************
  1184. * IDirectXVideoProcessor interface
  1185. */
  1186. #ifndef __IDirectXVideoProcessor_INTERFACE_DEFINED__
  1187. #define __IDirectXVideoProcessor_INTERFACE_DEFINED__
  1188. DEFINE_GUID(IID_IDirectXVideoProcessor, 0x8c3a39f0, 0x916e, 0x4690, 0x80,0x4f, 0x4c,0x80,0x01,0x35,0x5d,0x25);
  1189. #if defined(__cplusplus) && !defined(CINTERFACE)
  1190. MIDL_INTERFACE("8c3a39f0-916e-4690-804f-4c8001355d25")
  1191. IDirectXVideoProcessor : public IUnknown
  1192. {
  1193. virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorService(
  1194. IDirectXVideoProcessorService **ppService) = 0;
  1195. virtual HRESULT STDMETHODCALLTYPE GetCreationParameters(
  1196. GUID *pDeviceGuid,
  1197. DXVA2_VideoDesc *pVideoDesc,
  1198. D3DFORMAT *pRenderTargetFormat,
  1199. UINT *pMaxNumSubStreams) = 0;
  1200. virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorCaps(
  1201. DXVA2_VideoProcessorCaps *pCaps) = 0;
  1202. virtual HRESULT STDMETHODCALLTYPE GetProcAmpRange(
  1203. UINT ProcAmpCap,
  1204. DXVA2_ValueRange *pRange) = 0;
  1205. virtual HRESULT STDMETHODCALLTYPE GetFilterPropertyRange(
  1206. UINT FilterSetting,
  1207. DXVA2_ValueRange *pRange) = 0;
  1208. virtual HRESULT STDMETHODCALLTYPE VideoProcessBlt(
  1209. IDirect3DSurface9 *pRenderTarget,
  1210. const DXVA2_VideoProcessBltParams *pBltParams,
  1211. const DXVA2_VideoSample *pSamples,
  1212. UINT NumSamples,
  1213. HANDLE *pHandleComplete) = 0;
  1214. };
  1215. #ifdef __CRT_UUID_DECL
  1216. __CRT_UUID_DECL(IDirectXVideoProcessor, 0x8c3a39f0, 0x916e, 0x4690, 0x80,0x4f, 0x4c,0x80,0x01,0x35,0x5d,0x25)
  1217. #endif
  1218. #else
  1219. typedef struct IDirectXVideoProcessorVtbl {
  1220. BEGIN_INTERFACE
  1221. /*** IUnknown methods ***/
  1222. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  1223. IDirectXVideoProcessor *This,
  1224. REFIID riid,
  1225. void **ppvObject);
  1226. ULONG (STDMETHODCALLTYPE *AddRef)(
  1227. IDirectXVideoProcessor *This);
  1228. ULONG (STDMETHODCALLTYPE *Release)(
  1229. IDirectXVideoProcessor *This);
  1230. /*** IDirectXVideoProcessor methods ***/
  1231. HRESULT (STDMETHODCALLTYPE *GetVideoProcessorService)(
  1232. IDirectXVideoProcessor *This,
  1233. IDirectXVideoProcessorService **ppService);
  1234. HRESULT (STDMETHODCALLTYPE *GetCreationParameters)(
  1235. IDirectXVideoProcessor *This,
  1236. GUID *pDeviceGuid,
  1237. DXVA2_VideoDesc *pVideoDesc,
  1238. D3DFORMAT *pRenderTargetFormat,
  1239. UINT *pMaxNumSubStreams);
  1240. HRESULT (STDMETHODCALLTYPE *GetVideoProcessorCaps)(
  1241. IDirectXVideoProcessor *This,
  1242. DXVA2_VideoProcessorCaps *pCaps);
  1243. HRESULT (STDMETHODCALLTYPE *GetProcAmpRange)(
  1244. IDirectXVideoProcessor *This,
  1245. UINT ProcAmpCap,
  1246. DXVA2_ValueRange *pRange);
  1247. HRESULT (STDMETHODCALLTYPE *GetFilterPropertyRange)(
  1248. IDirectXVideoProcessor *This,
  1249. UINT FilterSetting,
  1250. DXVA2_ValueRange *pRange);
  1251. HRESULT (STDMETHODCALLTYPE *VideoProcessBlt)(
  1252. IDirectXVideoProcessor *This,
  1253. IDirect3DSurface9 *pRenderTarget,
  1254. const DXVA2_VideoProcessBltParams *pBltParams,
  1255. const DXVA2_VideoSample *pSamples,
  1256. UINT NumSamples,
  1257. HANDLE *pHandleComplete);
  1258. END_INTERFACE
  1259. } IDirectXVideoProcessorVtbl;
  1260. interface IDirectXVideoProcessor {
  1261. CONST_VTBL IDirectXVideoProcessorVtbl* lpVtbl;
  1262. };
  1263. #ifdef COBJMACROS
  1264. #ifndef WIDL_C_INLINE_WRAPPERS
  1265. /*** IUnknown methods ***/
  1266. #define IDirectXVideoProcessor_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  1267. #define IDirectXVideoProcessor_AddRef(This) (This)->lpVtbl->AddRef(This)
  1268. #define IDirectXVideoProcessor_Release(This) (This)->lpVtbl->Release(This)
  1269. /*** IDirectXVideoProcessor methods ***/
  1270. #define IDirectXVideoProcessor_GetVideoProcessorService(This,ppService) (This)->lpVtbl->GetVideoProcessorService(This,ppService)
  1271. #define IDirectXVideoProcessor_GetCreationParameters(This,pDeviceGuid,pVideoDesc,pRenderTargetFormat,pMaxNumSubStreams) (This)->lpVtbl->GetCreationParameters(This,pDeviceGuid,pVideoDesc,pRenderTargetFormat,pMaxNumSubStreams)
  1272. #define IDirectXVideoProcessor_GetVideoProcessorCaps(This,pCaps) (This)->lpVtbl->GetVideoProcessorCaps(This,pCaps)
  1273. #define IDirectXVideoProcessor_GetProcAmpRange(This,ProcAmpCap,pRange) (This)->lpVtbl->GetProcAmpRange(This,ProcAmpCap,pRange)
  1274. #define IDirectXVideoProcessor_GetFilterPropertyRange(This,FilterSetting,pRange) (This)->lpVtbl->GetFilterPropertyRange(This,FilterSetting,pRange)
  1275. #define IDirectXVideoProcessor_VideoProcessBlt(This,pRenderTarget,pBltParams,pSamples,NumSamples,pHandleComplete) (This)->lpVtbl->VideoProcessBlt(This,pRenderTarget,pBltParams,pSamples,NumSamples,pHandleComplete)
  1276. #else
  1277. /*** IUnknown methods ***/
  1278. static FORCEINLINE HRESULT IDirectXVideoProcessor_QueryInterface(IDirectXVideoProcessor* This,REFIID riid,void **ppvObject) {
  1279. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  1280. }
  1281. static FORCEINLINE ULONG IDirectXVideoProcessor_AddRef(IDirectXVideoProcessor* This) {
  1282. return This->lpVtbl->AddRef(This);
  1283. }
  1284. static FORCEINLINE ULONG IDirectXVideoProcessor_Release(IDirectXVideoProcessor* This) {
  1285. return This->lpVtbl->Release(This);
  1286. }
  1287. /*** IDirectXVideoProcessor methods ***/
  1288. static FORCEINLINE HRESULT IDirectXVideoProcessor_GetVideoProcessorService(IDirectXVideoProcessor* This,IDirectXVideoProcessorService **ppService) {
  1289. return This->lpVtbl->GetVideoProcessorService(This,ppService);
  1290. }
  1291. static FORCEINLINE HRESULT IDirectXVideoProcessor_GetCreationParameters(IDirectXVideoProcessor* This,GUID *pDeviceGuid,DXVA2_VideoDesc *pVideoDesc,D3DFORMAT *pRenderTargetFormat,UINT *pMaxNumSubStreams) {
  1292. return This->lpVtbl->GetCreationParameters(This,pDeviceGuid,pVideoDesc,pRenderTargetFormat,pMaxNumSubStreams);
  1293. }
  1294. static FORCEINLINE HRESULT IDirectXVideoProcessor_GetVideoProcessorCaps(IDirectXVideoProcessor* This,DXVA2_VideoProcessorCaps *pCaps) {
  1295. return This->lpVtbl->GetVideoProcessorCaps(This,pCaps);
  1296. }
  1297. static FORCEINLINE HRESULT IDirectXVideoProcessor_GetProcAmpRange(IDirectXVideoProcessor* This,UINT ProcAmpCap,DXVA2_ValueRange *pRange) {
  1298. return This->lpVtbl->GetProcAmpRange(This,ProcAmpCap,pRange);
  1299. }
  1300. static FORCEINLINE HRESULT IDirectXVideoProcessor_GetFilterPropertyRange(IDirectXVideoProcessor* This,UINT FilterSetting,DXVA2_ValueRange *pRange) {
  1301. return This->lpVtbl->GetFilterPropertyRange(This,FilterSetting,pRange);
  1302. }
  1303. static FORCEINLINE HRESULT IDirectXVideoProcessor_VideoProcessBlt(IDirectXVideoProcessor* This,IDirect3DSurface9 *pRenderTarget,const DXVA2_VideoProcessBltParams *pBltParams,const DXVA2_VideoSample *pSamples,UINT NumSamples,HANDLE *pHandleComplete) {
  1304. return This->lpVtbl->VideoProcessBlt(This,pRenderTarget,pBltParams,pSamples,NumSamples,pHandleComplete);
  1305. }
  1306. #endif
  1307. #endif
  1308. #endif
  1309. #endif /* __IDirectXVideoProcessor_INTERFACE_DEFINED__ */
  1310. /*****************************************************************************
  1311. * IDirectXVideoMemoryConfiguration interface
  1312. */
  1313. #ifndef __IDirectXVideoMemoryConfiguration_INTERFACE_DEFINED__
  1314. #define __IDirectXVideoMemoryConfiguration_INTERFACE_DEFINED__
  1315. DEFINE_GUID(IID_IDirectXVideoMemoryConfiguration, 0xb7f916dd, 0xdb3b, 0x49c1, 0x84,0xd7, 0xe4,0x5e,0xf9,0x9e,0xc7,0x26);
  1316. #if defined(__cplusplus) && !defined(CINTERFACE)
  1317. MIDL_INTERFACE("b7f916dd-db3b-49c1-84d7-e45ef99ec726")
  1318. IDirectXVideoMemoryConfiguration : public IUnknown
  1319. {
  1320. virtual HRESULT STDMETHODCALLTYPE GetAvailableSurfaceTypeByIndex(
  1321. DWORD wTypeIndex,
  1322. DXVA2_SurfaceType *pdwType) = 0;
  1323. virtual HRESULT STDMETHODCALLTYPE SetSurfaceType(
  1324. DXVA2_SurfaceType dwType) = 0;
  1325. };
  1326. #ifdef __CRT_UUID_DECL
  1327. __CRT_UUID_DECL(IDirectXVideoMemoryConfiguration, 0xb7f916dd, 0xdb3b, 0x49c1, 0x84,0xd7, 0xe4,0x5e,0xf9,0x9e,0xc7,0x26)
  1328. #endif
  1329. #else
  1330. typedef struct IDirectXVideoMemoryConfigurationVtbl {
  1331. BEGIN_INTERFACE
  1332. /*** IUnknown methods ***/
  1333. HRESULT (STDMETHODCALLTYPE *QueryInterface)(
  1334. IDirectXVideoMemoryConfiguration *This,
  1335. REFIID riid,
  1336. void **ppvObject);
  1337. ULONG (STDMETHODCALLTYPE *AddRef)(
  1338. IDirectXVideoMemoryConfiguration *This);
  1339. ULONG (STDMETHODCALLTYPE *Release)(
  1340. IDirectXVideoMemoryConfiguration *This);
  1341. /*** IDirectXVideoMemoryConfiguration methods ***/
  1342. HRESULT (STDMETHODCALLTYPE *GetAvailableSurfaceTypeByIndex)(
  1343. IDirectXVideoMemoryConfiguration *This,
  1344. DWORD wTypeIndex,
  1345. DXVA2_SurfaceType *pdwType);
  1346. HRESULT (STDMETHODCALLTYPE *SetSurfaceType)(
  1347. IDirectXVideoMemoryConfiguration *This,
  1348. DXVA2_SurfaceType dwType);
  1349. END_INTERFACE
  1350. } IDirectXVideoMemoryConfigurationVtbl;
  1351. interface IDirectXVideoMemoryConfiguration {
  1352. CONST_VTBL IDirectXVideoMemoryConfigurationVtbl* lpVtbl;
  1353. };
  1354. #ifdef COBJMACROS
  1355. #ifndef WIDL_C_INLINE_WRAPPERS
  1356. /*** IUnknown methods ***/
  1357. #define IDirectXVideoMemoryConfiguration_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
  1358. #define IDirectXVideoMemoryConfiguration_AddRef(This) (This)->lpVtbl->AddRef(This)
  1359. #define IDirectXVideoMemoryConfiguration_Release(This) (This)->lpVtbl->Release(This)
  1360. /*** IDirectXVideoMemoryConfiguration methods ***/
  1361. #define IDirectXVideoMemoryConfiguration_GetAvailableSurfaceTypeByIndex(This,wTypeIndex,pdwType) (This)->lpVtbl->GetAvailableSurfaceTypeByIndex(This,wTypeIndex,pdwType)
  1362. #define IDirectXVideoMemoryConfiguration_SetSurfaceType(This,dwType) (This)->lpVtbl->SetSurfaceType(This,dwType)
  1363. #else
  1364. /*** IUnknown methods ***/
  1365. static FORCEINLINE HRESULT IDirectXVideoMemoryConfiguration_QueryInterface(IDirectXVideoMemoryConfiguration* This,REFIID riid,void **ppvObject) {
  1366. return This->lpVtbl->QueryInterface(This,riid,ppvObject);
  1367. }
  1368. static FORCEINLINE ULONG IDirectXVideoMemoryConfiguration_AddRef(IDirectXVideoMemoryConfiguration* This) {
  1369. return This->lpVtbl->AddRef(This);
  1370. }
  1371. static FORCEINLINE ULONG IDirectXVideoMemoryConfiguration_Release(IDirectXVideoMemoryConfiguration* This) {
  1372. return This->lpVtbl->Release(This);
  1373. }
  1374. /*** IDirectXVideoMemoryConfiguration methods ***/
  1375. static FORCEINLINE HRESULT IDirectXVideoMemoryConfiguration_GetAvailableSurfaceTypeByIndex(IDirectXVideoMemoryConfiguration* This,DWORD wTypeIndex,DXVA2_SurfaceType *pdwType) {
  1376. return This->lpVtbl->GetAvailableSurfaceTypeByIndex(This,wTypeIndex,pdwType);
  1377. }
  1378. static FORCEINLINE HRESULT IDirectXVideoMemoryConfiguration_SetSurfaceType(IDirectXVideoMemoryConfiguration* This,DXVA2_SurfaceType dwType) {
  1379. return This->lpVtbl->SetSurfaceType(This,dwType);
  1380. }
  1381. #endif
  1382. #endif
  1383. #endif
  1384. #endif /* __IDirectXVideoMemoryConfiguration_INTERFACE_DEFINED__ */
  1385. HRESULT WINAPI DXVA2CreateDirect3DDeviceManager9(UINT *pResetToken,IDirect3DDeviceManager9 **ppDXVAManager);
  1386. HRESULT WINAPI DXVA2CreateVideoService(IDirect3DDevice9 *pDD,REFIID riid,void **ppService);
  1387. #endif
  1388. static inline DXVA2_Fixed32 DXVA2_Fixed32OpaqueAlpha(void) {
  1389. DXVA2_Fixed32 f32;
  1390. f32.ll = 0 + (1 << 16);
  1391. return f32;
  1392. }
  1393. static inline DXVA2_Fixed32 DXVA2_Fixed32TransparentAlpha(void) {
  1394. DXVA2_Fixed32 f32;
  1395. f32.ll = 0;
  1396. return f32;
  1397. }
  1398. static inline float DXVA2FixedToFloat(DXVA2_Fixed32 f32) {
  1399. return (float)f32.Value + (float)f32.Fraction / (1 << 16);
  1400. }
  1401. static inline DXVA2_Fixed32 DXVA2FloatToFixed(float f) {
  1402. DXVA2_Fixed32 f32;
  1403. f32.Value = ((ULONG) (f * (1 << 16))) >> 16;
  1404. f32.Fraction = ((ULONG) (f * (1 << 16))) & 0xFFFF;
  1405. return f32;
  1406. }
  1407. /* Begin additional prototypes for all interfaces */
  1408. /* End additional prototypes */
  1409. #ifdef __cplusplus
  1410. }
  1411. #endif
  1412. #endif /* __dxva2api_h__ */