Files with an .eps
extension are Encapsulated PostScript files, which are basically self-contained PostScript files for graphics.
They can contain many images in a single file. You could find this if you download an icon set from the web or receive graphics from a web designer.
One of the strengths of the EPS format is that the images can be resized without loosing quality, because the format is essentially a set of instructions about how to draw the images, much like SVG.
Extracting images
You can use Inkscape to extract the images. Inkscape is an open source program commonly used on Linux.
- Open the EPS in Inkscape. I just used the default PDF Import Settings.
- Make sure the selection tool - the plain black arrow, top left - is selected. It’ll say “Select and transform objects” when you hover over it.
- Click and drag a box around whatever you’d like to export. If nothing happens then you probably first need to ungroup the page via Object -> Ungroup.
- Copy with Edit -> Copy or ctrl-c.
- Open a new file with File -> New or ctrl-n.
- Paste into the new file with File -> Paste or ctrl-v.
Resize page to fit image
To resize the page to fit the size of the image:
- File -> Document Properties…
- On the Page tab (default), Resize page to content…
- Resize page to drawing or selection.
Crop image
To crop part of the image, see my Inkscape notes.
Save
You can save the file as whatever format you’d like, via File -> Save As…
If you save as a PNG this will not give it a transparent background.
Transparency
You need to export the file as a bitmap to get a transparent background. This will create a PNG.
- File -> Export Bitmap…
- Choose a filename and Export.
The file will be in the PNG format, so will be given a .png extension regardless of which filename you choose.
Resizing
You could choose new image dimensions when you export the image.
Alternatively you can resize the image in Inkscape before exporting it:
- Object -> Transform…
- Scale tab.
- Choose your new height and width, using the ‘Scale proportionally’ option to maintain image dimensions.
- Apply.