Info
Version: | 1.0.1 |
Author(s): | Peerless |
Last Update: | Saturday, February 24, 2018 |
.NET Fiddle: | Create the first Fiddle |
NuGet Url: | https://www.nuget.org/packages/Peerless.Resize.Image |
Install
Install-Package Peerless.Resize.Image
dotnet add package Peerless.Resize.Image
paket add Peerless.Resize.Image
Peerless.Resize.Image Download (Unzip the "nupkg" after downloading)
Dependencies
- System.Drawing.Common(>= 4.5.012591404)
Example Use Case:
string[] files = Directory.GetFiles("C:/Users/sdoherty/Desktop/DemoCount");
int height = 350;
int width = 200;
foreach (string file in files)
{
string filePath = Path.GetFileName(file);
Image imgPhoto = Image.FromFile(@file);
Bitmap image = ResizeImage(imgPhoto, width, height);
image.Save(@"C:\Users\sdoherty\Desktop\" + filePath);
}.