Size Saving JPEG to EPS Conversion

I am looking for the best way to convert JPEG files to EPS. I need to convert image files to EPS for insertion into my LaTeX files. Please note that I use dvipdfm to compile my LaTeX file to PDF, and I do not use pdflatex.

The problem is that the actual image size changes when converting to EPS. Therefore, I must use the "scale" parameter of the includegraphics command in LaTeX to get the image scale to its actual size. I tried Gimp , Jpeg2ps and ImageMagick Convert to convert JPEG files to EPS files. However, each of these converters creates an EPS file whose actual size is different from the actual size of the original JPEG file.

I would like to know if anyone knows of a way to convert JPEG files to EPS files that preserve the original image sizes. Such a size-saving converter will save us from manually scaling the image in the LaTeX file.

My LaTeX file (include-image.tex) looks like this:

\documentclass{article}
\usepackage[dvipdfm]{graphicx}
\begin{document}
\begin{figure}
\includegraphics{image.eps}
\end{figure}
\end{document}

And I use the following Makefile to create the pdf:

include-image.pdf: include-image.dvi
        dvipdfm include-image.dvi
include-image.dvi: include-image.tex
        latex include-image.tex
+3
source share
1 answer

JPEG is a fixed-resolution bitmap format; EPS is a non-resolution vector format.

http://www.logodesignworks.com/blog/vector-graphics-and-raster-graphics-difference

Raster graphics do not have physical dimensions relative to the substrate, the application that displays them uses the Dots-Per-Inch conversion factor (DPI) to scale the graph. If you have a JPEG with a resolution of 2000x2000 pixels and you print it at 400 DPI, it will be 5x5 inches, if you print it with a resolution of 800 DPI, it will be 2.5x2.5 inches.

jpeg2ps , -r-, DPI JPEG, EPS, JPEG DPI, EPS.

+5

Source: https://habr.com/ru/post/1713522/


All Articles