---
title: "Resize Sharp"
canonical: https://www.graphicsmill.com/samples/Transforms/Resize/ResizeSharp_cs
product: "Graphics Mill"
source: "Transforms/Resize/ResizeSharp.cs"
---

# Resize Sharp

Resizes image and maintains original sharpness (like Bicubic Sharper mode in Photoshop).

## Instruction

Resize the image to a width of 320 pixels, maintain the aspect ratio, apply an unsharp mask with specified parameters.

## Usings

```csharp
using Aurigma.GraphicsMill.Transforms;
```

## Code Snippet

```csharp
using (var bitmap = new Bitmap("Chicago.jpg"))
{
    bitmap.Transforms.Resize(320, 0, ResizeInterpolationMode.High);
    bitmap.Transforms.UnsharpMask(0.35f, 1, 0);
    bitmap.Save("ResizeSharp.jpg");
}
```

## Explanation

The code:

- Loads the image from file using the Bitmap class.
- Applies the "Resize" transform to adjust the image width to 320 pixels while maintaining the aspect ratio, using high-quality interpolation.
- Applies the "UnsharpMask" to sharpen the image with a radius of 1 and a strength of 0.35.
- Saves the processed image to a file with the sharpness enhancement.

## Tags

- [Bitmap](<https://www.graphicsmill.com/samples/tags/bitmap_md>): Working with images via the Bitmap API
- [Resize](<https://www.graphicsmill.com/samples/tags/resize_md>): Resizing images
- [Transform](<https://www.graphicsmill.com/samples/tags/transform_md>): Image transforms and effects

## Input

- [Chicago.jpg](<https://www.graphicsmill.com/samples/Transforms/compiled/Debug/Chicago_jpg>) (preview)

## Output

- [ResizeSharp.jpg](<https://www.graphicsmill.com/samples/Transforms/compiled/Debug/ResizeSharp_jpg>) (preview)

## Used APIs

- [Aurigma.GraphicsMill.Bitmap.Transforms](<https://www.graphicsmill.com/docs/gm/P_Aurigma_GraphicsMill_Bitmap_Transforms.htm.md>)
- [Aurigma.GraphicsMill.Transforms.ResizeInterpolationMode](<https://www.graphicsmill.com/docs/gm/T_Aurigma_GraphicsMill_Transforms_ResizeInterpolationMode.htm.md>)
- [Aurigma.GraphicsMill.TransformsProvider.Resize(Int32,Int32,ResizeInterpolationMode)](<https://www.graphicsmill.com/docs/gm/M_Aurigma_GraphicsMill_TransformsProvider_Resize_3_db5aa34c.htm.md>)
- [Aurigma.GraphicsMill.TransformsProvider.UnsharpMask(Single,Single,Single)](<https://www.graphicsmill.com/docs/gm/M_Aurigma_GraphicsMill_TransformsProvider_UnsharpMask_3_8ebc23ce.htm.md>)
