Convert PDF to PNG in Ubuntu
Feb 19, 2021
Install this
sudo apt install poppler-utils
Basic command
pdftoppm -png <input_file> prefix_output_filename
Advanced commands
for f in *.pdfdonew_f=${f::(-4)}echo ${new_f}pdftoppm -png $f ${new_f}done
What the above command doing is:
for each pdf file, split the file by page and save them as png file with
pdf_filename-1.png
pdf_filename-2.png
…
Explanation of more commands