Lines Matching refs:maxval
78 JSAMPLE *rescale; /* => maxval-remapping array, or NULL */
137 * maxval = MAXJSAMPLE, which is the normal case for 8-bit data.
143 /* This version is for reading text-format PGM files with any maxval */
161 /* This version is for reading text-format PPM files with any maxval */
181 /* This version is for reading raw-byte-format PGM files with any maxval */
202 /* This version is for reading raw-byte-format PPM files with any maxval */
225 /* This version is for reading raw-byte-format files with maxval = MAXJSAMPLE.
240 /* This version is for reading raw-word-format PGM files with any maxval */
264 /* This version is for reading raw-word-format PPM files with any maxval */
301 unsigned int w, h, maxval;
324 maxval = read_pbm_integer(cinfo, source->pub.input_file);
326 if (w <= 0 || h <= 0 || maxval <= 0) /* error check */
359 if (maxval > 255) {
361 } else if (maxval == MAXJSAMPLE && SIZEOF(JSAMPLE) == SIZEOF(U_CHAR)) {
374 if (maxval > 255) {
376 } else if (maxval == MAXJSAMPLE && SIZEOF(JSAMPLE) == SIZEOF(U_CHAR)) {
389 ((maxval<=255) ? SIZEOF(U_CHAR) : (2*SIZEOF(U_CHAR)));
415 /* On 16-bit-int machines we have to be careful of maxval = 65535 */
418 (size_t) (((long) maxval + 1L) * SIZEOF(JSAMPLE)));
419 half_maxval = maxval / 2;
420 for (val = 0; val <= (INT32) maxval; val++) {
422 source->rescale[val] = (JSAMPLE) ((val*MAXJSAMPLE + half_maxval)/maxval);