How to get the "Base geometry" of an eps file

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: How to get the "Base geometry" of an eps file

Post by anthony »

A EPS file is a vector format, and while it may contain raster images at particular DPI, the file format itself has no 'resolution' rating.

that is 300dpi is not written or even part of the image format.

You will need to specify the intended DPI resolution (using -density) before reading to get the desired final size.

NOTE within EPS is a string, something like
%%BoundingBox: llx lly urx ury
This specifys the image bounds (though it could draw outside these bounds) that the contents are located. They are in 'points' (1/72 points per inch) and as such are dependant on the 'density' (pixels per inch) the image is read in at.

IM should handle that conversion (via Ghostscript) perfectly fine.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply