updated on Mon Jan 16 00:01:41 UTC 2012
[aur-mirror.git] / firefox-pgo / mozilla-libjpeg-turbo.patch
blob54be1a18af7d4c7582ba81be8fc27572880ede2d
1 diff -up xulrunner-2.0/mozilla-central/modules/libpr0n/decoders/nsJPEGDecoder.cpp.jpeg-turbo xulrunner-2.0/mozilla-central/modules/libpr0n/decoders/nsJPEGDecoder.cpp
2 --- xulrunner-2.0/mozilla-central/modules/libpr0n/decoders/nsJPEGDecoder.cpp.jpeg-turbo 2010-11-04 21:06:43.000000000 +0100
3 +++ xulrunner-2.0/mozilla-central/modules/libpr0n/decoders/nsJPEGDecoder.cpp 2010-11-12 12:39:08.047171412 +0100
4 @@ -411,14 +411,6 @@ nsJPEGDecoder::WriteInternal(const char
5 return; /* I/O suspension */
8 - /* Force to use our YCbCr to Packed RGB converter when possible */
9 - if (!mTransform && (mCMSMode != eCMSMode_All) &&
10 - mInfo.jpeg_color_space == JCS_YCbCr && mInfo.out_color_space == JCS_RGB) {
11 - /* Special case for the most common case: transform from YCbCr direct into packed ARGB */
12 - mInfo.out_color_components = 4; /* Packed ARGB pixels are always 4 bytes...*/
13 - mInfo.cconvert->color_convert = ycc_rgb_convert_argb;
14 - }
16 /* If this is a progressive JPEG ... */
17 mState = mInfo.buffered_image ? JPEG_DECOMPRESS_PROGRESSIVE : JPEG_DECOMPRESS_SEQUENTIAL;
19 @@ -563,15 +555,6 @@ nsJPEGDecoder::OutputScanlines(PRBool* s
20 PRUint32 *imageRow = ((PRUint32*)mImageData) +
21 (mInfo.output_scanline * mInfo.output_width);
23 - if (mInfo.cconvert->color_convert == ycc_rgb_convert_argb) {
24 - /* Special case: scanline will be directly converted into packed ARGB */
25 - if (jpeg_read_scanlines(&mInfo, (JSAMPARRAY)&imageRow, 1) != 1) {
26 - *suspend = PR_TRUE; /* suspend */
27 - break;
28 - }
29 - continue; /* all done for this row! */
30 - }
32 JSAMPROW sampleRow = (JSAMPROW)imageRow;
33 if (mInfo.output_components == 3) {
34 /* Put the pixels at end of row to enable in-place expansion */