[net.text] TeX: Including graphics?

marvit@hplabsb.UUCP (Peter Marvit) (05/30/86)

\relax

I want to include graphics into TeX documents.  The \special seems to be
the TeX hook.  However, there's the dvi-->printer problem.  Has anyone
done any work in this area or have pointers thereof?

I leave the word "graphics" deliberately vague since I'm looking for a 
general solution to bit-mapped, raster, HP-GL, etc., if possible.  How-
ever, I'd like to hear of device/machine specific solutions.  One idea
I've heard is to convert the graphics image to METAFONT macros and let
METAFONT create one character which is the entire image.  What do you 
think?

If you post to the net, please e-mail me a copy.


Peter Marvit		ARPA:  marvit@hplabs.arpa
HP Labs 		UUCP:  ...!hplabs!marvit
415/857-6646

rpk@lmi-angel.UUCP (Bob Krajewski) (06/02/86)

The argument to the TeX control sequence \special is passed unchanged to the
program which actually prints the DVI file on a device, so the use of
\special is device-dependent, even though the DVI format itself is
device-independent.

For example, the Imagen-supplied DVI to IMPress program for 4.2bsd (dviimp),
when given a DVI file which was produced from the input which contained

	\special{insert(weird.impress)}

	\special{overlay(picture.impress)}

will insert (at the current ``cursor'' position) or overlay (relative to the
upper left-hand corner of the page) an IMPress file, which could contains
bitmaps, shapes from a drawing program, and so on.  More likely, other DVI
programs would ignore these commands if found in a DVI file.  Also, the
method of passing ``arguments'' to the \special command is apparently up to
the writer of the device driver.

Of course, it is also possible to do crude line graphics with TeX (see the
Dirty Tricks appendix), but it's basically tedious.

-- 
Robert P. Krajewski
Internet/MIT: RPK@MC.LCS.MIT.EDU
        UUCP: ...{cca,harvard,mit-eddie}!lmi-angel!rpk