The Independent JPEG Group's JPEG software v2

This commit is contained in:
Thomas G. Lane
1991-12-13 00:00:00 +00:00
committed by DRC
parent 2cbeb8abd9
commit bd543f030e
59 changed files with 4585 additions and 1143 deletions

View File

@@ -61,15 +61,15 @@ ycc_rgb_convert (decompress_info_ptr cinfo, int num_rows,
x = y + 1436*v + 512; /* red */
if (x < 0) x = 0;
if (x > ((INT32) MAXJSAMPLE*1024)) x = (INT32) MAXJSAMPLE*1024;
*outptr0++ = x >> 10;
*outptr0++ = (JSAMPLE) (x >> 10);
x = y - 352*u - 731*v + 512; /* green */
if (x < 0) x = 0;
if (x > ((INT32) MAXJSAMPLE*1024)) x = (INT32) MAXJSAMPLE*1024;
*outptr1++ = x >> 10;
*outptr1++ = (JSAMPLE) (x >> 10);
x = y + 1815*u + 512; /* blue */
if (x < 0) x = 0;
if (x > ((INT32) MAXJSAMPLE*1024)) x = (INT32) MAXJSAMPLE*1024;
*outptr2++ = x >> 10;
*outptr2++ = (JSAMPLE) (x >> 10);
}
}
}