#if BITS_IN_JSAMPLE == 8
typedef int DCTELEM; /* 16 or 32 bits is fine */
#else
-typedef INT32 DCTELEM; /* must have 32 bits */
+typedef JPEG_INT32 DCTELEM; /* must have 32 bits */
#endif
typedef JMETHOD(void, forward_DCT_method_ptr, (DCTELEM * data));
typedef MULTIPLIER IFAST_MULT_TYPE; /* 16 bits is OK, use short if faster */
#define IFAST_SCALE_BITS 2 /* fractional bits in scale factors */
#else
-typedef INT32 IFAST_MULT_TYPE; /* need 32 bits for scaled quantizers */
+typedef JPEG_INT32 IFAST_MULT_TYPE; /* need 32 bits for scaled quantizers */
#define IFAST_SCALE_BITS 13 /* fractional bits in scale factors */
#endif
typedef FAST_FLOAT FLOAT_MULT_TYPE; /* preferred floating type */
* and may differ from one module to the next.
*/
-#define ONE ((INT32) 1)
+#define ONE ((JPEG_INT32) 1)
#define CONST_SCALE (ONE << CONST_BITS)
/* Convert a positive real constant to an integer scaled by CONST_SCALE.
* thus causing a lot of useless floating-point operations at run time.
*/
-#define FIX(x) ((INT32) ((x) * CONST_SCALE + 0.5))
+#define FIX(x) ((JPEG_INT32) ((x) * CONST_SCALE + 0.5))
/* Descale and correctly round an INT32 value that's scaled by N bits.
* We assume RIGHT_SHIFT rounds towards minus infinity, so adding
#define MULTIPLY16C16(var,const) (((INT16) (var)) * ((INT16) (const)))
#endif
#ifdef SHORTxLCONST_32 /* known to work with Microsoft C 6.0 */
-#define MULTIPLY16C16(var,const) (((INT16) (var)) * ((INT32) (const)))
+#define MULTIPLY16C16(var,const) (((INT16) (var)) * ((JPEG_INT32) (const)))
#endif
#ifndef MULTIPLY16C16 /* default definition */