1
0
mirror of https://github.com/ciromattia/kcc synced 2026-03-31 06:05:32 +00:00

fix humble bundle pdf png autocontrast (#1273)

This commit is contained in:
Alex Xu
2026-03-17 15:09:02 -07:00
committed by GitHub
parent f5fe8d93b0
commit 87987c9ebf

View File

@@ -698,6 +698,9 @@ def imgFileProcessing(work):
img.gammaCorrectImage()
if not img.colorOutput:
img.convertToGrayscale()
img.autocontrastImage()
img.resizeImage()
img.optimizeForDisplay(opt.eraserainbow, img.colorOutput)
@@ -705,7 +708,6 @@ def imgFileProcessing(work):
if img.colorOutput:
pass
elif opt.forcepng:
img.convertToGrayscale()
if not opt.noquantize:
img.quantizeImage()
if opt.format == 'PDF':
@@ -714,8 +716,6 @@ def imgFileProcessing(work):
img.convertToGrayscale()
elif opt.pnglegacy:
img.convertToGrayscale()
else:
img.convertToGrayscale()
output.append(img.saveToDir())
return output
except Exception: