Patent attributes
A processor for forward reshaping to a target bit depth receives an input image with an input bit depth. The input luminance range is divided into luminance bands and each band is assigned a visual importance index. The output codewords at the target bit depth are divided into codeword bins and each bin is assigned to one of the luminance bands. Each codeword bin is assigned the visual importance index of the luminance band it belongs. Each bin is allocated a number of reshaped codewords according to its visual importance index and a codeword mapping function, where bins with the highest importance index are allocated more codewords than the other bins. A signal reshaping function is generated based on the allocation of codewords, and the reshaping function is applied to the input image to generate an output image in the target bit depth.