Dianoga.ImageMagick
1.0.1
See the version list below for details.
dotnet add package Dianoga.ImageMagick --version 1.0.1
NuGet\Install-Package Dianoga.ImageMagick -Version 1.0.1
<PackageReference Include="Dianoga.ImageMagick" Version="1.0.1" />
paket add Dianoga.ImageMagick --version 1.0.1
#r "nuget: Dianoga.ImageMagick, 1.0.1"
// Install Dianoga.ImageMagick as a Cake Addin #addin nuget:?package=Dianoga.ImageMagick&version=1.0.1 // Install Dianoga.ImageMagick as a Cake Tool #tool nuget:?package=Dianoga.ImageMagick&version=1.0.1
Dianoga.ImageMagick
An Add-on to the widely used Dianoga Automatic Image Resizing module by Kamsar.
https://github.com/kamsar/Dianoga
This add-on specifically targets the JPEG image format. It utilizes the ImageMagick portable exe to reduce the overall size and dimensions (if desired) of images in Sitecore.
Installation
Simply install the NuGet package "Dianoga.ImageMagick" (https://www.nuget.org/packages/Dianoga.ImageMagick) into your Sitecore web project, build and deploy to your Sitecore root.
That's it 😃
What Does It Install?
Aside from the files included with Dianoga, Dianoga.ImageMagick includes the following:
- Dianoga.ImageMagick.dll
- App_Config\Include\Dianoga\Dianoga.Z.ImageMagick.config
- App_Data\Dianoga Tools\imagemagick\magic.xml
- App_Data\Dianoga Tools\imagemagick\magick.exe
Usage
Dianoga.ImageMagick keys off of the following settings included with Sitecore:
Media.Resizing.Quality
Media.Resizing.MaxWidth
Media.Resizing.MaxHeight
Media.Resizing.Quality
is the only required setting. Given a value, ImageMagick will convert the requested image to the set quality and store it in the sites MediaCache
.
If either Media.Resizing.MaxWidth
or Media.Resizing.MaxHeight
are set, or if both are set, it will enforce these on the image. Therefore, if an image is requested that has a larger width than is supported in the Media.Resizing.MaxWidth
, it will be resized keeping its aspect ratio down to the MaxWidth. The same goes for the height.
To change any of these values, edit App_Config\Include\Dianoga\Dianoga.Z.ImageMagick.config or patch in via a separate config file.
Recommendation
I have found that a quality setting of 70(%) provides significant performance increases without sacrificing quality. Even going down as far as 50% was difficult to tell the difference, especially for smaller images. Choose a setting that best fits your site.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net40 is compatible. net403 was computed. net45 was computed. net451 was computed. net452 was computed. net46 was computed. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
-
- Dianoga (>= 3.1.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Initial release