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.

186 lines
6.3 KiB

  1. //==========================================================================;
  2. //
  3. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
  4. // KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
  5. // IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
  6. // PURPOSE.
  7. //
  8. // Copyright (c) 1997 Microsoft Corporation. All Rights Reserved.
  9. //
  10. //
  11. // History:
  12. // 22-Aug-97 TKB Created Initial Interface Version
  13. //
  14. //==========================================================================;
  15. #ifndef __ICODEC_H
  16. #define __ICODEC_H
  17. #include <iks.h>
  18. #pragma warning(disable:4355)
  19. //////////////////////////////////////////////////////////////
  20. // IBitmaskProperty
  21. //////////////////////////////////////////////////////////////
  22. class IBitmaskProperty : public IKSProperty
  23. {
  24. // Usable public interfaces
  25. public:
  26. IBitmaskProperty(IKSDriver &Driver, LPCGUID Set, ULONG Id, ULONG Size) :
  27. IKSProperty(Driver, Set, Id, Size) {}
  28. IBitmaskProperty(IKSPin &Pin, LPCGUID Set, ULONG Id, ULONG Size) :
  29. IKSProperty(Pin, Set, Id, Size) {}
  30. // Bitmask Manipulation Routines.
  31. ~IBitmaskProperty();
  32. // Helper functions and internal data
  33. protected:
  34. };
  35. //////////////////////////////////////////////////////////////
  36. // IScanlinesProperty
  37. //////////////////////////////////////////////////////////////
  38. class IScanlinesProperty : public IBitmaskProperty
  39. {
  40. // Usable public interfaces
  41. public:
  42. IScanlinesProperty(IKSDriver &Driver, ULONG Id, ULONG Size) :
  43. IBitmaskProperty(Driver, &KSPROPSETID_VBICodecFiltering, Id, Size) {}
  44. IScanlinesProperty(IKSPin &Pin, ULONG Id, ULONG Size) :
  45. IBitmaskProperty(Pin, &KSPROPSETID_VBICodecFiltering, Id, Size) {}
  46. // Scanline Manipulation Routines.
  47. ~IScanlinesProperty();
  48. // Helper functions and internal data
  49. protected:
  50. };
  51. //////////////////////////////////////////////////////////////
  52. // ISubstreamsProperty
  53. //////////////////////////////////////////////////////////////
  54. class ISubstreamsProperty : public IBitmaskProperty
  55. {
  56. // Usable public interfaces
  57. public:
  58. ISubstreamsProperty(IKSDriver &Driver, ULONG Id, ULONG Size ) :
  59. IBitmaskProperty(Driver,&KSPROPSETID_VBICodecFiltering,Id,Size) {}
  60. ISubstreamsProperty(IKSPin &Pin, ULONG Id, ULONG Size) :
  61. IBitmaskProperty(Pin,&KSPROPSETID_VBICodecFiltering,Id,Size) {}
  62. // Substream Manipulation Routines.
  63. ~ISubstreamsProperty();
  64. // Helper functions and internal data
  65. protected:
  66. };
  67. //////////////////////////////////////////////////////////////
  68. // IStatisticsProperty
  69. //////////////////////////////////////////////////////////////
  70. class IStatisticsProperty : public IKSProperty
  71. {
  72. // Usable public interfaces
  73. public:
  74. IStatisticsProperty(IKSDriver &Driver, ULONG Id, ULONG Size ) :
  75. IKSProperty(Driver,&KSPROPSETID_VBICodecFiltering,Id,Size) {}
  76. IStatisticsProperty(IKSPin &Pin, ULONG Id, ULONG Size) :
  77. IKSProperty(Pin,&KSPROPSETID_VBICodecFiltering,Id,Size) {}
  78. // Statistics Manipulation Routines.
  79. ~IStatisticsProperty();
  80. // Helper functions and internal data
  81. protected:
  82. };
  83. //////////////////////////////////////////////////////////////
  84. // IVBIOutputPin
  85. //////////////////////////////////////////////////////////////
  86. class IVBIOutputPin : public IKSPin
  87. {
  88. // Usable public interfaces
  89. public:
  90. IVBIOutputPin(IKSDriver &driver, int nPin, PKSDATARANGE pKSDataRange, DWORD nSubstreamBitmaskSize ) :
  91. IKSPin( driver, nPin, pKSDataRange ),
  92. m_ScanlinesRequested(*this,KSPROPERTY_VBICODECFILTERING_SCANLINES_REQUESTED_BIT_ARRAY,
  93. sizeof(VBICODECFILTERING_SCANLINES)),
  94. m_ScanlinesDiscovered(*this,KSPROPERTY_VBICODECFILTERING_SCANLINES_DISCOVERED_BIT_ARRAY,
  95. sizeof(VBICODECFILTERING_SCANLINES)),
  96. m_SubstreamsRequested(*this,KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_REQUESTED_BIT_ARRAY,
  97. nSubstreamBitmaskSize),
  98. m_SubstreamsDiscovered(*this,KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_DISCOVERED_BIT_ARRAY,
  99. nSubstreamBitmaskSize)
  100. {}
  101. ~IVBIOutputPin();
  102. // Pin specific properties (does not affect other pins)
  103. IScanlinesProperty m_ScanlinesRequested;
  104. IScanlinesProperty m_ScanlinesDiscovered;
  105. ISubstreamsProperty m_SubstreamsRequested;
  106. ISubstreamsProperty m_SubstreamsDiscovered;
  107. // Helper functions and internal data
  108. protected:
  109. };
  110. //////////////////////////////////////////////////////////////
  111. // IVBICodec:: VBI Codec Interface
  112. //////////////////////////////////////////////////////////////
  113. class IVBICodec : public IKSDriver
  114. {
  115. // Usable public interfaces
  116. public:
  117. IVBICodec(LPCSTR lpszDriver, DWORD nSubstreamBitmaskSize ) :
  118. IKSDriver(&KSCATEGORY_VBICODEC,lpszDriver),
  119. m_ScanlinesRequested(*this,KSPROPERTY_VBICODECFILTERING_SCANLINES_REQUESTED_BIT_ARRAY,
  120. sizeof(VBICODECFILTERING_SCANLINES)),
  121. m_ScanlinesDiscovered(*this,KSPROPERTY_VBICODECFILTERING_SCANLINES_DISCOVERED_BIT_ARRAY,
  122. sizeof(VBICODECFILTERING_SCANLINES)),
  123. m_SubstreamsRequested(*this,KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_REQUESTED_BIT_ARRAY,
  124. nSubstreamBitmaskSize),
  125. m_SubstreamsDiscovered(*this,KSPROPERTY_VBICODECFILTERING_SUBSTREAMS_DISCOVERED_BIT_ARRAY,
  126. nSubstreamBitmaskSize)
  127. {}
  128. ~IVBICodec();
  129. // Driver global properties (set new pin defaults & overall driver status)
  130. IScanlinesProperty m_ScanlinesRequested;
  131. IScanlinesProperty m_ScanlinesDiscovered;
  132. ISubstreamsProperty m_SubstreamsRequested;
  133. ISubstreamsProperty m_SubstreamsDiscovered;
  134. // Override the IsValid() implementation to included tests on properties
  135. BOOL IsValid() { return IKSDriver::IsValid()
  136. && m_ScanlinesRequested.IsValid()
  137. && m_ScanlinesDiscovered.IsValid()
  138. && m_SubstreamsRequested.IsValid()
  139. && m_SubstreamsDiscovered.IsValid(); }
  140. // Helper functions and internal data
  141. protected:
  142. };
  143. #pragma warning(default:4355)
  144. #endif