Change DPI (resolution) but keep same size

Apr 21, 2014 at 2:31 PM
Hi,

I want ot upscale image DPI from 300 to 600 but at the same time I want to keep the image size otiginal (8.5*11), how can I do that?
Any thoughts?
Thank you.
Coordinator
Apr 21, 2014 at 3:26 PM
You can change the DPI with the Resample method of MagickImage. The parameters are now described as width/height but it should be resolutionX and resolutionY. This will be changed in the next release.

Changing the DPI from 300 to 600 will resize the image to a bigger size. This will result in an image that has a lower quality so I am not sure why you would want that?
Apr 22, 2014 at 1:23 PM
Hi,

Thank you for your reply.

I am trying to improve quality of an Image to improve OCR on it.
So I want to increase DPI resolution.
Also I am planning to apply "Median Filter with radius 5".

Any other improvement(s) you can suggest?

Thank you so much,
HITESH.
P Please consider the environment before printing this e-mail, thank you.




Coordinator
Apr 22, 2014 at 6:42 PM
You could use some of the tips from the ImageMagick forum. Maybe the following post will help you: http://www.imagemagick.org/discourse-server/viewtopic.php?f=1&t=22625. More can be found here: http://lmgtfy.com/?q=imagemagick%20ocr%20preprocessing
Apr 25, 2014 at 12:02 AM
Hi

Thank you for the reply, this is really helpful.

I have one more question, sorry for my poor knowledge, but how can i convert image to "GreyScale" using Magick.Net?
I tried a couple approach but was unsuccessful.

Thank you,

HITESH.
P Please consider the environment before printing this e-mail, thank you.




Coordinator
Apr 25, 2014 at 6:59 AM
You should set the ColorSpace of the image:
image.ColorSpace = ColorSpace.GRAY;
Apr 26, 2014 at 5:38 PM
Thank you so much.

Appreciate your help.

Thank you,

HITESH.
P Please consider the environment before printing this e-mail, thank you.