title: Why do I get NoDecodeDelegateForThisImageFormat when rastering SVG to PNG with ImageMagick in PHP?
body: <p>I'm trying to convert svg image to png with the following code:</p>
  
  <pre><code>$image = new Imagick();
  $image-&gt;readImageBlob($_POST['svgcode']);
  $image-&gt;setImageFormat("png24");
  $image-&gt;resizeImage(600, 600, imagick::FILTER_LANCZOS, 1);
  header('Content-type: image/png');
  echo $image;
  </code></pre>
  
  <p>But there is an error in the second line:</p>
  
  <pre><code>NoDecodeDelegateForThisImageFormat `' @ error/blob.c/BlobToImage/361
  </code></pre>
  
  <p>How can I fix this?</p>