ImageThumbnailCreator 3.0.0

Suggested Alternatives

ImageThumbnailCreator.Core

Additional Details

Version 3.0.0 Updates
The .NET Framework version of this package is no longer maintained. See the .NET Standard v2.0 version available at ImageThumbnailCreator.Core

dotnet add package ImageThumbnailCreator --version 3.0.0                
NuGet\Install-Package ImageThumbnailCreator -Version 3.0.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ImageThumbnailCreator" Version="3.0.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add ImageThumbnailCreator --version 3.0.0                
#r "nuget: ImageThumbnailCreator, 3.0.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install ImageThumbnailCreator as a Cake Addin
#addin nuget:?package=ImageThumbnailCreator&version=3.0.0

// Install ImageThumbnailCreator as a Cake Tool
#tool nuget:?package=ImageThumbnailCreator&version=3.0.0                

ImageThumbnailCreator

Create image thumbnails from uploaded image files to help downsize large resolution images that need to be displayed on your website in a smaller resolution.

Excellent addition for custom blog sites or any kind of site that allows image files to be uploaded. You can downsize uploaded images as well as keep the original image if you want!

*Original uploaded images can be saved to the file system. *Thumbnails will be saved to the file system automatically.

Example MVC application is located at https://github.com/godfathr/ThumbnailWebExample

Version 3.0.0 Updates

Changed .NET framework to 4.8. Updated license from Apache to MIT. Updated README.md.

No updates to existing code are needed. Default value is set in NuGet package

How to use (example)

private Thumbnailer _thumbnailer = new Thumbnailer();
private string ThumbnailFolder = ConfigurationManager.AppSettings["TestDirectory"];
//Save the original photo at its original resolution
HttpPostedFileBase photo = Request.Files[0];
var originalImage = thumbnailer.SaveOriginal(uploadPath, photo);
//With specified compression level of 50
string thumbnailPath = _thumbnailer.Create(100, ThumbnailFolder, originalFileLocation, 50L); 

OR if a compression value is not provided, the default 85L will be used

string thumbnailPath = _thumbnailer.Create(100, ThumbnailFolder, originalFileLocation);

Version 2.0.1 Updates

Added optional image compression parameter. Max value is 100. Min value is 0. Default value is 85. Parameter type is long.

No updates to existing code are needed. Default value is set in NuGet package

public string Create(float width, string imageFolder, string fullImagePath, long compressionLevel = 85L)
{
    //method content here...
}
private Thumbnailer _thumbnailer = new Thumbnailer();
private string ThumbnailFolder = ConfigurationSettings.AppSettings["TestDirectory"];

_thumbnailer.Create(100, ThumbnailFolder, originalFileLocation, 50L); //With specified compression level of 50

OR if a compression value is not provided, the default 85L will be used

_thumbnailer.Create(100, ThumbnailFolder, originalFileLocation);

Version 2.0.0 Updates

Renamed "JpegThumbnailer" to "Thumbnailer". Added tests for PNG, GIF, TIF and BMP image formats. Added validation that prevents upsizing. Removed validation that would break the resizing if the property list had 0 items.

Version 1.0.2 Updates

Added unit tests.

Added parameter checking with meaningful exceptions.

Product Compatible and additional computed target framework versions.
.NET Framework net48 is compatible.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETFramework 4.8

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
3.0.0 759 6/13/2020 3.0.0 is deprecated because it is no longer maintained.
2.0.1 540 11/24/2019
2.0.0 587 5/24/2019
1.0.2 663 4/20/2019
1.0.1 606 3/22/2019

Upgrade to .NET 4.8. Change license from Apache to MIT.