Overview
Image file formats fall into two basic camps, vector and raster. Vector formats are things such as SVG (Inkscape/Firefox), EPS, AI (Adobe Illustrator) and so on. Raster formats are things like BMP, JPG, PNG or GIF. In a vector format pictures are composed of lines and curves which are described by mathematical equations (e.g. Bézier curves). In a raster format pictures are composed of a matrix of pixels that have values at each element of the matrix (you could think of a 100x100 pixel RGB image as 3-d matrix with dimensions 100x100x3).
Vector formats have the advantage that they can be scaled to any size you want. Since they are merely a description of lines and shapes, they can be resized and then rasterized at that new size. Raster formats are described by the pixes that they contain and the size of a raster image depends on the dpi of the device on which it is rendered. If we have a 100x100 pixel JPG and print it out at 100dpi it will be (roughly) 1 inch by 1 inch in size.
When to Use
I need to represent... |
Use this image format |
Full-color images, photographs, very detailed graphical logos; scaling is unimportant |
JPG |
Icons, simple logos, line art with large areas of flat color; scaling is unimportant |
PNG |
Pages of text, little or no graphics |
PDF, PS, Gzipped PS |
Pages of text, graphics |
|
Graphical logos, line drawings; scaling important |
EPS, PDF*, SVG |
* Be sure that this is native PDF. PDF is a container format and can have arbitrary data embedded in it. If you're just embedding a JPG in a PDF and then including that PDF file in another PDF, this is still the same as a JPG. To make the conversion, you'll have to convert from a raster image to a vector image. This process is called vectorization and is the opposite of rasterization. You can use Potrace, or Inkscape to do this.