Patent ID: 7792322

Claim:
An encoding data processing apparatus for generating a marked copy of an image by introducing a code word into a copy of the image, the apparatus comprising a code word generator operable to generate the code word having a plurality of code word coefficients, an image perception analyser operable to receive the image and to generate weighting factors for scaling the code word coefficients with respect to each of a plurality of parts of the image with which the code word coefficients are to be combined, a strength adapter operable to combine the weighting factors with the code word coefficients, and a combiner operable to combine the weighted code word coefficients with the image, wherein the image perception analyser includes a contrast masking engine, a smoothness compensation engine and a compensation combiner, the contrast masking engine being operable to determine for each of the plurality of parts of the image a relative measure of contrast, to calculate for each part, a weighting factor in accordance with the relative contrast measure, the weighting factor having an effect of reducing the code word coefficients for image parts having a lower relative contrast measure, the smoothness compensation engine comprises a neighbour contrast calculator, and is operable to determine for each image part a smoothness factor by counting a number of smooth pixels in the image part, a pixel being determined to be smooth if a predetermined number of pixels neighbouring said pixel are within a threshold value of said pixel's own value, the smoothness factor of each part then being calculated as a function of a proportion of smooth pixels in the part, and to generate compensation factors in accordance with the smoothness factors, which when combined with the corresponding weighting factors have an effect of reducing the strength of the code word coefficients for higher smoothness factors, and the compensation combiner is operable to combine the compensation factors with the weighting factor to provide compensated weighting factors for adapting the strength of the code word.