The invention is a method for determining a segmentation into distinct
regions of a set of coefficients representing at least part of an image
in order to insert or extract a set of watermarking signals with a
predetermined cardinal. The method of the invention generates a set of
acceptable segmentations, calculates, for each acceptable segmentation, a
probability of error on the detection of the watermarking signals
inserted in said each acceptable segmentation, and selects at least a
segmentation in the set of acceptable segmentations, on consideration of
the probability of error subject to a constraint on the number of regions
of the selected segmentation, with respect to said predetermined
cardinal.