title: Converting with ImageMagick - illegal parameter
body: <p>I am trying to convert a PDF to JPG, main goal is to have a thumbnail so that the user can preview the PDF within the application.</p>
  
  <p>Apparently ImageMagick is a good way to do this, yet so far I failed to get it to convert the file.</p>
  
  <pre><code>import subprocess
  
  params = ['convert', '-density 300 -resize 220x205', 'dummy.pdf', 'thumb.jpg']
  subprocess.check_call(params)
  </code></pre>
  
  <p>So this is what I am getting instead of having the file converted:</p>
  
  <p>Unzulässiger Parameter - 300
  Traceback (most recent call last):
    File "pdf_preview_test.py", line 4, in 
      subprocess.check_call(params)
    File "C:\Users\EliasMessner\AppData\Local\Programs\Python\Python37-32\lib\subprocess.py", line 347, in check_call
      raise CalledProcessError(retcode, cmd)
  subprocess.CalledProcessError: Command '['convert', '-density 300 -resize 220x205', 'dummy.pdf', 'thumb.jpg']' returned non-zero exit status 4.</p>
  
  <p>I couldn't find any info about the problem. It looks like the "300" parameter is illegal but IMHO it is used correctly.. Help would be much appreciated. Thanks.</p>