Click here to Skip to main content
15,885,757 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
I am having a picture box in my C# windows application with sizemode property as StrechImage. Image to the picture box is picking up from database. As the image is resized in picture box, image quality is very low. How can I keep the same resolution of image while streching the image?

Thank You.
Posted

You do - if you start with an image of 10 x 10 pixels, and display it at 100 x 100 you would have to invent 90% of the information in the large picture.

Either store larger images in the DB, or don't enlarge them too much. While there are algorithms that can help improve the effect when you stretch a low res image, the kind of stretch / zoom you get in Blade Runner / CSI / NCIS and so forth are fiction, not reality.
 
Share this answer
 
Comments
Zukiari 21-Sep-12 3:59am    
I'm reducing the size to picturebox size. i've to print the form with images and labels. For labels also Clarity is vry poor.
Please check the StackOverflow Discussion on - Resizing an Image without losing any quality[^].

Also if you can implement ImageResizer[^], that would be awesome.

Thanks...
 
Share this answer
 
Comments
fjdiewornncalwe 22-Sep-12 12:54pm    
My vote of 1: You have the OP's problem completely backwards on this one. He wants to increase the size of the image and maintain resolution. See Griff's answer as it is correct.
Ok thanks...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900