For exporting eps
figures from Matlab i use matlabfrag
and laprint
functions so that i split the psfrag
commands (.tex
) and figure(.eps
) streams. During the compilation using pstool
or auto-pst-pdf
packages, figures with latex
text font are automatically added.
But my question is :
How to add figure labels,legends for .png
figures similar to psfrag
? As the .png
is from third-party software.
Can i convert .png
to tagged .eps
and then add text using psfrag
commands?
I prefer to save figures in tagged eps
(.eps
and .tex
) instead of .pdf
so that i can add latex font based on the beamer
or article
class used. I don't like to freeze the font of text in figures by using PDF
.
Best Answer
You can't get TeX to find text in a png the way it does for
psfrag
as essentially the information just isn't there (even if TeX could read the binary file). However if the png image has no text at all you can overlay latex text over it. there are packages to help that but you don't really need a package.overlays the two labels over the image. Of course you have to judge the coordinates by eye or some external measurement.