Index: third_party/libjpeg_turbo/jcapimin.c |
=================================================================== |
--- third_party/libjpeg_turbo/jcapimin.c (revision 95020) |
+++ third_party/libjpeg_turbo/jcapimin.c (working copy) |
@@ -2,6 +2,7 @@ |
* jcapimin.c |
* |
* Copyright (C) 1994-1998, Thomas G. Lane. |
+ * Modified 2003-2010 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. |
* |
@@ -63,14 +64,25 @@ |
cinfo->comp_info = NULL; |
- for (i = 0; i < NUM_QUANT_TBLS; i++) |
+ for (i = 0; i < NUM_QUANT_TBLS; i++) { |
cinfo->quant_tbl_ptrs[i] = NULL; |
+#if JPEG_LIB_VERSION >= 70 |
+ cinfo->q_scale_factor[i] = 100; |
+#endif |
+ } |
for (i = 0; i < NUM_HUFF_TBLS; i++) { |
cinfo->dc_huff_tbl_ptrs[i] = NULL; |
cinfo->ac_huff_tbl_ptrs[i] = NULL; |
} |
+#if JPEG_LIB_VERSION >= 80 |
+ /* Must do it here for emit_dqt in case jpeg_write_tables is used */ |
+ cinfo->block_size = DCTSIZE; |
+ cinfo->natural_order = jpeg_natural_order; |
+ cinfo->lim_Se = DCTSIZE2-1; |
+#endif |
+ |
cinfo->script_space = NULL; |
cinfo->input_gamma = 1.0; /* in case application forgets */ |