Project

General

Profile

Feature #12011

Make TIFF compression level configurable

Added by Simon Raffeiner over 1 year ago. Updated about 1 year ago.

Status:
Fixed
Priority:
Low
Assignee:
-
Category:
General
Target version:
Start date:
02/15/2018
Due date:
% Done:

100%

Affected Version:
git master branch
System:
all
bitness:
64-bit
hardware architecture:
amd64/x86

Description

The TIFF compression level is currently hardcoded to 9 (Z_BEST_COMPRESSION), which doesn't lead to a noticeably smaller output file, but heavily increases the number of required CPU cycles. Make the level configurable and default to level 5.

This is equivalent to the solved issue regarding the PNG imageio module (#11695), with the exception that TIFF supports more than one compression scheme (including "uncompressed") and darktable already has a combo box to choose several schemes. The attached patch is a direct port of the commit (860def4eab3b1fc5b838d27bcc2f43ab81e2f295) which implemented the same feature for PNG.

The patch uses the UI string "compression" for the compression scheme and "compression level" for the compression level. This is a bit problematic because "compression level" is not yet localised in any language. Also the EXR module already uses "compression mode" and the WebP module already uses "compression type", this could be consolidated into a single string which works for EXR, WebP and the TIFF compression scheme.

darktable-tiff-add-compression-level.patch Magnifier (7.48 KB) Simon Raffeiner, 02/15/2018 11:59 AM

Associated revisions

Revision 0e5a6470
Added by Simon Raffeiner over 1 year ago

Add compression level slider to TIFF export module

Fixes #12011

Revision e574e302
Added by Simon Raffeiner about 1 year ago

Add compression level slider to TIFF export module

Fixes #12011

(cherry picked from commit 0e5a647003b89f817787c14c06d86354265a5250)

History

#1 Updated by Tobias Ellinghaus over 1 year ago

  • % Done changed from 0 to 100
  • Status changed from New to Fixed

Thank you, I changed it slightly and pushed it. And thanks for the bribe. ;-)

#2 Updated by Roman Lebedev about 1 year ago

  • Target version set to 2.6.0

Also available in: Atom PDF