A method (750) of encoding a value is disclosed. In one implementation the
value is encoded into an image (700). The method (750) operates by
defining (403) a first ordered set of positions; determining (405) a
number of marks for encoding the value in the ordered set of positions;
determining (409) a selection of the first ordered set of positions using
combinatorial theory with the number of marks and the number of positions
in the first ordered set of positions for encoding the value; and placing
(411) marks at the selection of the first ordered set of positions.
Preferably the value is encoded by encoding a base value and an offset
value, the base value is encoded by the number of marks, and the offset
value is encoded by the selection of positions. Preferably the marks are
basis patterns forming a watermark (710). A method is also disclosed of
encoding the number of basis patterns used in the watermark (710), which
comprises the steps of defining a further ordered set of positions in the
image; and adding a mark to the image at one of the further ordered set
of positions, the mark at the one position encoding the number of basis
patterns used in the watermark (710).