ByteScout Watermarking SDK - VB.NET - Stamp - ByteScout
Announcement
Our ByteScout SDK products are sunsetting as we focus on expanding new solutions.
Learn More Open modal
Close modal
Announcement Important Update
ByteScout SDK Sunsetting Notice
Our ByteScout SDK products are sunsetting as we focus on our new & improved solutions. Thank you for being part of our journey, and we look forward to supporting you in this next chapter!

ByteScout Watermarking SDK – VB.NET – Stamp

  • Home
  • /
  • Articles
  • /
  • ByteScout Watermarking SDK – VB.NET – Stamp

ByteScout Watermarking SDK – VB.NET – Stamp

Module1.vb

Imports Bytescout.Watermarking

Module Module1

    Sub Main()
        ' Create Watermarker instance
        Dim waterMarker As New Watermarker()

        ' Initialize library
        waterMarker.InitLibrary("demo", "demo")

        ' Set input file name
        Dim inputFilePath As String = "my_sample_image.jpg"

        For Each stampType As String In Presets.Stamp.PresetImages
            ' Set output file title
            Dim outputFilePath As String = "my_sample_output_" + stampType + ".jpg"

            ' Add image to apply watermarks to
            waterMarker.AddInputFile(inputFilePath, outputFilePath)

            ' Set output directory
            waterMarker.OutputOptions.OutputDirectory = "."

            ' Create new watermark
            Dim preset As New Presets.Stamp()

            ' Set stamp type
            preset.ImageFile = stampType

            ' Add watermark to watermarker
            waterMarker.AddWatermark(preset)

            ' Apply watermarks
            waterMarker.Execute()

            ' Clear all settings
            waterMarker.Clear()
        Next

    End Sub

End Module


  Click here to get your Free Trial version of the SDK

Tutorials:

prev
next