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.

224 lines
6.9 KiB

  1. /*
  2. * @DEC_COPYRIGHT@
  3. */
  4. /*
  5. * HISTORY
  6. * $Log: sv_internals.h,v $
  7. * Revision 1.1.8.2 1996/05/07 19:56:06 Hans_Graves
  8. * Added HUFF_SUPPORT.
  9. * [1996/05/07 17:25:29 Hans_Graves]
  10. *
  11. * Revision 1.1.6.2 1996/03/29 22:21:16 Hans_Graves
  12. * Added JPEG_SUPPORT ifdefs. Moved JPEG specific data to JpegInfo structures
  13. * [1996/03/29 22:14:34 Hans_Graves]
  14. *
  15. * Revision 1.1.4.2 1995/12/07 19:31:30 Hans_Graves
  16. * Added SvMpegCompressInfo_t pointer
  17. * [1995/12/07 18:27:16 Hans_Graves]
  18. *
  19. * Revision 1.1.2.7 1995/09/22 12:58:41 Bjorn_Engberg
  20. * Added MPEG_SUPPORT, H261_SUPPORT and BITSTREAM_SUPPORT.
  21. * [1995/09/22 12:49:37 Bjorn_Engberg]
  22. *
  23. * Revision 1.1.2.6 1995/09/11 18:49:43 Farokh_Morshed
  24. * Support BI_BITFIELDS format
  25. * [1995/09/11 18:49:23 Farokh_Morshed]
  26. *
  27. * Revision 1.1.2.5 1995/07/21 17:41:06 Hans_Graves
  28. * Renamed Callback related stuff.
  29. * [1995/07/21 17:28:26 Hans_Graves]
  30. *
  31. * Revision 1.1.2.4 1995/07/17 16:12:14 Hans_Graves
  32. * Moved BSIn, BufQ and ImageQ to SvCodecInfo_t structure.
  33. * [1995/07/17 15:54:04 Hans_Graves]
  34. *
  35. * Revision 1.1.2.3 1995/06/19 20:31:17 Karen_Dintino
  36. * Added support for H.261
  37. * [1995/06/19 20:14:01 Karen_Dintino]
  38. *
  39. * Revision 1.1.2.2 1995/05/31 18:10:06 Hans_Graves
  40. * Inclusion in new SLIB location.
  41. * [1995/05/31 15:43:08 Hans_Graves]
  42. *
  43. * Revision 1.1.2.3 1994/11/18 18:48:17 Paul_Gauthier
  44. * Cleanup & bug fixes
  45. * [1994/11/18 18:45:08 Paul_Gauthier]
  46. *
  47. * Revision 1.1.2.2 1994/10/07 14:54:06 Paul_Gauthier
  48. * SLIB v3.0 incl. MPEG Decode
  49. * [1994/10/07 13:56:29 Paul_Gauthier]
  50. *
  51. * $EndLog$
  52. */
  53. /*
  54. **++
  55. ** FACILITY: Workstation Multimedia (WMM) v1.0
  56. **
  57. ** FILE NAME:
  58. ** MODULE NAME:
  59. **
  60. ** MODULE DESCRIPTION:
  61. **
  62. ** DESIGN OVERVIEW:
  63. **
  64. **--
  65. */
  66. /* "%Z% %M% revision %I%; last modified %G%"; */
  67. /*****************************************************************************
  68. ** Copyright (c) Digital Equipment Corporation, 1994 **
  69. ** **
  70. ** All Rights Reserved. Unpublished rights reserved under the copyright **
  71. ** laws of the United States. **
  72. ** **
  73. ** The software contained on this media is proprietary to and embodies **
  74. ** the confidential technology of Digital Equipment Corporation. **
  75. ** Possession, use, duplication or dissemination of the software and **
  76. ** media is authorized only pursuant to a valid written license from **
  77. ** Digital Equipment Corporation. **
  78. ** **
  79. ** RESTRICTED RIGHTS LEGEND Use, duplication, or disclosure by the U.S. **
  80. ** Government is subject to restrictions as set forth in Subparagraph **
  81. ** (c)(1)(ii) of DFARS 252.227-7013, or in FAR 52.227-19, as applicable. **
  82. ******************************************************************************/
  83. /*--------------------------------------------------------------------------
  84. * Baseline data structure definitions.
  85. *
  86. * Modification History: sv_internals.h
  87. *
  88. * 08-Sep-94 PSG Created
  89. *---------------------------------------------------------------------------*/
  90. #ifndef _SV_INTERNALS_H_
  91. #define _SV_INTERNALS_H_
  92. #include "SV.h"
  93. #ifdef JPEG_SUPPORT
  94. #include "sv_jpeg.h"
  95. #endif /* JPEG_SUPPORT */
  96. #ifdef MPEG_SUPPORT
  97. #include "sv_mpeg.h"
  98. #endif /* MPEG_SUPPORT */
  99. #ifdef H261_SUPPORT
  100. #include "sv_h261.h"
  101. #endif /* H261_SUPPORT */
  102. #ifdef H263_SUPPORT
  103. #include "sv_h263.h"
  104. #endif /* H263_SUPPORT */
  105. #ifdef HUFF_SUPPORT
  106. #include "sv_huff.h"
  107. #endif /* HUFF_SUPPORT */
  108. #if defined(MPEG_SUPPORT) || defined(H261_SUPPORT) || defined(H263_SUPPORT) || defined(HUFF_SUPPORT)
  109. #define BITSTREAM_SUPPORT
  110. #endif /* MPEG_SUPPORT || H261_SUPPORT */
  111. #define TOC_ENTRIES_INCREMENT 100
  112. #define TEMP_BUF_SIZE 8192
  113. #define JBUFSIZE 16384
  114. #define BYTE_BUF_SIZE 8192
  115. /*
  116. ** The following structure contains *all* state information pertaining
  117. ** to each individual codec instance. Anything SLIB would ever want
  118. ** about the codec configuration is contained in this structure.
  119. ** For example:
  120. ** - what is the codec configured for: compression or decompression
  121. ** - source image characteristics
  122. ** - destination image characteristics
  123. ** - characteristics particular to JPEG compression
  124. ** - characteristics particular to JPEG decompression
  125. ** - component specific information
  126. **
  127. */
  128. typedef struct SvCodecInfo_s {
  129. /*
  130. ** what is the CODEC opened for:
  131. */
  132. SvCodecType_e mode; /* code type, encode or decode */
  133. ScBoolean_t started; /* begin was called? */
  134. /*
  135. ** specific CODEC info
  136. */
  137. union {
  138. void *info;
  139. #ifdef JPEG_SUPPORT
  140. /*
  141. ** JPEG information is stored here:
  142. ** modes = SV_JPEG_DECODE, SV_JPEG_ENCODE
  143. */
  144. SvJpegDecompressInfo_t *jdcmp;
  145. SvJpegCompressInfo_t *jcomp;
  146. #endif /* !JPEG_SUPPORT */
  147. #ifdef MPEG_SUPPORT
  148. /*
  149. ** MPEG specific information is stored here:
  150. ** modes = SV_MPEG_DECODE, SV_MPEG_ENCODE, SV_MPEG_DECODE, SV_MPEG_ENCODE
  151. */
  152. SvMpegDecompressInfo_t *mdcmp;
  153. SvMpegCompressInfo_t *mcomp;
  154. #endif /* !MPEG_SUPPORT */
  155. #ifdef H261_SUPPORT
  156. /* Encoding specific information for H.261 is kept in this structure
  157. ** which is defined in sv_h261.h
  158. */
  159. SvH261Info_t *h261;
  160. #endif /* !H261_SUPPORT */
  161. #ifdef H263_SUPPORT
  162. /*
  163. ** H263 specific information is stored here:
  164. */
  165. SvH263DecompressInfo_t *h263dcmp;
  166. SvH263CompressInfo_t *h263comp;
  167. #endif /* !MPEG_SUPPORT */
  168. #ifdef HUFF_SUPPORT
  169. /* Encoding specific information for huffman video encoder & decoder
  170. */
  171. SvHuffInfo_t *huff;
  172. #endif /* !HUFF_SUPPORT */
  173. }; /* union */
  174. /*
  175. ** Source image characteristics:
  176. */
  177. int Width; /* pixels/lines */
  178. int Height; /* number of lines */
  179. unsigned int NumOperations; /* # codec operations this session */
  180. /*
  181. ** Microsoft specific:
  182. */
  183. BITMAPINFOHEADER InputFormat;
  184. DWORD InRedMask; /* For BI_BITFIELDS */
  185. DWORD InGreenMask; /* For BI_BITFIELDS */
  186. DWORD InBlueMask; /* For BI_BITFIELDS */
  187. BITMAPINFOHEADER OutputFormat;
  188. DWORD OutRedMask; /* For BI_BITFIELDS */
  189. DWORD OutGreenMask; /* For BI_BITFIELDS */
  190. DWORD OutBlueMask; /* For BI_BITFIELDS */
  191. /*
  192. ** Bitstream stuff - Only used by H261, H263 and MPEG
  193. */
  194. ScQueue_t *BufQ; /* The queue of bitstream data buffers */
  195. ScQueue_t *ImageQ; /* The queue of images (streaming mode only) */
  196. ScBitstream_t *BSIn;
  197. ScBitstream_t *BSOut;
  198. /*
  199. ** Callback function to abort processing & bitstream operations
  200. */
  201. int (* CallbackFunction)(SvHandle_t, SvCallbackInfo_t *, SvPictureInfo_t *);
  202. } SvCodecInfo_t;
  203. #endif _SV_INTERNALS_H_