mirror of
https://github.com/ciromattia/kcc
synced 2025-12-13 01:36:27 +00:00
Prevents rainbow eraser crash on images with 1px dimensions
Don't apply rainbow eraser on images with 1px dimensions
This commit is contained in:
@@ -383,7 +383,7 @@ class ComicPage:
|
|||||||
|
|
||||||
def optimizeForDisplay(self, eraserainbow, is_color):
|
def optimizeForDisplay(self, eraserainbow, is_color):
|
||||||
# Erase rainbow artifacts for grayscale and color images by removing spectral frequencies that cause Moire interference with color filter array
|
# Erase rainbow artifacts for grayscale and color images by removing spectral frequencies that cause Moire interference with color filter array
|
||||||
if eraserainbow:
|
if eraserainbow and all(dim > 1 for dim in self.image.size):
|
||||||
self.image = erase_rainbow_artifacts(self.image, is_color)
|
self.image = erase_rainbow_artifacts(self.image, is_color)
|
||||||
|
|
||||||
def resizeImage(self):
|
def resizeImage(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user