Page 1 of 1
finding resolution?
Posted: 2007-07-18T11:21:51-07:00
by fcaserio
Can ImageMagick find image resolution?
When I apply image conversion from EPS to JPG ImageMagick applies a default 73dpi conversion, and I have to declare the image resolution to prevent data loss.
Can I make the conversion without declaring the resolution and no data loss?
If not, can ImageMagick find image resolution?
Re: finding resolution?
Posted: 2007-08-09T00:43:21-07:00
by anthony
That is the big question, and one i would love to answer to myself.
however no it does not seem to be posible. It would be good is ghostscript has some method of extracting raster images from postscript and PDF files as is, but that does not seem to be the case either.
Re: finding resolution?
Posted: 2007-08-09T06:36:26-07:00
by fcaserio
ops, sorry... I wrote my reply on the report tool. Let me answer on the proper area...
I found that some versions of photoshop writes a XML string with the resolution and other params after the binary code on EPS files. I dont think it is reliable to read resolution from this XML because I think if the file was not created by Photoshop the XML is not present.
tks any way...
Can I make another question about EPS? If the EPS file has a clipping path, when IM converts it to JPG the area outside the clipping path is discarted. Is there anyway to discard the clipping path before the conversion?
tks again
Re: finding resolution?
Posted: 2007-08-09T18:37:21-07:00
by anthony
Only but modifying the EPS file, as it would have to be done before ghostscript rasterises it.
IM itself will only apply the clipping path is -clip is specified, but that will only work with the original JPEG file, and not a ghostscript converted EPS image.
If you find more info on that XML, or find other methods of extracting raster images from Postscript, then PLEASE let me know. This is probably something that should be addressed to the ghostscript developers, as ghostscript is probably in the best position to see raster images before they are 'drawn' at the requested resolution.