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

187 lines
5.5 KiB

  1. // Copyright (c) 1995 - 1997 Microsoft Corporation. All Rights Reserved.
  2. #include <mpegtype.h> // IMpegAudioDecoder
  3. typedef struct {
  4. LONG lWidth; // Native Width in pixels
  5. LONG lHeight; // Native Height in pixels
  6. LONG lvbv; // vbv
  7. REFERENCE_TIME PictureTime; // Time per picture in 100ns units
  8. LONG lTimePerFrame; // Time per picture in MPEG units
  9. LONG dwBitRate; // Bits per second
  10. LONG lXPelsPerMeter; // Pel aspect ratio
  11. LONG lYPelsPerMeter; // Pel aspect ratio
  12. DWORD dwStartTimeCode; // First GOP time code (or -1)
  13. LONG lActualHeaderLen; // Length of valid bytes in raw seq hdr
  14. BYTE RawHeader[140]; // The real sequence header
  15. } SEQHDR_INFO;
  16. #define DECODE_I 0x0001L
  17. #define DECODE_IP 0x0003L
  18. #define DECODE_IPB 0x0007L // Normal B Frame
  19. #define DECODE_IPB1 0x000FL // Decode 1 out of 4 B frames
  20. #define DECODE_IPB2 0x0010L // Decode 2 out of 4 B frames
  21. #define DECODE_IPB3 0x0020L // Decode 3 out of 4 B frames
  22. #define DECODE_DIS 0x0040L // No Decode, Convert only
  23. #define DECODE_BQUAL_HIGH 0x00000000L // Normal B Decode
  24. #define DECODE_BQUAL_MEDIUM 0x10000000L // Fast B Frame (No Half Pixel)
  25. #define DECODE_BQUAL_LOW 0x20000000L // Super Fast B Frame (No Half Pixel & Fast IDCT)
  26. #define MM_NOCONV 0x00000000L // No Conversion
  27. #define MM_HRESOLUTION 0x10000000L // Half Resolution
  28. #define MM_CLIPPED 0x20000000L // Clipped version (RGB8 only at present)
  29. #define MM_420PL 0x00000001L // YU12 :: YCbCr
  30. #define MM_420PL_ 0x00000002L // YV12 :: YCrCb
  31. #define MM_422PK 0x00000010L // YUY2 :: YCbCr
  32. #define MM_422PK_ 0x00000020L // YVY2 :: YCrCb
  33. #define MM_422SPK 0x00000040L // :: CbYCrY
  34. #define MM_422SPK_ 0x00000080L // :: CrYCbY
  35. #define MM_411PK 0x00000100L // BT41
  36. #define MM_410PL_ 0x00000200L // YVU9 - 16:1:1 Planar format
  37. #define MM_Y_DIB 0x00001000L // Luminance Only DIB
  38. #define MM_Y_DDB 0x00002000L // Luminance Only DDB
  39. #define MM_RGB24_DIB 0x00010000L // RGB 8:8:8 DIB (Not Supported)
  40. #define MM_RGB24_DDB 0x00020000L // RGB 8:8:8 DDB (Not Supported)
  41. #define MM_RGB32_DIB 0x00040000L // RGB a:8:8:8 DIB (Not Supported)
  42. #define MM_RGB32_DDB 0x00080000L // RGB a:8:8:8 DDB (Not Supported)
  43. #define MM_RGB565_DIB 0x00100000L // RGB 5:6:5 DIB
  44. #define MM_RGB565_DDB 0x00200000L // RGB 5:6:5 DDB
  45. #define MM_RGB555_DIB 0x00400000L // RGB 5:5:5 DIB
  46. #define MM_RGB555_DDB 0x00800000L // RGB 5:5:5 DDB
  47. #define MM_RGB8_DIB 0x01000000L // 8 Bit Paletized RGB DIB
  48. #define MM_RGB8_DDB 0x02000000L // 8 Bit Paletized RGB DDB
  49. #define DECODE_HALF_HIQ 0x00004000L
  50. #define DECODE_HALF_FULLQ 0x00008000L
  51. // {CC785860-B2CA-11ce-8D2B-0000E202599C}
  52. DEFINE_GUID(CLSID_MpegAudioDecodePropertyPage,
  53. 0xcc785860, 0xb2ca, 0x11ce, 0x8d, 0x2b, 0x0, 0x0, 0xe2, 0x2, 0x59, 0x9c);
  54. // {E5B4EAA0-B2CA-11ce-8D2B-0000E202599C}
  55. DEFINE_GUID(CLSID_MpegVideoDecodePropertyPage,
  56. 0xe5b4eaa0, 0xb2ca, 0x11ce, 0x8d, 0x2b, 0x0, 0x0, 0xe2, 0x2, 0x59, 0x9c);
  57. // {EB1BB270-F71F-11CE-8E85-02608C9BABA2}
  58. DEFINE_GUID(IID_IMpegVideoDecoder,
  59. 0xeb1bb270, 0xf71f, 0x11ce, 0x8e, 0x85, 0x02, 0x60, 0x8c, 0x9b, 0xab, 0xa2);
  60. //
  61. // Structure to describe the caps of the mpeg video decoder.
  62. //
  63. typedef struct {
  64. DWORD VideoMaxBitRate;
  65. } MPEG_VIDEO_DECODER_CAPS;
  66. //
  67. // IMpegVideoDecoder
  68. //
  69. DECLARE_INTERFACE_(IMpegVideoDecoder, IUnknown) {
  70. STDMETHOD(get_CurrentDecoderOption)
  71. ( THIS_
  72. DWORD *pOptions
  73. ) PURE;
  74. STDMETHOD(set_CurrentDecoderOption)
  75. ( THIS_
  76. DWORD Options
  77. ) PURE;
  78. STDMETHOD(get_DefaultDecoderOption)
  79. ( THIS_
  80. DWORD *pOptions
  81. ) PURE;
  82. STDMETHOD(set_DefaultDecoderOption)
  83. ( THIS_
  84. DWORD Options
  85. ) PURE;
  86. STDMETHOD(get_QualityMsgProcessing)
  87. ( THIS_
  88. BOOL *pfIgnore
  89. ) PURE;
  90. STDMETHOD(set_QualityMsgProcessing)
  91. ( THIS_
  92. BOOL fIgnore
  93. ) PURE;
  94. STDMETHOD(get_GreyScaleOutput)
  95. ( THIS_
  96. BOOL *pfGrey
  97. ) PURE;
  98. STDMETHOD(set_GreyScaleOutput)
  99. ( THIS_
  100. BOOL fGrey
  101. ) PURE;
  102. STDMETHOD(get_SequenceHeader)
  103. ( THIS_
  104. SEQHDR_INFO *pSeqHdrInfo
  105. ) PURE;
  106. STDMETHOD(get_OutputFormat)
  107. ( THIS_
  108. DWORD *pOutputFormat
  109. ) PURE;
  110. STDMETHOD(get_FrameStatistics)
  111. ( THIS_
  112. DWORD *pIFramesDecoded,
  113. DWORD *pPFramesDecoded,
  114. DWORD *pBFramesDecoded,
  115. DWORD *pIFramesSkipped,
  116. DWORD *pPFramesSkipped,
  117. DWORD *pBFramesSkipped
  118. ) PURE;
  119. STDMETHOD(ResetFrameStatistics)
  120. ( THIS_
  121. ) PURE;
  122. STDMETHOD(get_DecoderPaletteInfo)
  123. ( THIS_
  124. LPDWORD lpdwFirstEntry,
  125. LPDWORD lpdwLastEntry
  126. ) PURE;
  127. STDMETHOD(get_DecoderPaletteEntries)
  128. ( THIS_
  129. DWORD dwStartEntry,
  130. DWORD dwNumEntries,
  131. LPPALETTEENTRY lppe
  132. ) PURE;
  133. STDMETHOD(get_EncryptionKey)
  134. ( THIS_
  135. DWORD *dwEncrptionKey
  136. ) PURE;
  137. STDMETHOD(put_EncryptionKey)
  138. ( THIS_
  139. DWORD dwEncrptionKey
  140. ) PURE;
  141. STDMETHOD(get_DecoderCaps)
  142. ( THIS_
  143. MPEG_VIDEO_DECODER_CAPS *pCaps
  144. ) PURE;
  145. };