I want to keep the original size of my image just converting its format. The following command should work, shouldn't it?
convert PTS01.pdf PTS01.gif
It doesn't apply the way I wanted it to. My PTS01.pdf image was resized and I can barely read what is written on it. I tried then to use the command -size (since I know the size of my original image) combined with the quality command:
convert -quality 100 -size 500x350 PTS01.pdf PTS01.gif
Why it doesn't work at all?
Thanks!
Why -size option on convert command doesn't work?
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Why -size option on convert command doesn't work?
First, -size is a setting and does nothing by itself.
More importantly, PDF files have no resolution (density), because they are vector format. You need to assign a density before reading the PDF (nominally it would be 72 dpi). Plus to get better quality you need to "supersample", which means you have to make the pdf larger by using a larger density and then resize the result back down by the opposite ratio. That will make the processing slower but give you higher quality result.
try
convert -density 288 PTS01.pdf -resize 25% PTS01.gif
288=72*4
25%=100%/4
More importantly, PDF files have no resolution (density), because they are vector format. You need to assign a density before reading the PDF (nominally it would be 72 dpi). Plus to get better quality you need to "supersample", which means you have to make the pdf larger by using a larger density and then resize the result back down by the opposite ratio. That will make the processing slower but give you higher quality result.
try
convert -density 288 PTS01.pdf -resize 25% PTS01.gif
288=72*4
25%=100%/4
Re: Why -size option on convert command doesn't work?
Wonderful explanation! Thank you very much.