ByteScout Watermarking SDK - C# - Resize Image in Percentage - ByteScout

ByteScout Watermarking SDK – C# – Resize Image in Percentage

  • Home
  • /
  • Articles
  • /
  • ByteScout Watermarking SDK – C# – Resize Image in Percentage

resize image in percentage in C# and ByteScout Watermarking SDK

Tutorial: how to do resize image in percentage in C#

ByteScout tutorials explain the material for programmers who use C#. ByteScout Watermarking SDK helps with resize image in percentage in C#. ByteScout Watermarking SDK is the powerful SDK can apply high quality visible and semivisible watermarks into PNG, JPG, BMP pictures and TIFF scans. Doznes of presets are available, multiple watermarks can be applied. Can add logo based watermark from image, can adjust font size, font family, colors.

The SDK samples like this one below explain how to quickly make your application do resize image in percentage in C# with the help of ByteScout Watermarking SDK. Follow the instruction from the scratch to work and copy and paste code for C# into your editor. Test C# sample code examples whether they respond your needs and requirements for the project.

Our website provides free trial version of ByteScout Watermarking SDK. It comes along with all these source code samples with the goal to help you with your C# application implementation.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)

Program.cs
      
using System; using System.Diagnostics; using System.Drawing; using System.Collections.Generic; using Bytescout.Watermarking; using Bytescout.Watermarking.Presets; namespace Sample { class Program { static void Main(string[] args) { // Create Watermarker instance Watermarker waterMarker = new Watermarker(); // Initialize library waterMarker.InitLibrary("demo", "demo"); // Set input file name string inputFilePath = "my_sample_image.jpg"; // Set output file title string outputFilePath = "my_sample_output.jpg"; // Add image to apply watermarks to waterMarker.AddInputFile(inputFilePath, outputFilePath); // Allow resize waterMarker.OutputOptions.Resize = true; // Set resize type to percentage waterMarker.OutputOptions.ResizeType = ResizeType.Percentage; // Reduce image by 1/2 waterMarker.OutputOptions.ResizePercentage = 50; // Set output directory waterMarker.OutputOptions.OutputDirectory = "."; // Apply watermarks waterMarker.Execute(); // open generated image file in default image viewer installed in Windows Process.Start(outputFilePath); } } }

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Watermarking SDK Home Page

Explore ByteScout Watermarking SDK Documentation

Explore Samples

Sign Up for ByteScout Watermarking SDK Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

VIDEO

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Watermarking SDK Home Page

Explore ByteScout Watermarking SDK Documentation

Explore Samples

Sign Up for ByteScout Watermarking SDK Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next