Skip to content

Commit 6cedc82

Browse files
committed
Merge pull request opencv#10274 from alalek:update_3rdparty
2 parents d0d2faf + cd41761 commit 6cedc82

File tree

333 files changed

+43504
-37502
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

333 files changed

+43504
-37502
lines changed

3rdparty/libjasper/CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,9 @@ endif(WIN32 AND NOT MINGW)
2525

2626
ocv_warnings_disable(CMAKE_C_FLAGS -Wno-implicit-function-declaration -Wno-uninitialized -Wmissing-prototypes
2727
-Wno-unused-but-set-parameter -Wmissing-declarations -Wunused -Wshadow
28-
-Wsign-compare -Wstrict-overflow -Wpointer-compare)
28+
-Wsign-compare -Wstrict-overflow -Wpointer-compare
29+
-Wabsolute-value # clang on Linux
30+
)
2931
ocv_warnings_disable(CMAKE_C_FLAGS -Wunused-parameter -Wstrict-prototypes) # clang
3032
ocv_warnings_disable(CMAKE_C_FLAGS /wd4013 /wd4018 /wd4101 /wd4244 /wd4267 /wd4715) # vs2005
3133

3rdparty/libjpeg/README

Lines changed: 66 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
The Independent JPEG Group's JPEG software
22
==========================================
33

4-
README for release 9 of 13-Jan-2013
5-
===================================
4+
README for release 9b of 17-Jan-2016
5+
====================================
66

77
This distribution contains the ninth public release of the Independent JPEG
88
Group's free JPEG software. You are welcome to redistribute this software and
@@ -14,7 +14,7 @@ Julian Minguillon, Luis Ortiz, George Phillips, Davide Rossi, Ge' Weijers,
1414
and other members of the Independent JPEG Group.
1515

1616
IJG is not affiliated with the ISO/IEC JTC1/SC29/WG1 standards committee
17-
(also known as JPEG, together with ITU-T SG16).
17+
(previously known as JPEG, together with ITU-T SG16).
1818

1919

2020
DOCUMENTATION ROADMAP
@@ -60,7 +60,7 @@ OVERVIEW
6060

6161
This package contains C software to implement JPEG image encoding, decoding,
6262
and transcoding. JPEG (pronounced "jay-peg") is a standardized compression
63-
method for full-color and gray-scale images.
63+
method for full-color and grayscale images.
6464

6565
This software implements JPEG baseline, extended-sequential, and progressive
6666
compression processes. Provision is made for supporting all variants of these
@@ -115,7 +115,7 @@ with respect to this software, its quality, accuracy, merchantability, or
115115
fitness for a particular purpose. This software is provided "AS IS", and you,
116116
its user, assume the entire risk as to its quality and accuracy.
117117

118-
This software is copyright (C) 1991-2013, Thomas G. Lane, Guido Vollbeding.
118+
This software is copyright (C) 1991-2016, Thomas G. Lane, Guido Vollbeding.
119119
All Rights Reserved except as specified below.
120120

121121
Permission is hereby granted to use, copy, modify, and distribute this
@@ -153,16 +153,11 @@ ltmain.sh). Another support script, install-sh, is copyright by X Consortium
153153
but is also freely distributable.
154154

155155
The IJG distribution formerly included code to read and write GIF files.
156-
To avoid entanglement with the Unisys LZW patent, GIF reading support has
157-
been removed altogether, and the GIF writer has been simplified to produce
158-
"uncompressed GIFs". This technique does not use the LZW algorithm; the
159-
resulting GIF files are larger than usual, but are readable by all standard
160-
GIF decoders.
161-
162-
We are required to state that
163-
"The Graphics Interchange Format(c) is the Copyright property of
164-
CompuServe Incorporated. GIF(sm) is a Service Mark property of
165-
CompuServe Incorporated."
156+
To avoid entanglement with the Unisys LZW patent (now expired), GIF reading
157+
support has been removed altogether, and the GIF writer has been simplified
158+
to produce "uncompressed GIFs". This technique does not use the LZW
159+
algorithm; the resulting GIF files are larger than usual, but are readable
160+
by all standard GIF decoders.
166161

167162

168163
REFERENCES
@@ -176,8 +171,8 @@ The best short technical introduction to the JPEG compression algorithm is
176171
Communications of the ACM, April 1991 (vol. 34 no. 4), pp. 30-44.
177172
(Adjacent articles in that issue discuss MPEG motion picture compression,
178173
applications of JPEG, and related topics.) If you don't have the CACM issue
179-
handy, a PostScript file containing a revised version of Wallace's article is
180-
available at http://www.ijg.org/files/wallace.ps.gz. The file (actually
174+
handy, a PDF file containing a revised version of Wallace's article is
175+
available at http://www.ijg.org/files/Wallace.JPEG.pdf. The file (actually
181176
a preprint for an article that appeared in IEEE Trans. Consumer Electronics)
182177
omits the sample images that appeared in CACM, but it includes corrections
183178
and some added material. Note: the Wallace article is copyright ACM and IEEE,
@@ -225,14 +220,13 @@ WG1 N 6080 with title "JPEG 9 Lossless Coding", June/July 2012, Paris,
225220
France.
226221

227222
The JPEG standard does not specify all details of an interchangeable file
228-
format. For the omitted details we follow the "JFIF" conventions, revision
229-
1.02. JFIF 1.02 has been adopted as an Ecma International Technical Report
230-
and thus received a formal publication status. It is available as a free
231-
download in PDF format from
232-
http://www.ecma-international.org/publications/techreports/E-TR-098.htm.
233-
A PostScript version of the JFIF document is available at
234-
http://www.ijg.org/files/jfif.ps.gz. There is also a plain text version at
235-
http://www.ijg.org/files/jfif.txt.gz, but it is missing the figures.
223+
format. For the omitted details we follow the "JFIF" conventions, version 2.
224+
JFIF version 1 has been adopted as Recommendation ITU-T T.871 (05/2011) :
225+
Information technology - Digital compression and coding of continuous-tone
226+
still images: JPEG File Interchange Format (JFIF). It is available as a
227+
free download in PDF file format from http://www.itu.int/rec/T-REC-T.871.
228+
A PDF file of the older JFIF document is available at
229+
http://www.w3.org/Graphics/JPEG/jfif3.pdf.
236230

237231
The TIFF 6.0 file format specification can be obtained by FTP from
238232
ftp://ftp.sgi.com/graphics/tiff/TIFF6.ps.gz. The JPEG incorporation scheme
@@ -252,8 +246,8 @@ ARCHIVE LOCATIONS
252246
The "official" archive site for this software is www.ijg.org.
253247
The most recent released version can always be found there in
254248
directory "files". This particular version will be archived as
255-
http://www.ijg.org/files/jpegsrc.v9.tar.gz, and in Windows-compatible
256-
"zip" archive format as http://www.ijg.org/files/jpegsr9.zip.
249+
http://www.ijg.org/files/jpegsrc.v9b.tar.gz, and in Windows-compatible
250+
"zip" archive format as http://www.ijg.org/files/jpegsr9b.zip.
257251

258252
The JPEG FAQ (Frequently Asked Questions) article is a source of some
259253
general information about JPEG.
@@ -280,7 +274,7 @@ Thank to Thomas Wiegand and Gary Sullivan for inviting me to the
280274
Joint Video Team (MPEG & ITU) meeting in Geneva, Switzerland.
281275

282276
Thank to Thomas Richter and Daniel Lee for inviting me to the
283-
ISO/IEC JTC1/SC29/WG1 (also known as JPEG, together with ITU-T SG16)
277+
ISO/IEC JTC1/SC29/WG1 (previously known as JPEG, together with ITU-T SG16)
284278
meeting in Berlin, Germany.
285279

286280
Thank to John Korejwa and Massimo Ballerini for inviting me to
@@ -306,10 +300,10 @@ design and development of this singular software package.
306300
FILE FORMAT WARS
307301
================
308302

309-
The ISO/IEC JTC1/SC29/WG1 standards committee (also known as JPEG, together
310-
with ITU-T SG16) currently promotes different formats containing the name
311-
"JPEG" which is misleading because these formats are incompatible with
312-
original DCT-based JPEG and are based on faulty technologies.
303+
The ISO/IEC JTC1/SC29/WG1 standards committee (previously known as JPEG,
304+
together with ITU-T SG16) currently promotes different formats containing
305+
the name "JPEG" which is misleading because these formats are incompatible
306+
with original DCT-based JPEG and are based on faulty technologies.
313307
IJG therefore does not and will not support such momentary mistakes
314308
(see REFERENCES).
315309
There exist also distributions under the name "OpenJPEG" promoting such
@@ -322,29 +316,60 @@ Don't use an incompatible file format!
322316
(In any case, our decoder will remain capable of reading existing JPEG
323317
image files indefinitely.)
324318

325-
Furthermore, the ISO committee pretends to be "responsible for the popular
326-
JPEG" in their public reports which is not true because they don't respond to
327-
actual requirements for the maintenance of the original JPEG specification.
319+
The ISO committee pretends to be "responsible for the popular JPEG" in their
320+
public reports which is not true because they don't respond to actual
321+
requirements for the maintenance of the original JPEG specification.
322+
Furthermore, the ISO committee pretends to "ensure interoperability" with
323+
their standards which is not true because their "standards" support only
324+
application-specific and proprietary use cases and contain mathematically
325+
incorrect code.
328326

329327
There are currently different distributions in circulation containing the
330328
name "libjpeg" which is misleading because they don't have the features and
331329
are incompatible with formats supported by actual IJG libjpeg distributions.
332330
One of those fakes is released by members of the ISO committee and just uses
333331
the name of libjpeg for misdirection of people, similar to the abuse of the
334332
name JPEG as described above, while having nothing in common with actual IJG
335-
libjpeg distributions.
336-
The other one claims to be a "derivative" or "fork" of the original libjpeg
337-
and violates the license conditions as described under LEGAL ISSUES above.
338-
We have no sympathy for the release of misleading and illegal distributions
339-
derived from obsolete code bases.
333+
libjpeg distributions and containing mathematically incorrect code.
334+
The other one claims to be a "derivative" or "fork" of the original libjpeg,
335+
but violates the license conditions as described under LEGAL ISSUES above
336+
and violates basic C programming properties.
337+
We have no sympathy for the release of misleading, incorrect and illegal
338+
distributions derived from obsolete code bases.
340339
Don't use an obsolete code base!
341340

341+
According to the UCC (Uniform Commercial Code) law, IJG has the lawful and
342+
legal right to foreclose on certain standardization bodies and other
343+
institutions or corporations that knowingly perform substantial and
344+
systematic deceptive acts and practices, fraud, theft, and damaging of the
345+
value of the people of this planet without their knowing, willing and
346+
intentional consent.
347+
The titles, ownership, and rights of these institutions and all their assets
348+
are now duly secured and held in trust for the free people of this planet.
349+
People of the planet, on every country, may have a financial interest in
350+
the assets of these former principals, agents, and beneficiaries of the
351+
foreclosed institutions and corporations.
352+
IJG asserts what is: that each man, woman, and child has unalienable value
353+
and rights granted and deposited in them by the Creator and not any one of
354+
the people is subordinate to any artificial principality, corporate fiction
355+
or the special interest of another without their appropriate knowing,
356+
willing and intentional consent made by contract or accommodation agreement.
357+
IJG expresses that which already was.
358+
The people have already determined and demanded that public administration
359+
entities, national governments, and their supporting judicial systems must
360+
be fully transparent, accountable, and liable.
361+
IJG has secured the value for all concerned free people of the planet.
362+
363+
A partial list of foreclosed institutions and corporations ("Hall of Shame")
364+
is currently prepared and will be published later.
365+
342366

343367
TO DO
344368
=====
345369

346370
Version 9 is the second release of a new generation JPEG standard
347-
to overcome the limitations of the original JPEG specification.
371+
to overcome the limitations of the original JPEG specification,
372+
and is the first true source reference JPEG codec.
348373
More features are being prepared for coming releases...
349374

350375
Please send bug reports, offers of help, etc. to jpeg-info@jpegclub.org.

3rdparty/libjpeg/change.log

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,56 @@
11
CHANGE LOG for Independent JPEG Group's JPEG software
22

33

4+
Version 9b 17-Jan-2016
5+
-----------------------
6+
7+
Improvements and optimizations in DCT and color calculations.
8+
Normalize range limit array composition and access pattern.
9+
Thank to Sia Furler and Maddie Ziegler for inspiration.
10+
11+
Use merged upsample with scaled DCT sizes larger than 8.
12+
Thank to Taylor Hatala for inspiration.
13+
14+
Check for excessive comment lengths in argument parsing in wrjpgcom.c.
15+
Thank to Julian Cohen for hint.
16+
17+
Add makefile.b32 for use with Borland C++ 32-bit (bcc32).
18+
Thank to Joe Slater for contribution.
19+
20+
Document 'f' specifier for jpegtran -crop specification.
21+
Thank to Michele Martone for suggestion.
22+
23+
Use defined value from header instead of hardwired number in rdswitch.c.
24+
Thank to Robert Sprowson for hint.
25+
26+
27+
Version 9a 19-Jan-2014
28+
-----------------------
29+
30+
Add support for wide gamut color spaces (JFIF version 2).
31+
Improve clarity and accuracy in color conversion modules.
32+
Note: Requires rebuild of test images.
33+
34+
Extend the bit depth support to all values from 8 to 12
35+
(BITS_IN_JSAMPLE configuration option in jmorecfg.h).
36+
jpegtran now supports N bits sample data precision with all N from 8 to 12
37+
in a single instance. Thank to Roland Fassauer for inspiration.
38+
39+
Try to resolve issues with new boolean type definition.
40+
Thank also to v4hn for suggestion.
41+
42+
Enable option to use default Huffman tables for lossless compression
43+
(for hardware solution), and in this case improve lossless RGB compression
44+
with reversible color transform. Thank to Benny Alexandar for hint.
45+
46+
Extend the entropy decoding structure, so that extraneous bytes between
47+
compressed scan data and following marker can be reported correctly.
48+
Thank to Nigel Tao for hint.
49+
50+
Add jpegtran -wipe option and extension for -crop.
51+
Thank to Andrew Senior, David Clunie, and Josef Schmid for suggestion.
52+
53+
454
Version 9 13-Jan-2013
555
----------------------
656

3rdparty/libjpeg/jcapimin.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ jpeg_CreateCompress (j_compress_ptr cinfo, int version, size_t structsize)
3737
if (version != JPEG_LIB_VERSION)
3838
ERREXIT2(cinfo, JERR_BAD_LIB_VERSION, JPEG_LIB_VERSION, version);
3939
if (structsize != SIZEOF(struct jpeg_compress_struct))
40-
ERREXIT2(cinfo, JERR_BAD_STRUCT_SIZE,
41-
(int) SIZEOF(struct jpeg_compress_struct), (int) structsize);
40+
ERREXIT2(cinfo, JERR_BAD_STRUCT_SIZE,
41+
(int) SIZEOF(struct jpeg_compress_struct), (int) structsize);
4242

4343
/* For debugging purposes, we zero the whole master structure.
4444
* But the application has already set the err pointer, and may have set
@@ -169,15 +169,15 @@ jpeg_finish_compress (j_compress_ptr cinfo)
169169
(*cinfo->master->prepare_for_pass) (cinfo);
170170
for (iMCU_row = 0; iMCU_row < cinfo->total_iMCU_rows; iMCU_row++) {
171171
if (cinfo->progress != NULL) {
172-
cinfo->progress->pass_counter = (long) iMCU_row;
173-
cinfo->progress->pass_limit = (long) cinfo->total_iMCU_rows;
174-
(*cinfo->progress->progress_monitor) ((j_common_ptr) cinfo);
172+
cinfo->progress->pass_counter = (long) iMCU_row;
173+
cinfo->progress->pass_limit = (long) cinfo->total_iMCU_rows;
174+
(*cinfo->progress->progress_monitor) ((j_common_ptr) cinfo);
175175
}
176176
/* We bypass the main controller and invoke coef controller directly;
177177
* all work is being done from the coefficient buffer.
178178
*/
179179
if (! (*cinfo->coef->compress_data) (cinfo, (JSAMPIMAGE) NULL))
180-
ERREXIT(cinfo, JERR_CANT_SUSPEND);
180+
ERREXIT(cinfo, JERR_CANT_SUSPEND);
181181
}
182182
(*cinfo->master->finish_pass) (cinfo);
183183
}
@@ -198,7 +198,7 @@ jpeg_finish_compress (j_compress_ptr cinfo)
198198

199199
GLOBAL(void)
200200
jpeg_write_marker (j_compress_ptr cinfo, int marker,
201-
const JOCTET *dataptr, unsigned int datalen)
201+
const JOCTET *dataptr, unsigned int datalen)
202202
{
203203
JMETHOD(void, write_marker_byte, (j_compress_ptr info, int val));
204204

3rdparty/libjpeg/jcapistd.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
* jcapistd.c
33
*
44
* Copyright (C) 1994-1996, Thomas G. Lane.
5+
* Modified 2013 by Guido Vollbeding.
56
* This file is part of the Independent JPEG Group's software.
67
* For conditions of distribution and use, see the accompanying README file.
78
*
@@ -75,7 +76,7 @@ jpeg_start_compress (j_compress_ptr cinfo, boolean write_all_tables)
7576

7677
GLOBAL(JDIMENSION)
7778
jpeg_write_scanlines (j_compress_ptr cinfo, JSAMPARRAY scanlines,
78-
JDIMENSION num_lines)
79+
JDIMENSION num_lines)
7980
{
8081
JDIMENSION row_ctr, rows_left;
8182

@@ -118,7 +119,7 @@ jpeg_write_scanlines (j_compress_ptr cinfo, JSAMPARRAY scanlines,
118119

119120
GLOBAL(JDIMENSION)
120121
jpeg_write_raw_data (j_compress_ptr cinfo, JSAMPIMAGE data,
121-
JDIMENSION num_lines)
122+
JDIMENSION num_lines)
122123
{
123124
JDIMENSION lines_per_iMCU_row;
124125

@@ -145,7 +146,7 @@ jpeg_write_raw_data (j_compress_ptr cinfo, JSAMPIMAGE data,
145146
(*cinfo->master->pass_startup) (cinfo);
146147

147148
/* Verify that at least one iMCU row has been passed. */
148-
lines_per_iMCU_row = cinfo->max_v_samp_factor * DCTSIZE;
149+
lines_per_iMCU_row = cinfo->max_v_samp_factor * cinfo->min_DCT_v_scaled_size;
149150
if (num_lines < lines_per_iMCU_row)
150151
ERREXIT(cinfo, JERR_BUFFER_SIZE);
151152

0 commit comments

Comments
 (0)