From fb7bae1655af0a9f0f9dfc5bbd0e2ce56d964357 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Sat, 27 Aug 2016 17:56:34 +0200 Subject: Fix ICC profile parsing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/icc.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/icc.py') diff --git a/src/icc.py b/src/icc.py index 61c0414..1d6ab0d 100644 --- a/src/icc.py +++ b/src/icc.py @@ -187,11 +187,11 @@ def parse_icc(content): elif gamma_type == 1: ## The profile is encoded with gamma, brightness and contrast values # Get the gamma, brightness and contrast for the red channel, - (r_gamma, r_min, r_max) = [int_(read(4)) / 65535 for _ in range(3)] + (r_gamma, r_min, r_max) = [int_(read(4)) / 65536 for _ in range(3)] # green channel - (g_gamma, g_min, g_max) = [int_(read(4)) / 65535 for _ in range(3)] + (g_gamma, g_min, g_max) = [int_(read(4)) / 65536 for _ in range(3)] # and blue channel. - (b_gamma, b_min, b_max) = [int_(read(4)) / 65535 for _ in range(3)] + (b_gamma, b_min, b_max) = [int_(read(4)) / 65536 for _ in range(3)] def f(): ''' Apply the gamma, brightness and contrast -- cgit v1.2.3-70-g09d2