Parameters
Name | Explanation |
---|---|
Handle1 | The image handle of the original image. (24 bit color images only) The watermark will be set on this image. |
Handle2 | The image handle of the digital watermark (1 bit color image) |
Text | Sets the digital watermark text (the length of text can be up to 127 bytes) |
FName | Sets the font name (the length of the font name can be up to 31 bytes) |
FSize | Sets the font size ( in points) |
Bold | If True (nonzero), sets font to bold |
Italic | If True (nonzero), sets font to italics |
Underline | If True (nonzero), sets underline to font. |
StrikeOut | If True (nonzero), sets strikethrough line to font |
Direction | Sets the direction of the watermark text (0: left to right, 1: right to left, 2: top to bottom, 3: bottom to top) |
Angle | Sets the rotation angle of the watermark text (0, 90, 180, 270 degrees) |
Level | Sets the level of "detection" for the watermark (-20 to 20) |
Left | The x coordinate of the location where the top left corner of the Handle2 image or text is to be attached to Handle1 (in pixels) |
Top | The y coordinate of the location where the top left corner of the Handle2 image or text is to be attached to Handle1 (in pixels) |
Right | The x coordinate of the location where the bottom right corner of the text is to be attached to Handle1 (in pixels) |
Bottom | The y coordinate of the location where the bottom right corner of the text is to be attached to Handle1 (in pixels) |
Return Value
Returns True (nonzero) if successful, otherwise returns False (0).
Explanation
The SetSecretImage method sets a digital watermark into a
raster image. It can set either a 1 bit color image or text as the
watermark. The value of the Level parameter determines how
"detectable" the digitable watermark will be. As the Level
parameter increases in a positive direction, the digital watermark
becomes brighter. As it increases in a negative direction, the
digital watermark becomes darker. Note also that depending on the
Direction or Angle parameter values, the Underline and StrikeOut
parameters may be ineffective.
If the Handle2 parameter is set (nonzero), the image referred to by
the Handle2 parameter will be set as the digital watermark. In this
case the top left corner of the Handle2 image will be attached to
the Handle1 image at the coordinate location determined by the Top
and Left parameters. If the Handle2 parameter is 0, then the Text
set in the Text parameter will be used as the digital watermark. It
will be placed within a rectangular area on the Handle1 image as
determined by the Top, Left, Bottom and Right parameters.
If successful the resulting raster image handle is set in the
ImageHandle property or
the Layer(LayerNo).ImageHandle
property dpending on the value set in the LayerNo property. The resulting image
is a 24 bit image.
When the Caption, Message, and ButtonName properties are blank, the
progress dialog box will not be displayed. When the progress dialog
box is displayed, the percentage that the processing has completed
will be shown in the dialog box.
To check if a watermark exists on an image, please refer to the
CheckSecretImage
method.