OLD | NEW |
1 /* | 1 /* |
2 * jmorecfg.h | 2 * jmorecfg.h |
3 * | 3 * |
4 * This file was part of the Independent JPEG Group's software: | 4 * This file was part of the Independent JPEG Group's software: |
5 * Copyright (C) 1991-1997, Thomas G. Lane. | 5 * Copyright (C) 1991-1997, Thomas G. Lane. |
6 * Modifications: | 6 * Modifications: |
7 * Copyright (C) 2009, 2011, D. R. Commander. | 7 * Copyright (C) 2009, 2011, 2014, D. R. Commander. |
8 * For conditions of distribution and use, see the accompanying README file. | 8 * For conditions of distribution and use, see the accompanying README file. |
9 * | 9 * |
10 * This file contains additional configuration options that customize the | 10 * This file contains additional configuration options that customize the |
11 * JPEG software for special applications or support machine-dependent | 11 * JPEG software for special applications or support machine-dependent |
12 * optimizations. Most users will not need to touch this file. | 12 * optimizations. Most users will not need to touch this file. |
13 */ | 13 */ |
14 | 14 |
15 | 15 |
16 /* | 16 /* |
17 * Define BITS_IN_JSAMPLE as either | 17 * Define BITS_IN_JSAMPLE as either |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
316 * 3. The color quantizer modules will not behave desirably if RGB_PIXELSIZE | 316 * 3. The color quantizer modules will not behave desirably if RGB_PIXELSIZE |
317 * is not 3 (they don't understand about dummy color components!). So you | 317 * is not 3 (they don't understand about dummy color components!). So you |
318 * can't use color quantization if you change that value. | 318 * can't use color quantization if you change that value. |
319 */ | 319 */ |
320 | 320 |
321 #define RGB_RED 0 /* Offset of Red in an RGB scanline element */ | 321 #define RGB_RED 0 /* Offset of Red in an RGB scanline element */ |
322 #define RGB_GREEN 1 /* Offset of Green */ | 322 #define RGB_GREEN 1 /* Offset of Green */ |
323 #define RGB_BLUE 2 /* Offset of Blue */ | 323 #define RGB_BLUE 2 /* Offset of Blue */ |
324 #define RGB_PIXELSIZE 3 /* JSAMPLEs per RGB scanline element */ | 324 #define RGB_PIXELSIZE 3 /* JSAMPLEs per RGB scanline element */ |
325 | 325 |
326 #define JPEG_NUMCS 16 | 326 #define JPEG_NUMCS 17 |
327 | 327 |
328 #define EXT_RGB_RED 0 | 328 #define EXT_RGB_RED 0 |
329 #define EXT_RGB_GREEN 1 | 329 #define EXT_RGB_GREEN 1 |
330 #define EXT_RGB_BLUE 2 | 330 #define EXT_RGB_BLUE 2 |
331 #define EXT_RGB_PIXELSIZE 3 | 331 #define EXT_RGB_PIXELSIZE 3 |
332 | 332 |
333 #define EXT_RGBX_RED 0 | 333 #define EXT_RGBX_RED 0 |
334 #define EXT_RGBX_GREEN 1 | 334 #define EXT_RGBX_GREEN 1 |
335 #define EXT_RGBX_BLUE 2 | 335 #define EXT_RGBX_BLUE 2 |
336 #define EXT_RGBX_PIXELSIZE 4 | 336 #define EXT_RGBX_PIXELSIZE 4 |
(...skipping 14 matching lines...) Expand all Loading... |
351 #define EXT_XBGR_PIXELSIZE 4 | 351 #define EXT_XBGR_PIXELSIZE 4 |
352 | 352 |
353 #define EXT_XRGB_RED 1 | 353 #define EXT_XRGB_RED 1 |
354 #define EXT_XRGB_GREEN 2 | 354 #define EXT_XRGB_GREEN 2 |
355 #define EXT_XRGB_BLUE 3 | 355 #define EXT_XRGB_BLUE 3 |
356 #define EXT_XRGB_PIXELSIZE 4 | 356 #define EXT_XRGB_PIXELSIZE 4 |
357 | 357 |
358 static const int rgb_red[JPEG_NUMCS] = { | 358 static const int rgb_red[JPEG_NUMCS] = { |
359 -1, -1, RGB_RED, -1, -1, -1, EXT_RGB_RED, EXT_RGBX_RED, | 359 -1, -1, RGB_RED, -1, -1, -1, EXT_RGB_RED, EXT_RGBX_RED, |
360 EXT_BGR_RED, EXT_BGRX_RED, EXT_XBGR_RED, EXT_XRGB_RED, | 360 EXT_BGR_RED, EXT_BGRX_RED, EXT_XBGR_RED, EXT_XRGB_RED, |
361 EXT_RGBX_RED, EXT_BGRX_RED, EXT_XBGR_RED, EXT_XRGB_RED | 361 EXT_RGBX_RED, EXT_BGRX_RED, EXT_XBGR_RED, EXT_XRGB_RED, |
| 362 -1 |
362 }; | 363 }; |
363 | 364 |
364 static const int rgb_green[JPEG_NUMCS] = { | 365 static const int rgb_green[JPEG_NUMCS] = { |
365 -1, -1, RGB_GREEN, -1, -1, -1, EXT_RGB_GREEN, EXT_RGBX_GREEN, | 366 -1, -1, RGB_GREEN, -1, -1, -1, EXT_RGB_GREEN, EXT_RGBX_GREEN, |
366 EXT_BGR_GREEN, EXT_BGRX_GREEN, EXT_XBGR_GREEN, EXT_XRGB_GREEN, | 367 EXT_BGR_GREEN, EXT_BGRX_GREEN, EXT_XBGR_GREEN, EXT_XRGB_GREEN, |
367 EXT_RGBX_GREEN, EXT_BGRX_GREEN, EXT_XBGR_GREEN, EXT_XRGB_GREEN | 368 EXT_RGBX_GREEN, EXT_BGRX_GREEN, EXT_XBGR_GREEN, EXT_XRGB_GREEN, |
| 369 -1 |
368 }; | 370 }; |
369 | 371 |
370 static const int rgb_blue[JPEG_NUMCS] = { | 372 static const int rgb_blue[JPEG_NUMCS] = { |
371 -1, -1, RGB_BLUE, -1, -1, -1, EXT_RGB_BLUE, EXT_RGBX_BLUE, | 373 -1, -1, RGB_BLUE, -1, -1, -1, EXT_RGB_BLUE, EXT_RGBX_BLUE, |
372 EXT_BGR_BLUE, EXT_BGRX_BLUE, EXT_XBGR_BLUE, EXT_XRGB_BLUE, | 374 EXT_BGR_BLUE, EXT_BGRX_BLUE, EXT_XBGR_BLUE, EXT_XRGB_BLUE, |
373 EXT_RGBX_BLUE, EXT_BGRX_BLUE, EXT_XBGR_BLUE, EXT_XRGB_BLUE | 375 EXT_RGBX_BLUE, EXT_BGRX_BLUE, EXT_XBGR_BLUE, EXT_XRGB_BLUE, |
| 376 -1 |
374 }; | 377 }; |
375 | 378 |
376 static const int rgb_pixelsize[JPEG_NUMCS] = { | 379 static const int rgb_pixelsize[JPEG_NUMCS] = { |
377 -1, -1, RGB_PIXELSIZE, -1, -1, -1, EXT_RGB_PIXELSIZE, EXT_RGBX_PIXELSIZE, | 380 -1, -1, RGB_PIXELSIZE, -1, -1, -1, EXT_RGB_PIXELSIZE, EXT_RGBX_PIXELSIZE, |
378 EXT_BGR_PIXELSIZE, EXT_BGRX_PIXELSIZE, EXT_XBGR_PIXELSIZE, EXT_XRGB_PIXELSIZE, | 381 EXT_BGR_PIXELSIZE, EXT_BGRX_PIXELSIZE, EXT_XBGR_PIXELSIZE, EXT_XRGB_PIXELSIZE, |
379 EXT_RGBX_PIXELSIZE, EXT_BGRX_PIXELSIZE, EXT_XBGR_PIXELSIZE, EXT_XRGB_PIXELSIZE | 382 EXT_RGBX_PIXELSIZE, EXT_BGRX_PIXELSIZE, EXT_XBGR_PIXELSIZE, EXT_XRGB_PIXELSIZE
, |
| 383 -1 |
380 }; | 384 }; |
381 | 385 |
382 /* Definitions for speed-related optimizations. */ | 386 /* Definitions for speed-related optimizations. */ |
383 | 387 |
384 /* On some machines (notably 68000 series) "int" is 32 bits, but multiplying | 388 /* On some machines (notably 68000 series) "int" is 32 bits, but multiplying |
385 * two 16-bit shorts is faster than multiplying two ints. Define MULTIPLIER | 389 * two 16-bit shorts is faster than multiplying two ints. Define MULTIPLIER |
386 * as short on such a machine. MULTIPLIER must be at least 16 bits wide. | 390 * as short on such a machine. MULTIPLIER must be at least 16 bits wide. |
387 */ | 391 */ |
388 | 392 |
389 #ifndef MULTIPLIER | 393 #ifndef MULTIPLIER |
(...skipping 15 matching lines...) Expand all Loading... |
405 | 409 |
406 #ifndef FAST_FLOAT | 410 #ifndef FAST_FLOAT |
407 #ifdef HAVE_PROTOTYPES | 411 #ifdef HAVE_PROTOTYPES |
408 #define FAST_FLOAT float | 412 #define FAST_FLOAT float |
409 #else | 413 #else |
410 #define FAST_FLOAT double | 414 #define FAST_FLOAT double |
411 #endif | 415 #endif |
412 #endif | 416 #endif |
413 | 417 |
414 #endif /* JPEG_INTERNAL_OPTIONS */ | 418 #endif /* JPEG_INTERNAL_OPTIONS */ |
OLD | NEW |