From 85c699d29aab7ca7f7218b3f7f859e10c9025e37 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Tue, 24 May 2016 12:25:22 +0100 Subject: Add somewhat speculative Rec 1886 and Rec 2020 colour conversions. --- src/modified_gamma_transfer_function.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/modified_gamma_transfer_function.h') diff --git a/src/modified_gamma_transfer_function.h b/src/modified_gamma_transfer_function.h index e8875d4b..c200743a 100644 --- a/src/modified_gamma_transfer_function.h +++ b/src/modified_gamma_transfer_function.h @@ -25,10 +25,15 @@ namespace dcp { -/** A transfer function which for an input x gives an output y where +/** A transfer function which for an input x gives a linear output y where * * y = x / B for x <= threshold * y = ((x + A) / (1 + A))^power for x > threshold + * + * The reverse transform is + * + * x = y * B for y <= threshold / B + * x = (1 + A) * y ^ (1 / power) - A for y > threshold / B */ class ModifiedGammaTransferFunction : public TransferFunction { -- cgit v1.2.3