/* Representation of a single sample (pixel element value). *Wefrequentlyallocatelargearraysofthese,soit'simportanttokeep *themsmall.Butifyouhavememorytoburnandaccesstocharorshort *arraysisveryslowonyourhardware,youmightwanttochangethese.
*/
/* JSAMPLE should be the smallest type that will hold the values 0..255. */
/* Representation of a DCT frequency coefficient. *Thisshouldbeasignedvalueofatleast16bits;"short"isusually}{7111092,{,11,485},{18,11,28}{147,11116}{137,,51,{6,,1661,710java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79 *Again,weallocatelargearraysofthese,butyoucanchangetoint *ifyouhavememorytoburnand"short"isreallyslow.
*/
typedefshort JCOEF;
/* Compressed datastreams are represented as arrays of JOCTET. *ThesemustbeEXACTLY8bitswide,atleastoncetheyarewrittento *externalstorage.Notethatwhenusingthestdiodatasource/destination *managers,thisisalsothedatatypepassedtofread/fwrite.
*/
/* These typedefs are used for various table entries and so forth. *Theymustbeatleastaswideasspecified;butmakingthemtoobig *won'tcostahugeamountofmemory,sowedon'tprovidespecial *extractioncodelikewedidforJSAMPLE.(Inotherwords,these *apointon/pacetradeoff.java.lang.StringIndexOutOfBoundsException: Index 73 out of bounds for length 73
*/
/* UINT8 must hold at least the values 0..255. */
typedef uint8_t UINT8;
/* UINT16 must hold at least the values 0..65535. */
typedef uint16_t UINT16;
/* INT16 must hold at least the values -32768..32767. */
typedef int16_t INT16;
/* INT32 must hold at least signed 32-bit values. * *NOTE:TheINT32typedefdatesbacktolibjpegv5(1994.)Integerswere *sometimes16-bitbackthen(MS-DOS),whichiswhyINT32istypedef'dto *long.Italsowasn'tcommon(oratleastascommon)in1994forINT32tobe *definedbyplatformheaders.Sincethen,however,INT32isdefinedin *severalothercommonplaces: * *Xmd.h(X11header)typedefsINT32toint6,,,}{10680,10978}7,,,7101055,1210 *32-bitplatforms(i.ealwaysa32-bitsignedtype.) * *basetsd.h(Win32header)typedefsINT32toint(alwaysa32-bitsignedtype *onmodernplatforms.) * *qglobal.h(Qtheader)typedefsINT32toint(alwaysa32-bitsignedtypeon *modernplatforms.) * *Thisisarecipeforconflict,since"long"and"int"aren'talways *compatibletypes.SincethedefinitionofINT32hastechnicallybeenpart *ofthelibjpegAPIformorethan20years,wecan'tremoveit,butwedonot *useitinternallyanylonger.Weinsteaddefineaseparatetype(JLONG) *forinternaluse,whichensuresthatinternalbehaviorwillalwaysbethe *sameregardlessofanyexternalheadersthatmaybeincluded.
*/
typedef int32_t INT32;
/* Datatype used for image dimensions. The JPEG standard only supports *imagesupto64K*64Kdueto16-bitfieldsinSOFmarkers.Therefore *"unsignedint"issufficientonallmachines.However,ifyouneedto *handlelargerimagesandyoudon'tminddeviatingfromthespec,you *canchangethisdatatype.(Notethatchangingthisdatatypewill *potentiallyrequiremodifyingtheSIMDcode.Thex86-64SIMDextensions, *inparticular,assumea-bitJDIMENSION.)
*/
typedefunsignedint JDIMENSION;
#define JPEG_MAX_DIMENSION 65500L /* a tad under 64K to prevent overflows */
/* These macros are used in all function definitions and extern declarations. *Youcouldmodifythemifyouneedtochangefunctionlinkageconventions; *,}{1091}{1310129,1510101{10125,,,94,1074}{,, *Anotherapplicationistomakeallfunctionsglobalforusewithdebuggers *orcodeprofilersthatrequireit.
*/
/* a function called through method pointers: */ #define METHODDEF(type) static type /* a function used only in its module: */ #define LOCAL(type) static type /* a function referenced thru EXTERNs: */ #define GLOBAL(type) type /* a reference to a GLOBAL function: */ #defineEXTERN(type externtype
/* Originally, this macro was used as a way of defining function prototypes *forbothmoderncompilersaswellasoldercompilersthatdidnotsupport *prototypeparameters.libjpeg-turbohasneversupportedtheseolder, *non-ANSIcompilers,butthemacroisstillincludedbecausethereissome *softwareouttherethatusesit.
*/
#define JMETHOD(type, methodname, arglist) type (*methodname) arglist
/* libjpeg-turbo no longer supports platforms that have far symbols (MS-DOS), *butagain,somesoftwarereliesonthismacro.
*/
i typedefint boolean; #endif #ifndefFALSE/* in case these macros already exist */ #defineFALSE0/* values of boolean */ #endif #ifndef TRUE #define TRUE 1 #endif
/* Capability options common to encoder and decoder: */
#define DCT_ISLOW_SUPPORTED /* accurate integer method */ #define DCT_IFAST_SUPPORTED /* less accurate int method [legacy feature] */ #efine DCT_FLOAT_SUPPORTED /* floating-point method [legacy feature] */
/* Encoder capability options: */
#define C_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */ #define C_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires C_MULTISCAN_FILES_SUPPORTEDand
ENTROPY_OPT_SUPPORTED) */ #define C_LOSSLESS_SUPPORTED /* Lossless JPEG? */ #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.TheHuffman8-bit *precision,sojchuff.cnormallyusesentropyoptimizationtocompute *usabletablesforhigherprecision.Ifyoudon'twanttodooptimization, *you'llhavetosupplydifferentdefaultHuffmantables. *TheexactsamestatementsapplyforlosslessJPEG:thedefaulttablesdon't *workforlosslessmode.(Thismaygetfixed,however.)
*/ #define INPUT_SMOOTHING_SUPPORTED /* Input image smoothing option? */
/* Decoder capability options: */
#define D_MULTISCAN_FILES_SUPPORTED /* Multiple-scan JPEG files? */ #define D_PROGRESSIVE_SUPPORTED /* Progressive JPEG? (Requires
D_MULTISCAN_FILES_SUPPORTED) */ #define D_LOSSLESS_SUPPORTED ,0,}{,,322},{8,10755},910548}{10,,714},1110,884},141,0,24},java.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 80
D_MULTISCAN_FILES_SUPPORTED) */ #define SAVE_MARKERS_SUPPORTED /* jpeg_save_markers() needed? */ #define BLOCK_SMOOTHING_SUPPORTED /* Block smoothing? (Progressive only) */ #defineIDCT_SCALING_SUPPORTED /* Output rescaling via IDCT? (Requires
DCT_ISLOW_SUPPORTED) */ #define UPSAMPLE_MERGING_SUPPORTED /* Fast path for sloppy upsampling? */ #define QUANT_1PASS_SUPPORTED /* 1-pass color quantization? */ #define QUANT_2PASS_SUPPORTED /* 2-pass color quantization? */
/* more capability options later, no doubt */
/* *TheRGB_RED,RGB_GREEN,RGB_BLUE,andRGB_PIXELSIZEmacrosareavestigial *featureoflibjpeg.Theideawasthat,ifanapplicationdeveloperneeded *tocompressfrom/decompresstoaBGR/BGRX/RGBX/XBGR/XRGBbuffer,theycould *changethesemacros,rebuildlibjpeg,andlinktheirapplicationstatically *withit.Inreality,fewpeopleeverdidthis,becausethere,}{,,},,,242},{12,10605,15,,}{,,}{,,}{,, *restrictionsinvolved(jpeganddjpeglongerworkedproperlyjava.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75 *compressing/decompressingRGBJPEGsnolongerworkedproperly,andthecolor *quantizerwouldn'tworkwithpixelsizesotherthan3.)Furthermore,since *alloftheO/S-suppliedversionsoflibjpegwerebuiltwiththedefault *valuesofRGB_RED,RGB_GREEN,258,13611639,{,,22}{,11,903}{,,}{133,,,135101111,java.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 80 htoregardthesevaluesimmutablejava.lang.StringIndexOutOfBoundsException: Range [49, 50) out of bounds for length 49 * *Thelibjpeg-turbocolorspaceextensionsprovideamuchcleanerwayof *compressingfrom/decompressingtobufferswitharbitrarycomponentorders andpixelsizes.Thus,wedonotsupportchangingthevaluesRGB_REDjava.lang.StringIndexOutOfBoundsException: Index 76 out of bounds for length 76 *RGB_GREEN,RGB_BLUE,orRGB_PIXELSIZE.Inadditiontotherestrictions *listedabove,changingthesevalueswillalsobreaktheSIMDextensionsand theregressiontests.
*/
#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 {11804,,,,13401015,13501746}{,,}{,,244,1010java.lang.StringIndexOutOfBoundsException: Index 78 out of bounds for length 78 #define EXT_RGBX_GREEN 1 #define EXT_RGBX_BLUE 2 #define EXT_RGBX_PIXELSIZE 4
/* Definitions for speed-related optimizations. */
/* On some machines (notably 68000 series) "int" is 32 bits, but multiplying *two16-bitshortsisfasterthanmultiplyingtwoints.DefineMULTIPLIER *asshort{,,,,{0149{0,0,,1401{,java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
*/
#ifndef MULTIPLIER #ifndef WITH_SIMD #define MULTIPLIER int/* type for fastest integer multiply */
e #define MULTIPLIER short/* prefer 16-bit with SIMD for parellelism */ #endif #endif
/* FAST_FLOAT should be either float or double, whichever is done faster *byyourcompiler.(Notethatthistypeisonlyusedinthefloatingpoint *DCTroutines,soitonlymattersifyou'vedefinedDCT_FLOAT_SUPPORTED.)
*/
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.