There are lots of programs with which you can actually resize/crop an image in C#, the earlier posts can help you with this, coming to the aspect ratio part 4:3 is nothing but standard 1024 X 768 pixels... So in your program you can always set the width
to 1024 and height to 768
And remember aspect ratios are calculated by find the greatest common divisor of the resolution.. in this case the 256 is the greatest common divisor of 1024 and 768
256 * 4 is 1024 and 156 * 3 is 768.... So you can very well go ahead and use the above programs to get to the 4:3 ratio...
Member
24 Points
229 Posts
Image Crop using aspect ratio
Jan 19, 2012 04:27 AM|shobana raja|LINK
How to crop and save a image with aspect ratio 4:3 in asp.net C#
All-Star
52617 Points
13226 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 04:38 AM|mudassarkhan|LINK
Refer these
http://www.switchonthecode.com/tutorials/csharp-tutorial-image-editing-saving-cropping-and-resizing
http://stackoverflow.com/questions/4648456/save-image-to-file-keeping-aspect-ratio-in-a-wpf-app
Member
24 Points
229 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 05:04 AM|shobana raja|LINK
i need the center crop of the image like in the microsoft picture manager.
Member
21 Points
24 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 05:11 AM|virazv|LINK
Check out this article
http://weblogs.asp.net/gunnarpeipman/archive/2009/11/03/using-asp-net-and-jcrop-to-crop-images-online.aspx
Member
24 Points
229 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 05:58 AM|shobana raja|LINK
Do anyone know how to change (any)width and (any)height to standard 4:3 ratio ???????
Participant
1243 Points
337 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 06:09 AM|Arunmhn|LINK
Hi,
There are lots of programs with which you can actually resize/crop an image in C#, the earlier posts can help you with this, coming to the aspect ratio part 4:3 is nothing but standard 1024 X 768 pixels... So in your program you can always set the width to 1024 and height to 768
Here is the link for all aspect ratios http://en.wikipedia.org/wiki/Display_resolution
And remember aspect ratios are calculated by find the greatest common divisor of the resolution.. in this case the 256 is the greatest common divisor of 1024 and 768
256 * 4 is 1024 and 156 * 3 is 768.... So you can very well go ahead and use the above programs to get to the 4:3 ratio...
Thanks
Arun
Member
24 Points
229 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 06:38 AM|shobana raja|LINK
Member
150 Points
75 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 08:05 AM|eprovidere|LINK
http://www.dotnetthoughts.net/2009/12/07/image-cropping-in-asp-net-with-jquery/
http://geekswithblogs.net/SanjayU/articles/asp.net-image--photo-cropper-in-c.aspx
Star
10444 Points
2464 Posts
Re: Image Crop using aspect ratio
Jan 19, 2012 08:09 AM|sirdneo|LINK
See this link, it will guide you how you can generate good quality thumbnail and image scaling:-
http://zeeshanumardotnet.blogspot.com/2010/06/generate-high-quality-thumbnail-images.html
Zeeshan Umar
~Please Mark As Answer, one or multiple posts, which helped you. So that it might be useful for others~
Member
24 Points
229 Posts
Re: Image Crop using aspect ratio
Jan 20, 2012 12:37 AM|shobana raja|LINK
I need a method to crop using aspect ratio like microsoft picture manager. I need the method to convert original image with new height and new width.
Star
10444 Points
2464 Posts
Re: Image Crop using aspect ratio
Jan 20, 2012 04:16 AM|sirdneo|LINK
have you tried the code which I shared, i am able to generate good quality thumbnails with that code.
Zeeshan Umar
~Please Mark As Answer, one or multiple posts, which helped you. So that it might be useful for others~
Member
24 Points
229 Posts
Re: Image Crop using aspect ratio
Jan 20, 2012 04:38 AM|shobana raja|LINK
An error while saving the thumbnail image
"A generic error occurred in GDI+."
Member
21 Points
24 Posts
Re: Image Crop using aspect ratio
Jan 20, 2012 05:27 AM|virazv|LINK
Check out this thread http://forums.asp.net/t/1395596.aspx/1
Member
24 Points
229 Posts
Re: Image Crop using aspect ratio
Jan 20, 2012 06:54 AM|shobana raja|LINK
Thanks alot it worked