From 36e9a54f02905788899916609fd6ccd488cc841e Mon Sep 17 00:00:00 2001 From: "James R. Barlow" Date: Tue, 3 Nov 2020 01:34:28 -0800 Subject: [PATCH] Remove extraneous page rotation This was added in commit b5ccbfd but seems to have been ill-advised. --- src/ocrmypdf/_pipeline.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/ocrmypdf/_pipeline.py b/src/ocrmypdf/_pipeline.py index 67bb26c8..aa55f5d4 100644 --- a/src/ocrmypdf/_pipeline.py +++ b/src/ocrmypdf/_pipeline.py @@ -536,9 +536,6 @@ def create_ocr_image(image: Path, page_context: PageContext): # Pillow requires integer DPI dpi = tuple(round(coord) for coord in im.info['dpi']) - if page_context.pageinfo.rotation != 0: - log.info(f"Rotating {page_context.pageinfo.rotation}") - im = im.rotate(page_context.pageinfo.rotation) im.save(output_file, dpi=dpi) return output_file