diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2014-12-13 20:28:24 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2014-12-13 20:28:24 +0000 |
commit | d2d798d0f11abcbf141db69869e76e8d123ec1eb (patch) | |
tree | cee8645964030b4b80231952885911f724850d12 /plugins/AdvaImg/src/LibJPEG/jdinput.c | |
parent | a400ebf572dcad9b43d1b641b1742814f8b5e8a5 (diff) |
FreeImage updated to 3.16
git-svn-id: http://svn.miranda-ng.org/main/trunk@11379 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/AdvaImg/src/LibJPEG/jdinput.c')
-rw-r--r-- | plugins/AdvaImg/src/LibJPEG/jdinput.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/plugins/AdvaImg/src/LibJPEG/jdinput.c b/plugins/AdvaImg/src/LibJPEG/jdinput.c index de6f7ed8e9..80bdef568a 100644 --- a/plugins/AdvaImg/src/LibJPEG/jdinput.c +++ b/plugins/AdvaImg/src/LibJPEG/jdinput.c @@ -2,7 +2,7 @@ * jdinput.c
*
* Copyright (C) 1991-1997, Thomas G. Lane.
- * Modified 2002-2009 by Guido Vollbeding.
+ * Modified 2002-2013 by Guido Vollbeding.
* This file is part of the Independent JPEG Group's software.
* For conditions of distribution and use, see the accompanying README file.
*
@@ -196,7 +196,7 @@ jpeg_core_output_dimensions (j_decompress_ptr cinfo) /* Hardwire it to "no scaling" */
cinfo->output_width = cinfo->image_width;
cinfo->output_height = cinfo->image_height;
- /* jdinput.c has already initialized DCT_scaled_size,
+ /* initial_setup has already initialized DCT_scaled_size,
* and has computed unscaled downsampled_width and downsampled_height.
*/
@@ -216,8 +216,8 @@ initial_setup (j_decompress_ptr cinfo) (long) cinfo->image_width > (long) JPEG_MAX_DIMENSION)
ERREXIT1(cinfo, JERR_IMAGE_TOO_BIG, (unsigned int) JPEG_MAX_DIMENSION);
- /* For now, precision must match compiled-in value... */
- if (cinfo->data_precision != BITS_IN_JSAMPLE)
+ /* Only 8 to 12 bits data precision are supported for DCT based JPEG */
+ if (cinfo->data_precision < 8 || cinfo->data_precision > 12)
ERREXIT1(cinfo, JERR_BAD_PRECISION, cinfo->data_precision);
/* Check that number of components won't exceed internal array sizes */
@@ -537,6 +537,7 @@ start_input_pass (j_decompress_ptr cinfo) METHODDEF(void)
finish_input_pass (j_decompress_ptr cinfo)
{
+ (*cinfo->entropy->finish_pass) (cinfo);
cinfo->inputctl->consume_input = consume_markers;
}
@@ -646,7 +647,7 @@ jinit_input_controller (j_decompress_ptr cinfo) inputctl = (my_inputctl_ptr)
(*cinfo->mem->alloc_small) ((j_common_ptr) cinfo, JPOOL_PERMANENT,
SIZEOF(my_input_controller));
- cinfo->inputctl = (struct jpeg_input_controller *) inputctl;
+ cinfo->inputctl = &inputctl->pub;
/* Initialize method pointers */
inputctl->pub.consume_input = consume_markers;
inputctl->pub.reset_input_controller = reset_input_controller;
|