Perceptual quantizer

The perceptual quantizer (PQ), published by SMPTE as SMPTE ST 2084,  is a transfer function that allows for HDR display by replacing the gamma curve used in SDR. It is capable of representing luminance level up to 10000 cd/m2 (nits) and down to 0.0001 nits. It was developed by Dolby and standardized in 2014 by SMPTE and also in 2016 by ITU in Rec. 2100. ITU specifies the use of PQ or HLG as transfer functions for HDR-TV. PQ is the basis of HDR video formats (such as Dolby Vision, HDR10 and HDR10+ ) and is also used for HDR still picture formats. PQ is not backward compatible with the BT.1886 EOTF (i.e. the gamma curve of SDR), while HLG is compatible.

PQ is a non-linear transfer function based on the human visual perception of banding and is able to produce no visible banding in 12 bits. A power function (used as EOTFs in standard dynamic range applications) extended to 10000 cd/m2 would have required 15 bits.

Technical details
The PQ EOTF (electro-optical transfer function) is as follows:

$$F_D = EOTF[E'] = 10000 \left( \frac{\max[ (E'^{1/m_2} - c_1), 0]} {c_2 - c_3 \cdot E' ^ {1/m_2} } \right) ^ {1/ m_1} $$

The PQ inverse EOTF is as follows:

$$E' = EOTF^{-1}[F_D] = \left( \frac{c_1 + c_2 \cdot Y^{m_1}}{1 + c_3 \cdot Y^{m_1} } \right)^{m_2}$$

where


 * $$E'$$ is the non-linear signal value, in the range $$\left[0, 1 \right]$$.
 * $$F_D$$ is the displayed luminance in cd/m2
 * $$Y = F_D/10000$$ is the normalized linear displayed value, in the range [0:1] (with $$Y = 1$$ representing the peak luminance of 10000 cd/m2)
 * $$m_1 = \frac{2610}{16384} = \frac{1305}{8192} = 0.1593017578125$$
 * $$m_2 = 128 \frac{2523}{4096} = \frac{2523}{32} = 78.84375$$


 * $$c_1 = \frac{3424}{4096} = \frac{107}{128} = 0.8359375 = c_3 - c_2 + 1 $$
 * $$c_2 = 32 \frac{2413}{4096} = \frac{2413}{128} = 18.8515625$$
 * $$c_3 = 32 \frac{2392}{4096} = \frac{2392}{128} = 18.6875$$