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.

109 lines
3.2 KiB

  1. typedef enum tagFrameSize
  2. {
  3. FORBIDDEN=0,
  4. SQCIF=1,
  5. QCIF=2,
  6. CIF=3,
  7. fCIF=4,
  8. ssCIF=5
  9. }FrameSize;
  10. // MSH26X Configuration Information
  11. typedef struct tagMSH26XCONF{
  12. BOOL bInitialized; // Whether custom msgs can be rcv'd.
  13. BOOL bCompressBegin; // Whether the CompressBegin msg was rcv'd.
  14. BOOL bRTPHeader; // Whether to generate RTP header info
  15. /* used if bRTPHeader */
  16. UINT unPacketSize; // Maximum packet size
  17. BOOL bEncoderResiliency; // Whether to use resiliency restrictions
  18. /* used if bEncoderResiliency */
  19. UINT unPacketLoss;
  20. BOOL bBitRateState;
  21. /* used if bBitRateState */
  22. UINT unBytesPerSecond;
  23. /* The following information is determined from the packet loss value. */
  24. /* These values are calculated each time we receive a resiliency msg or */
  25. /* the value is changed through the dialog box. They are not stored in */
  26. /* the registry. Only the above elements are stored in the registry. */
  27. BOOL bDisallowPosVerMVs; // if true, disallow positive vertical MVs
  28. BOOL bDisallowAllVerMVs; // if true, disallow all vertical MVs
  29. UINT unPercentForcedUpdate; // Percent Forced Update per Frame
  30. UINT unDefaultIntraQuant; // Default Intra Quant
  31. UINT unDefaultInterQuant; // Default Inter Quant
  32. } MSH26XCONF;
  33. // MSH26X Compressor Instance information
  34. typedef struct tagMSH26XCOMPINSTINFO{
  35. BOOL Initialized;
  36. WORD xres, yres;
  37. FrameSize FrameSz; // Which of the supported frame sizes.
  38. float FrameRate;
  39. DWORD DataRate; // Data rate in bytes per second.
  40. HGLOBAL hEncoderInst; // Instance data private to encoder.
  41. LPVOID EncoderInst;
  42. WORD CompressedSize;
  43. BOOL Is160x120;
  44. BOOL Is240x180;
  45. BOOL Is320x240;
  46. MSH26XCONF Configuration;
  47. #if !defined(_ALPHA_) && defined(USE_BILINEAR_MSH26X)
  48. UINT InputCompression;
  49. UINT InputBitWidth;
  50. #endif
  51. } MSH26XCOMPINSTINFO, *PMSH26XCOMPINSTINFO;
  52. // MSH26X BitStream Info Trailer structure
  53. typedef struct tagH26X_RTP_BSINFO_TRAILER {
  54. DWORD dwVersion;
  55. DWORD dwFlags;
  56. DWORD dwUniqueCode;
  57. DWORD dwCompressedSize;
  58. DWORD dwNumOfPackets;
  59. BYTE bySrc;
  60. BYTE byTR;
  61. BYTE byTRB;
  62. BYTE byDBQ;
  63. } H26X_RTP_BSINFO_TRAILER, *PH26X_RTP_BSINFO_TRAILER;
  64. // MSH263 BitStream Info structure
  65. typedef struct tagRTP_H263_BSINFO {
  66. DWORD dwFlags;
  67. DWORD dwBitOffset;
  68. BYTE byMode;
  69. BYTE byMBA;
  70. BYTE byQuant;
  71. BYTE byGOBN;
  72. char cHMV1;
  73. char cVMV1;
  74. char cHMV2;
  75. char cVMV2;
  76. } RTP_H263_BSINFO, *PRTP_H263_BSINFO;
  77. // MSH261 BitStream Info structure
  78. typedef struct tagRTP_H261_BSINFO {
  79. DWORD dwFlags;
  80. DWORD dwBitOffset;
  81. BYTE byMBA;
  82. BYTE byQuant;
  83. BYTE byGOBN;
  84. char cHMV;
  85. char cVMV;
  86. BYTE byPadding0;
  87. WORD wPadding1;
  88. } RTP_H261_BSINFO, *PRTP_H261_BSINFO;
  89. // Constants
  90. #define H263_RTP_BS_START_CODE MakeFOURCC('H','2','6','3')
  91. #define H261_RTP_BS_START_CODE MakeFOURCC('H','2','6','1')
  92. #define RTP_H26X_INTRA_CODED 0x00000001
  93. #define RTP_H263_PB 0x00000002
  94. #define RTP_H263_AP 0x00000004
  95. #define RTP_H263_SAC 0x00000008
  96. #define RTP_H263_MODE_A 0x00
  97. #define RTP_H263_MODE_B 0x01
  98. #define RTP_H263_MODE_C 0x02
  99. #define H26X_RTP_PAYLOAD_VERSION 0x00000000
  100. #define RTP_H26X_PACKET_LOST 0x00000001