I have some pictures saved at the same time in different image extensions, for example, pic1.png, pic1.pdf, pic1.jpg, pic2.pdf, pic2.png, pic3.jpg.
I would like to include preferably .pdf, if not, .png, and as last option .jpg, if no other format is available, when I include the picture in my LaTeX document using \includegraphics
.