microtuts

C#: Resize an Image Proportionally (Specify Max Width/height)

Here’s a little function in C# to resize an image with proportional constraints. Just specific the max width and max height and this method will return a bitmap all sized up for you. I have this snipped in the form of a static Utilities class because that’s how I use it.

Enjoy!


Creating your first programming language is easier than you think.

Understanding how a programming language works is a surefire way to be a better developer. Read more.


Suggested Reading


written by Ryan Bosinger
Ryan is a web developer living and working in Banff Alberta. He also writes for giftsforpeoplewitheverything.com and freefoley.com.

3 Responses to “C#: Resize an Image Proportionally (Specify Max Width/height)”

  1. Bleeter says:

    You da man Ryan!

  2. Srihari says:

    Thank you very much sir, this code i need exactly.

  3. Marco says:

    Very good! Thank you!

Leave a Reply