Created
August 16, 2022 11:41
-
-
Save conholdate-docs-gists/a52f00f603e5924078cce7f4f89d4044 to your computer and use it in GitHub Desktop.
Adding watermark to photos | https://docs.conholdate.com/net/adding-watermark-to-photos/
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TiffImageLoadOptions loadOptions = new TiffImageLoadOptions(); | |
// Constants.InImageTiff is an absolute or relative path to your document. Ex: @"C:\Docs\image.tiff" | |
using (Watermarker watermarker = new Watermarker(Constants.InImageTiff, loadOptions)) | |
{ | |
// Initialize text or image watermark | |
TextWatermark watermark = new TextWatermark("Test watermark", new Font("Arial", 19)); | |
// Add watermark to the first frame | |
TiffImageWatermarkOptions options = new TiffImageWatermarkOptions(); | |
options.FrameIndex = 0; | |
watermarker.Add(watermark, options); | |
watermarker.Save(Constants.OutImageTiff); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Read the complete article: https://docs.conholdate.com/net/adding-watermark-to-photos/