[libpng16] Cosmetic revision of previous change
This commit is contained in:
parent
a518abd582
commit
d74d82137b
@ -6776,11 +6776,12 @@ image_transform_png_set_rgb_to_gray_ini(PNG_CONST image_transform *this,
|
||||
* conversion adds another +/-2 in the 16-bit case and
|
||||
* +/-(1<<(15-PNG_MAX_GAMMA_8)) in the 8-bit case.
|
||||
*/
|
||||
that->pm->limit +=
|
||||
# if PNG_MAX_GAMMA_8 < 14
|
||||
that->pm->limit += pow((that->this.bit_depth == 16 ? 8. :
|
||||
pow((that->this.bit_depth == 16 ? 8. :
|
||||
6. + (1<<(15-PNG_MAX_GAMMA_8)))/65535, data.gamma);
|
||||
# else
|
||||
that->pm->limit += pow((that->this.bit_depth == 16 ? 8. :
|
||||
pow((that->this.bit_depth == 16 ? 8. :
|
||||
8. + (1<<(15-PNG_MAX_GAMMA_8)))/65535, data.gamma);
|
||||
# endif
|
||||
}
|
||||
@ -6800,10 +6801,11 @@ image_transform_png_set_rgb_to_gray_ini(PNG_CONST image_transform *this,
|
||||
* internal calculation errors, not the actual limit imposed by
|
||||
* pngvalid on the output errors.
|
||||
*/
|
||||
that->pm->limit +=
|
||||
# if DIGITIZE
|
||||
that->pm->limit += pow(1.1 /255, data.gamma);
|
||||
pow(1.1 /255, data.gamma);
|
||||
# else
|
||||
that->pm->limit += pow(1.0 /255, data.gamma);
|
||||
pow(1.0 /255, data.gamma);
|
||||
# endif
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user