Team Fortress 2 Source Code as on 22/4/2020
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.

393 lines
17 KiB

  1. /*
  2. * jdct.h
  3. *
  4. * Copyright (C) 1994-1996, Thomas G. Lane.
  5. * This file is part of the Independent JPEG Group's software.
  6. * For conditions of distribution and use, see the accompanying README file.
  7. *
  8. * This include file contains common declarations for the forward and
  9. * inverse DCT modules. These declarations are private to the DCT managers
  10. * (jcdctmgr.c, jddctmgr.c) and the individual DCT algorithms.
  11. * The individual DCT algorithms are kept in separate files to ease
  12. * machine-dependent tuning (e.g., assembly coding).
  13. */
  14. /*
  15. * A forward DCT routine is given a pointer to an input sample array and
  16. * a pointer to a work area of type DCTELEM[]; the DCT is to be performed
  17. * in-place in that buffer. Type DCTELEM is int for 8-bit samples, INT32
  18. * for 12-bit samples. (NOTE: Floating-point DCT implementations use an
  19. * array of type FAST_FLOAT, instead.)
  20. * The input data is to be fetched from the sample array starting at a
  21. * specified column. (Any row offset needed will be applied to the array
  22. * pointer before it is passed to the FDCT code.)
  23. * Note that the number of samples fetched by the FDCT routine is
  24. * DCT_h_scaled_size * DCT_v_scaled_size.
  25. * The DCT outputs are returned scaled up by a factor of 8; they therefore
  26. * have a range of +-8K for 8-bit data, +-128K for 12-bit data. This
  27. * convention improves accuracy in integer implementations and saves some
  28. * work in floating-point ones.
  29. * Quantization of the output coefficients is done by jcdctmgr.c.
  30. */
  31. #if BITS_IN_JSAMPLE == 8
  32. typedef int DCTELEM; /* 16 or 32 bits is fine */
  33. #else
  34. typedef INT32 DCTELEM; /* must have 32 bits */
  35. #endif
  36. typedef JMETHOD(void, forward_DCT_method_ptr, (DCTELEM * data,
  37. JSAMPARRAY sample_data,
  38. JDIMENSION start_col));
  39. typedef JMETHOD(void, float_DCT_method_ptr, (FAST_FLOAT * data,
  40. JSAMPARRAY sample_data,
  41. JDIMENSION start_col));
  42. /*
  43. * An inverse DCT routine is given a pointer to the input JBLOCK and a pointer
  44. * to an output sample array. The routine must dequantize the input data as
  45. * well as perform the IDCT; for dequantization, it uses the multiplier table
  46. * pointed to by compptr->dct_table. The output data is to be placed into the
  47. * sample array starting at a specified column. (Any row offset needed will
  48. * be applied to the array pointer before it is passed to the IDCT code.)
  49. * Note that the number of samples emitted by the IDCT routine is
  50. * DCT_h_scaled_size * DCT_v_scaled_size.
  51. */
  52. /* typedef inverse_DCT_method_ptr is declared in jpegint.h */
  53. /*
  54. * Each IDCT routine has its own ideas about the best dct_table element type.
  55. */
  56. typedef MULTIPLIER ISLOW_MULT_TYPE; /* short or int, whichever is faster */
  57. #if BITS_IN_JSAMPLE == 8
  58. typedef MULTIPLIER IFAST_MULT_TYPE; /* 16 bits is OK, use short if faster */
  59. #define IFAST_SCALE_BITS 2 /* fractional bits in scale factors */
  60. #else
  61. typedef INT32 IFAST_MULT_TYPE; /* need 32 bits for scaled quantizers */
  62. #define IFAST_SCALE_BITS 13 /* fractional bits in scale factors */
  63. #endif
  64. typedef FAST_FLOAT FLOAT_MULT_TYPE; /* preferred floating type */
  65. /*
  66. * Each IDCT routine is responsible for range-limiting its results and
  67. * converting them to unsigned form (0..MAXJSAMPLE). The raw outputs could
  68. * be quite far out of range if the input data is corrupt, so a bulletproof
  69. * range-limiting step is required. We use a mask-and-table-lookup method
  70. * to do the combined operations quickly. See the comments with
  71. * prepare_range_limit_table (in jdmaster.c) for more info.
  72. */
  73. #define IDCT_range_limit(cinfo) ((cinfo)->sample_range_limit + CENTERJSAMPLE)
  74. #define RANGE_MASK (MAXJSAMPLE * 4 + 3) /* 2 bits wider than legal samples */
  75. /* Short forms of external names for systems with brain-damaged linkers. */
  76. #ifdef NEED_SHORT_EXTERNAL_NAMES
  77. #define jpeg_fdct_islow jFDislow
  78. #define jpeg_fdct_ifast jFDifast
  79. #define jpeg_fdct_float jFDfloat
  80. #define jpeg_fdct_7x7 jFD7x7
  81. #define jpeg_fdct_6x6 jFD6x6
  82. #define jpeg_fdct_5x5 jFD5x5
  83. #define jpeg_fdct_4x4 jFD4x4
  84. #define jpeg_fdct_3x3 jFD3x3
  85. #define jpeg_fdct_2x2 jFD2x2
  86. #define jpeg_fdct_1x1 jFD1x1
  87. #define jpeg_fdct_9x9 jFD9x9
  88. #define jpeg_fdct_10x10 jFD10x10
  89. #define jpeg_fdct_11x11 jFD11x11
  90. #define jpeg_fdct_12x12 jFD12x12
  91. #define jpeg_fdct_13x13 jFD13x13
  92. #define jpeg_fdct_14x14 jFD14x14
  93. #define jpeg_fdct_15x15 jFD15x15
  94. #define jpeg_fdct_16x16 jFD16x16
  95. #define jpeg_fdct_16x8 jFD16x8
  96. #define jpeg_fdct_14x7 jFD14x7
  97. #define jpeg_fdct_12x6 jFD12x6
  98. #define jpeg_fdct_10x5 jFD10x5
  99. #define jpeg_fdct_8x4 jFD8x4
  100. #define jpeg_fdct_6x3 jFD6x3
  101. #define jpeg_fdct_4x2 jFD4x2
  102. #define jpeg_fdct_2x1 jFD2x1
  103. #define jpeg_fdct_8x16 jFD8x16
  104. #define jpeg_fdct_7x14 jFD7x14
  105. #define jpeg_fdct_6x12 jFD6x12
  106. #define jpeg_fdct_5x10 jFD5x10
  107. #define jpeg_fdct_4x8 jFD4x8
  108. #define jpeg_fdct_3x6 jFD3x6
  109. #define jpeg_fdct_2x4 jFD2x4
  110. #define jpeg_fdct_1x2 jFD1x2
  111. #define jpeg_idct_islow jRDislow
  112. #define jpeg_idct_ifast jRDifast
  113. #define jpeg_idct_float jRDfloat
  114. #define jpeg_idct_7x7 jRD7x7
  115. #define jpeg_idct_6x6 jRD6x6
  116. #define jpeg_idct_5x5 jRD5x5
  117. #define jpeg_idct_4x4 jRD4x4
  118. #define jpeg_idct_3x3 jRD3x3
  119. #define jpeg_idct_2x2 jRD2x2
  120. #define jpeg_idct_1x1 jRD1x1
  121. #define jpeg_idct_9x9 jRD9x9
  122. #define jpeg_idct_10x10 jRD10x10
  123. #define jpeg_idct_11x11 jRD11x11
  124. #define jpeg_idct_12x12 jRD12x12
  125. #define jpeg_idct_13x13 jRD13x13
  126. #define jpeg_idct_14x14 jRD14x14
  127. #define jpeg_idct_15x15 jRD15x15
  128. #define jpeg_idct_16x16 jRD16x16
  129. #define jpeg_idct_16x8 jRD16x8
  130. #define jpeg_idct_14x7 jRD14x7
  131. #define jpeg_idct_12x6 jRD12x6
  132. #define jpeg_idct_10x5 jRD10x5
  133. #define jpeg_idct_8x4 jRD8x4
  134. #define jpeg_idct_6x3 jRD6x3
  135. #define jpeg_idct_4x2 jRD4x2
  136. #define jpeg_idct_2x1 jRD2x1
  137. #define jpeg_idct_8x16 jRD8x16
  138. #define jpeg_idct_7x14 jRD7x14
  139. #define jpeg_idct_6x12 jRD6x12
  140. #define jpeg_idct_5x10 jRD5x10
  141. #define jpeg_idct_4x8 jRD4x8
  142. #define jpeg_idct_3x6 jRD3x8
  143. #define jpeg_idct_2x4 jRD2x4
  144. #define jpeg_idct_1x2 jRD1x2
  145. #endif /* NEED_SHORT_EXTERNAL_NAMES */
  146. /* Extern declarations for the forward and inverse DCT routines. */
  147. EXTERN(void) jpeg_fdct_islow
  148. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  149. EXTERN(void) jpeg_fdct_ifast
  150. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  151. EXTERN(void) jpeg_fdct_float
  152. JPP((FAST_FLOAT * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  153. EXTERN(void) jpeg_fdct_7x7
  154. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  155. EXTERN(void) jpeg_fdct_6x6
  156. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  157. EXTERN(void) jpeg_fdct_5x5
  158. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  159. EXTERN(void) jpeg_fdct_4x4
  160. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  161. EXTERN(void) jpeg_fdct_3x3
  162. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  163. EXTERN(void) jpeg_fdct_2x2
  164. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  165. EXTERN(void) jpeg_fdct_1x1
  166. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  167. EXTERN(void) jpeg_fdct_9x9
  168. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  169. EXTERN(void) jpeg_fdct_10x10
  170. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  171. EXTERN(void) jpeg_fdct_11x11
  172. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  173. EXTERN(void) jpeg_fdct_12x12
  174. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  175. EXTERN(void) jpeg_fdct_13x13
  176. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  177. EXTERN(void) jpeg_fdct_14x14
  178. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  179. EXTERN(void) jpeg_fdct_15x15
  180. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  181. EXTERN(void) jpeg_fdct_16x16
  182. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  183. EXTERN(void) jpeg_fdct_16x8
  184. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  185. EXTERN(void) jpeg_fdct_14x7
  186. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  187. EXTERN(void) jpeg_fdct_12x6
  188. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  189. EXTERN(void) jpeg_fdct_10x5
  190. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  191. EXTERN(void) jpeg_fdct_8x4
  192. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  193. EXTERN(void) jpeg_fdct_6x3
  194. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  195. EXTERN(void) jpeg_fdct_4x2
  196. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  197. EXTERN(void) jpeg_fdct_2x1
  198. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  199. EXTERN(void) jpeg_fdct_8x16
  200. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  201. EXTERN(void) jpeg_fdct_7x14
  202. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  203. EXTERN(void) jpeg_fdct_6x12
  204. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  205. EXTERN(void) jpeg_fdct_5x10
  206. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  207. EXTERN(void) jpeg_fdct_4x8
  208. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  209. EXTERN(void) jpeg_fdct_3x6
  210. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  211. EXTERN(void) jpeg_fdct_2x4
  212. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  213. EXTERN(void) jpeg_fdct_1x2
  214. JPP((DCTELEM * data, JSAMPARRAY sample_data, JDIMENSION start_col));
  215. EXTERN(void) jpeg_idct_islow
  216. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  217. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  218. EXTERN(void) jpeg_idct_ifast
  219. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  220. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  221. EXTERN(void) jpeg_idct_float
  222. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  223. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  224. EXTERN(void) jpeg_idct_7x7
  225. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  226. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  227. EXTERN(void) jpeg_idct_6x6
  228. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  229. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  230. EXTERN(void) jpeg_idct_5x5
  231. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  232. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  233. EXTERN(void) jpeg_idct_4x4
  234. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  235. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  236. EXTERN(void) jpeg_idct_3x3
  237. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  238. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  239. EXTERN(void) jpeg_idct_2x2
  240. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  241. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  242. EXTERN(void) jpeg_idct_1x1
  243. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  244. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  245. EXTERN(void) jpeg_idct_9x9
  246. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  247. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  248. EXTERN(void) jpeg_idct_10x10
  249. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  250. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  251. EXTERN(void) jpeg_idct_11x11
  252. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  253. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  254. EXTERN(void) jpeg_idct_12x12
  255. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  256. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  257. EXTERN(void) jpeg_idct_13x13
  258. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  259. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  260. EXTERN(void) jpeg_idct_14x14
  261. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  262. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  263. EXTERN(void) jpeg_idct_15x15
  264. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  265. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  266. EXTERN(void) jpeg_idct_16x16
  267. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  268. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  269. EXTERN(void) jpeg_idct_16x8
  270. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  271. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  272. EXTERN(void) jpeg_idct_14x7
  273. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  274. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  275. EXTERN(void) jpeg_idct_12x6
  276. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  277. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  278. EXTERN(void) jpeg_idct_10x5
  279. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  280. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  281. EXTERN(void) jpeg_idct_8x4
  282. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  283. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  284. EXTERN(void) jpeg_idct_6x3
  285. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  286. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  287. EXTERN(void) jpeg_idct_4x2
  288. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  289. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  290. EXTERN(void) jpeg_idct_2x1
  291. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  292. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  293. EXTERN(void) jpeg_idct_8x16
  294. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  295. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  296. EXTERN(void) jpeg_idct_7x14
  297. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  298. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  299. EXTERN(void) jpeg_idct_6x12
  300. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  301. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  302. EXTERN(void) jpeg_idct_5x10
  303. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  304. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  305. EXTERN(void) jpeg_idct_4x8
  306. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  307. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  308. EXTERN(void) jpeg_idct_3x6
  309. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  310. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  311. EXTERN(void) jpeg_idct_2x4
  312. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  313. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  314. EXTERN(void) jpeg_idct_1x2
  315. JPP((j_decompress_ptr cinfo, jpeg_component_info * compptr,
  316. JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col));
  317. /*
  318. * Macros for handling fixed-point arithmetic; these are used by many
  319. * but not all of the DCT/IDCT modules.
  320. *
  321. * All values are expected to be of type INT32.
  322. * Fractional constants are scaled left by CONST_BITS bits.
  323. * CONST_BITS is defined within each module using these macros,
  324. * and may differ from one module to the next.
  325. */
  326. #define ONE ((INT32) 1)
  327. #define CONST_SCALE (ONE << CONST_BITS)
  328. /* Convert a positive real constant to an integer scaled by CONST_SCALE.
  329. * Caution: some C compilers fail to reduce "FIX(constant)" at compile time,
  330. * thus causing a lot of useless floating-point operations at run time.
  331. */
  332. #define FIX(x) ((INT32) ((x) * CONST_SCALE + 0.5))
  333. /* Descale and correctly round an INT32 value that's scaled by N bits.
  334. * We assume RIGHT_SHIFT rounds towards minus infinity, so adding
  335. * the fudge factor is correct for either sign of X.
  336. */
  337. #define DESCALE(x,n) RIGHT_SHIFT((x) + (ONE << ((n)-1)), n)
  338. /* Multiply an INT32 variable by an INT32 constant to yield an INT32 result.
  339. * This macro is used only when the two inputs will actually be no more than
  340. * 16 bits wide, so that a 16x16->32 bit multiply can be used instead of a
  341. * full 32x32 multiply. This provides a useful speedup on many machines.
  342. * Unfortunately there is no way to specify a 16x16->32 multiply portably
  343. * in C, but some C compilers will do the right thing if you provide the
  344. * correct combination of casts.
  345. */
  346. #ifdef SHORTxSHORT_32 /* may work if 'int' is 32 bits */
  347. #define MULTIPLY16C16(var,const) (((INT16) (var)) * ((INT16) (const)))
  348. #endif
  349. #ifdef SHORTxLCONST_32 /* known to work with Microsoft C 6.0 */
  350. #define MULTIPLY16C16(var,const) (((INT16) (var)) * ((INT32) (const)))
  351. #endif
  352. #ifndef MULTIPLY16C16 /* default definition */
  353. #define MULTIPLY16C16(var,const) ((var) * (const))
  354. #endif
  355. /* Same except both inputs are variables. */
  356. #ifdef SHORTxSHORT_32 /* may work if 'int' is 32 bits */
  357. #define MULTIPLY16V16(var1,var2) (((INT16) (var1)) * ((INT16) (var2)))
  358. #endif
  359. #ifndef MULTIPLY16V16 /* default definition */
  360. #define MULTIPLY16V16(var1,var2) ((var1) * (var2))
  361. #endif