User Tools

Site Tools


latexslideshow

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
Last revision Both sides next revision
latexslideshow [2018/12/06 19:50]
abeverley created
latexslideshow [2018/12/06 20:05]
abeverley
Line 3: Line 3:
 The steps shown here include resizing and renaming the photos first. The steps shown here include resizing and renaming the photos first.
  
-I am assuming that you have all your images in the directory ​<tt>images</tt>+I am assuming that you have all your images in the directory ​''​%%images%%''​
  
-==Resize photos==+===== Resize photos ​=====
  
-I used the Imagemagick ​<tt>mogrify</​tt> ​command to bulk resize all the images. This command resizes all images to a maximum size of 1280x1024, but does not resize them if they are already smaller than that.+I used the Imagemagick ​''​%%mogrify%%'' ​command to bulk resize all the images. This command resizes all images to a maximum size of 1280x1024, but does not resize them if they are already smaller than that.
  
- ​mogrify ​-resize 1280x1024\> images/*+''​%%mogrify -resize 1280x1024\>​ images/​*%%''​
  
-==Rename files sequentially==+===== Rename files sequentially ​=====
  
-The following Perl script renames all the files sequentially. This makes it easier to include them in the Latex script. See [http://​stackoverflow.com/​questions/​3211595/​renaming-files-in-a-folder-to-sequential-numbers this Stackoverflow question] for more details.+The following Perl script renames all the files sequentially. This makes it easier to include them in the Latex script. See [[http://​stackoverflow.com/​questions/​3211595/​renaming-files-in-a-folder-to-sequential-numbers|this Stackoverflow question]] for more details.
  
-<pre>+<code>
 #​!/​usr/​bin/​perl #​!/​usr/​bin/​perl
  
Line 47: Line 47:
     rename "​$dir/​$file",​ sprintf("​%s/​%s%s",​ $dir, ++$i, $ext); ​     rename "​$dir/​$file",​ sprintf("​%s/​%s%s",​ $dir, ++$i, $ext); ​
 } }
-</pre> +</code>
 Save the above script and run: Save the above script and run:
  
- ./rename.pl images+''​%%./rename.pl images%%''​
  
 You should now have all your images as 1.jpg, 2.jpg and so on. You should now have all your images as 1.jpg, 2.jpg and so on.
  
-==Convert to slideshow PDF==+===== Convert to slideshow PDF =====
  
-Save the following Latex script as <tt>slides.tex</tt>. Comments being with a <tt>%</tt>.+Save the following Latex script as ''​%%slides.tex%%''​. Comments being with a ''​%%%%%''​.
  
-<pre>+<code>
 \documentclass{beamer} \documentclass{beamer}
 \usepackage[size=a4]{beamerposter} \usepackage[size=a4]{beamerposter}
Line 97: Line 96:
  
 \end{document} \end{document}
-</pre> +</code
- +Run the script. ​''​%%xelatex%%'' ​is used so that fonts can be used:
-Run the script. ​<tt>xelatex</​tt> ​is used so that fonts can be used:+
  
- ​xelatex slides.tex+''​%%xelatex slides.tex%%''​
  
-This will produce ​<tt>slides.pdf</tt>. This file can be opened with Adobe Acrobat and shown in full screen to see the slideshow with transitions. As much as I dislike the proprietary Adobe viewer, it does show the slideshow well, which not many other PDF viewers seem to support.+This will produce ​''​%%slides.pdf%%''​. This file can be opened with Adobe Acrobat and shown in full screen to see the slideshow with transitions. As much as I dislike the proprietary Adobe viewer, it does show the slideshow well, which not many other PDF viewers seem to support.
  
latexslideshow.txt · Last modified: 2018/12/06 20:06 by abeverley