| Index: core/include/thirdparties/libjpeg/jmorecfg.h
|
| diff --git a/core/include/thirdparties/libjpeg/jmorecfg.h b/core/include/thirdparties/libjpeg/jmorecfg.h
|
| index 88d210954cf8b882241b2ba9e8582068f34cb008..1f2390c65748ddd2c93d2def60aca3f3feef7192 100644
|
| --- a/core/include/thirdparties/libjpeg/jmorecfg.h
|
| +++ b/core/include/thirdparties/libjpeg/jmorecfg.h
|
| @@ -11,7 +11,7 @@
|
| */
|
|
|
| #ifdef _MSC_VER
|
| -#pragma warning (disable : 4142)
|
| +#pragma warning(disable : 4142)
|
| #endif
|
|
|
| /*
|
| @@ -23,8 +23,7 @@
|
| * We do not support run-time selection of data precision, sorry.
|
| */
|
|
|
| -#define BITS_IN_JSAMPLE 8 /* use 8 or 12 */
|
| -
|
| +#define BITS_IN_JSAMPLE 8 /* use 8 or 12 */
|
|
|
| /*
|
| * Maximum number of components (color channels) allowed in JPEG image.
|
| @@ -35,8 +34,7 @@
|
| * bytes of storage, whether actually used in an image or not.)
|
| */
|
|
|
| -#define MAX_COMPONENTS 10 /* maximum number of image components */
|
| -
|
| +#define MAX_COMPONENTS 10 /* maximum number of image components */
|
|
|
| /*
|
| * Basic data types.
|
| @@ -60,39 +58,37 @@
|
| #ifdef HAVE_UNSIGNED_CHAR
|
|
|
| typedef unsigned char JSAMPLE;
|
| -#define GETJSAMPLE(value) ((int) (value))
|
| +#define GETJSAMPLE(value) ((int)(value))
|
|
|
| #else /* not HAVE_UNSIGNED_CHAR */
|
|
|
| typedef char JSAMPLE;
|
| #ifdef CHAR_IS_UNSIGNED
|
| -#define GETJSAMPLE(value) ((int) (value))
|
| +#define GETJSAMPLE(value) ((int)(value))
|
| #else
|
| -#define GETJSAMPLE(value) ((int) (value) & 0xFF)
|
| +#define GETJSAMPLE(value) ((int)(value)&0xFF)
|
| #endif /* CHAR_IS_UNSIGNED */
|
|
|
| #endif /* HAVE_UNSIGNED_CHAR */
|
|
|
| -#define MAXJSAMPLE 255
|
| -#define CENTERJSAMPLE 128
|
| +#define MAXJSAMPLE 255
|
| +#define CENTERJSAMPLE 128
|
|
|
| #endif /* BITS_IN_JSAMPLE == 8 */
|
|
|
| -
|
| #if BITS_IN_JSAMPLE == 12
|
| /* JSAMPLE should be the smallest type that will hold the values 0..4095.
|
| * On nearly all machines "short" will do nicely.
|
| */
|
|
|
| typedef short JSAMPLE;
|
| -#define GETJSAMPLE(value) ((int) (value))
|
| +#define GETJSAMPLE(value) ((int)(value))
|
|
|
| -#define MAXJSAMPLE 4095
|
| -#define CENTERJSAMPLE 2048
|
| +#define MAXJSAMPLE 4095
|
| +#define CENTERJSAMPLE 2048
|
|
|
| #endif /* BITS_IN_JSAMPLE == 12 */
|
|
|
| -
|
| /* Representation of a DCT frequency coefficient.
|
| * This should be a signed value of at least 16 bits; "short" is usually OK.
|
| * Again, we allocate large arrays of these, but you can change to int
|
| @@ -101,7 +97,6 @@ typedef short JSAMPLE;
|
|
|
| typedef short JCOEF;
|
|
|
| -
|
| /* Compressed datastreams are represented as arrays of JOCTET.
|
| * These must be EXACTLY 8 bits wide, at least once they are written to
|
| * external storage. Note that when using the stdio data source/destination
|
| @@ -111,20 +106,19 @@ typedef short JCOEF;
|
| #ifdef HAVE_UNSIGNED_CHAR
|
|
|
| typedef unsigned char JOCTET;
|
| -#define GETJOCTET(value) (value)
|
| +#define GETJOCTET(value) (value)
|
|
|
| #else /* not HAVE_UNSIGNED_CHAR */
|
|
|
| typedef char JOCTET;
|
| #ifdef CHAR_IS_UNSIGNED
|
| -#define GETJOCTET(value) (value)
|
| +#define GETJOCTET(value) (value)
|
| #else
|
| -#define GETJOCTET(value) ((value) & 0xFF)
|
| +#define GETJOCTET(value) ((value)&0xFF)
|
| #endif /* CHAR_IS_UNSIGNED */
|
|
|
| #endif /* HAVE_UNSIGNED_CHAR */
|
|
|
| -
|
| /* These typedefs are used for various table entries and so forth.
|
| * They must be at least as wide as specified; but making them too big
|
| * won't cost a huge amount of memory, so we don't provide special
|
| @@ -141,33 +135,32 @@ typedef unsigned char UINT8;
|
| #else /* not HAVE_UNSIGNED_CHAR */
|
| #ifdef CHAR_IS_UNSIGNED
|
| typedef char UINT8;
|
| -#else /* not CHAR_IS_UNSIGNED */
|
| +#else /* not CHAR_IS_UNSIGNED */
|
| typedef short UINT8;
|
| #endif /* CHAR_IS_UNSIGNED */
|
| #endif /* HAVE_UNSIGNED_CHAR */
|
|
|
| -
|
| /* UINT16 must hold at least the values 0..65535. */
|
|
|
| #ifdef HAVE_UNSIGNED_SHORT
|
| typedef unsigned short UINT16;
|
| -#else /* not HAVE_UNSIGNED_SHORT */
|
| +#else /* not HAVE_UNSIGNED_SHORT */
|
| typedef unsigned int UINT16;
|
| #endif /* HAVE_UNSIGNED_SHORT */
|
|
|
| /* INT16 must hold at least the values -32768..32767. */
|
|
|
| -#ifndef XMD_H /* X11/xmd.h correctly defines INT16 */
|
| +#ifndef XMD_H /* X11/xmd.h correctly defines INT16 */
|
| typedef short INT16;
|
| #endif
|
|
|
| /* INT32 must hold at least signed 32-bit values. */
|
|
|
| -#ifndef XMD_H /* X11/xmd.h correctly defines INT32 */
|
| +#ifndef XMD_H /* X11/xmd.h correctly defines INT32 */
|
| typedef int INT32;
|
| #endif
|
|
|
| -#endif
|
| +#endif
|
|
|
| /* Datatype used for image dimensions. The JPEG standard only supports
|
| * images up to 64K*64K due to 16-bit fields in SOF markers. Therefore
|
| @@ -178,8 +171,7 @@ typedef int INT32;
|
|
|
| typedef unsigned int JDIMENSION;
|
|
|
| -#define JPEG_MAX_DIMENSION 65500L /* a tad under 64K to prevent overflows */
|
| -
|
| +#define JPEG_MAX_DIMENSION 65500L /* a tad under 64K to prevent overflows */
|
|
|
| /* These macros are used in all function definitions and extern declarations.
|
| * You could modify them if you need to change function linkage conventions;
|
| @@ -189,20 +181,19 @@ typedef unsigned int JDIMENSION;
|
| */
|
|
|
| /* a function called through method pointers: */
|
| -#define METHODDEF(type) static type
|
| +#define METHODDEF(type) static type
|
| /* a function used only in its module: */
|
| -#define LOCAL(type) static type
|
| +#define LOCAL(type) static type
|
| /* a function referenced thru EXTERNs: */
|
| -#define GLOBAL(type) type
|
| +#define GLOBAL(type) type
|
|
|
| #ifdef _FX_MANAGED_CODE_
|
| -#define EXTERN(type) extern "C" type
|
| +#define EXTERN(type) extern "C" type
|
| #else
|
| /* a reference to a GLOBAL function: */
|
| -#define EXTERN(type) extern type
|
| +#define EXTERN(type) extern type
|
| #endif
|
|
|
| -
|
| /* This macro is used to declare a "method", that is, a function pointer.
|
| * We want to supply prototype parameters if the compiler can cope.
|
| * Note that the arglist parameter must be parenthesized!
|
| @@ -210,12 +201,11 @@ typedef unsigned int JDIMENSION;
|
| */
|
|
|
| #ifdef HAVE_PROTOTYPES
|
| -#define JMETHOD(type,methodname,arglist) type (*methodname) arglist
|
| +#define JMETHOD(type, methodname, arglist) type(*methodname) arglist
|
| #else
|
| -#define JMETHOD(type,methodname,arglist) type (*methodname) ()
|
| +#define JMETHOD(type, methodname, arglist) type (*methodname)()
|
| #endif
|
|
|
| -
|
| /* Here is the pseudo-keyword for declaring pointers that must be "far"
|
| * on 80x86 machines. Most of the specialized coding for 80x86 is handled
|
| * by just saying "FAR *" where such a pointer is needed. In a few places
|
| @@ -223,12 +213,11 @@ typedef unsigned int JDIMENSION;
|
| */
|
|
|
| #ifdef NEED_FAR_POINTERS
|
| -#define FAR far
|
| +#define FAR far
|
| #else
|
| //#define FAR
|
| #endif
|
|
|
| -
|
| /*
|
| * On a few systems, type boolean and/or its values FALSE, TRUE may appear
|
| * in standard header files. Or you may have conflicts with application-
|
| @@ -239,14 +228,13 @@ typedef unsigned int JDIMENSION;
|
| #ifndef HAVE_BOOLEAN
|
| typedef int boolean;
|
| #endif
|
| -#ifndef FALSE /* in case these macros already exist */
|
| -#define FALSE 0 /* values of boolean */
|
| +#ifndef FALSE /* in case these macros already exist */
|
| +#define FALSE 0 /* values of boolean */
|
| #endif
|
| #ifndef TRUE
|
| -#define TRUE 1
|
| +#define TRUE 1
|
| #endif
|
|
|
| -
|
| /*
|
| * The remaining options affect code selection within the JPEG library,
|
| * but they don't need to be visible to most applications using the library.
|
| @@ -260,7 +248,6 @@ typedef int boolean;
|
|
|
| #ifdef JPEG_INTERNAL_OPTIONS
|
|
|
| -
|
| /*
|
| * These defines indicate whether to include various optional functions.
|
| * Undefining some of these symbols will produce a smaller but less capable
|
| @@ -273,16 +260,16 @@ typedef int boolean;
|
|
|
| /* Capability options common to encoder and decoder: */
|
|
|
| -#define DCT_ISLOW_SUPPORTED /* slow but accurate integer algorithm */
|
| -#define DCT_IFAST_SUPPORTED /* faster, less accurate integer method */
|
| -#undef DCT_FLOAT_SUPPORTED /* floating-point: accurate, fast on fast HW */
|
| +#define DCT_ISLOW_SUPPORTED /* slow but accurate integer algorithm */
|
| +#define DCT_IFAST_SUPPORTED /* faster, less accurate integer method */
|
| +#undef DCT_FLOAT_SUPPORTED /* floating-point: accurate, fast on fast HW */
|
|
|
| /* Encoder capability options: */
|
|
|
| -#undef C_ARITH_CODING_SUPPORTED /* Arithmetic coding back end? */
|
| +#undef C_ARITH_CODING_SUPPORTED /* Arithmetic coding back end? */
|
| #define C_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */
|
| -#define C_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires MULTISCAN)*/
|
| -#define ENTROPY_OPT_SUPPORTED /* Optimization of entropy coding parms? */
|
| +#define C_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires MULTISCAN)*/
|
| +#define ENTROPY_OPT_SUPPORTED /* Optimization of entropy coding parms? */
|
| /* Note: if you selected 12-bit data precision, it is dangerous to turn off
|
| * ENTROPY_OPT_SUPPORTED. The standard Huffman tables are only good for 8-bit
|
| * precision, so jchuff.c normally uses entropy optimization to compute
|
| @@ -291,24 +278,23 @@ typedef int boolean;
|
| * The exact same statements apply for progressive JPEG: the default tables
|
| * don't work for progressive mode. (This may get fixed, however.)
|
| */
|
| -#define INPUT_SMOOTHING_SUPPORTED /* Input image smoothing option? */
|
| +#define INPUT_SMOOTHING_SUPPORTED /* Input image smoothing option? */
|
|
|
| /* Decoder capability options: */
|
|
|
| -#undef D_ARITH_CODING_SUPPORTED /* Arithmetic coding back end? */
|
| +#undef D_ARITH_CODING_SUPPORTED /* Arithmetic coding back end? */
|
| #define D_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */
|
| -#define D_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires MULTISCAN)*/
|
| -#define SAVE_MARKERS_SUPPORTED /* jpeg_save_markers() needed? */
|
| +#define D_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires MULTISCAN)*/
|
| +#define SAVE_MARKERS_SUPPORTED /* jpeg_save_markers() needed? */
|
| #define BLOCK_SMOOTHING_SUPPORTED /* Block smoothing? (Progressive only) */
|
| -#define IDCT_SCALING_SUPPORTED /* Output rescaling via IDCT? */
|
| -#undef UPSAMPLE_SCALING_SUPPORTED /* Output rescaling at upsample stage? */
|
| +#define IDCT_SCALING_SUPPORTED /* Output rescaling via IDCT? */
|
| +#undef UPSAMPLE_SCALING_SUPPORTED /* Output rescaling at upsample stage? */
|
| #define UPSAMPLE_MERGING_SUPPORTED /* Fast path for sloppy upsampling? */
|
| -#undef QUANT_1PASS_SUPPORTED /* 1-pass color quantization? */
|
| -#undef QUANT_2PASS_SUPPORTED /* 2-pass color quantization? */
|
| +#undef QUANT_1PASS_SUPPORTED /* 1-pass color quantization? */
|
| +#undef QUANT_2PASS_SUPPORTED /* 2-pass color quantization? */
|
|
|
| /* more capability options later, no doubt */
|
|
|
| -
|
| /*
|
| * Ordering of RGB data in scanlines passed to or from the application.
|
| * If your application wants to deal with data in the order B,G,R, just
|
| @@ -324,39 +310,35 @@ typedef int boolean;
|
| * can't use color quantization if you change that value.
|
| */
|
|
|
| -#define RGB_RED 0 /* Offset of Red in an RGB scanline element */
|
| -#define RGB_GREEN 1 /* Offset of Green */
|
| -#define RGB_BLUE 2 /* Offset of Blue */
|
| -#define RGB_PIXELSIZE 3 /* JSAMPLEs per RGB scanline element */
|
| -
|
| +#define RGB_RED 0 /* Offset of Red in an RGB scanline element */
|
| +#define RGB_GREEN 1 /* Offset of Green */
|
| +#define RGB_BLUE 2 /* Offset of Blue */
|
| +#define RGB_PIXELSIZE 3 /* JSAMPLEs per RGB scanline element */
|
|
|
| /* Definitions for speed-related optimizations. */
|
|
|
| -
|
| /* If your compiler supports inline functions, define INLINE
|
| * as the inline keyword; otherwise define it as empty.
|
| */
|
|
|
| #ifndef INLINE
|
| -#ifdef __GNUC__ /* for instance, GNU C knows about inline */
|
| +#ifdef __GNUC__ /* for instance, GNU C knows about inline */
|
| #define INLINE __inline__
|
| #endif
|
| #ifndef INLINE
|
| -#define INLINE /* default is to define it as empty */
|
| +#define INLINE /* default is to define it as empty */
|
| #endif
|
| #endif
|
|
|
| -
|
| /* On some machines (notably 68000 series) "int" is 32 bits, but multiplying
|
| * two 16-bit shorts is faster than multiplying two ints. Define MULTIPLIER
|
| * as short on such a machine. MULTIPLIER must be at least 16 bits wide.
|
| */
|
|
|
| #ifndef MULTIPLIER
|
| -#define MULTIPLIER int /* type for fastest integer multiply */
|
| +#define MULTIPLIER int /* type for fastest integer multiply */
|
| #endif
|
|
|
| -
|
| /* FAST_FLOAT should be either float or double, whichever is done faster
|
| * by your compiler. (Note that this type is only used in the floating point
|
| * DCT routines, so it only matters if you've defined DCT_FLOAT_SUPPORTED.)
|
| @@ -367,9 +349,9 @@ typedef int boolean;
|
|
|
| #ifndef FAST_FLOAT
|
| #ifdef HAVE_PROTOTYPES
|
| -#define FAST_FLOAT float
|
| +#define FAST_FLOAT float
|
| #else
|
| -#define FAST_FLOAT double
|
| +#define FAST_FLOAT double
|
| #endif
|
| #endif
|
|
|
|
|