How to add images
Introduction
In LATEX the images that you want to insert in the document are recalled through links to external files.
It is also possible to create images, which will become vectorial, with LATEX commands, even if this
opportunity requires an in-depth knowledge of the language.
To add an image you must know its location and write its path inside the braces after the \includegraphics command.
WARNING!
An important advice for the organizational purposes of the work: it will be very convenient to prepare a folder for all the figures and images to be inserted, in order to keep the work space organised.
An important advice for the organizational purposes of the work: it will be very convenient to prepare a folder for all the figures and images to be inserted, in order to keep the work space organised.
Types of images
There are two types of figures:
1.Vector (generally indicated for graphs)
2.Bitmap (generally indicated for images)
1.Vector (generally indicated for graphs)
- .pdf (portable document file)
- .eps (encapsulated postcript)
- .ps (postcript)
2.Bitmap (generally indicated for images)
- .png (portable network graphics)
- .jpeg o .jpg (joint photographic experts group)
- .tiff o .tif (tagged image file format)
The command \includegraphics
The \includegraphics command is undoubtedly the most important command of the graphicx package and is the one
that allows you to insert an image into the document.
The \includegraphics command accepts the name of a file as a mandatory parameter; this file contains the image
that will have to be inserted in the document and, in most cases.
Ad \ includegraphics can also be passed a list of optional parameters, which will be given a broad description
in the "Image positioning" paragraph, which \ includegraphics simply does `and examine the file
containing the image to be included, process any options, determine the space to be reserved for the image to be inserted and
make sure that all the necessary information is present in the file that LATEX will generate.Usually, the \includegraphics command is used
within the environment figures to create a figure (which in the final document will be positioned according
to certain aesthetic options and rules) with, eventually, a caption.
CODE
\begin{figure}[h]
\includegraphics[width=12cm]{../media/img/USI-LOGO.png
\end{figure}