title: How can one do a pixel by pixel comparison of an image created by cairo and an image loaded from a file
body: <p>I have some code in nim that creates a picture using Cairo (<a href="https://github.com/nim-lang/cairo" rel="nofollow noreferrer">https://github.com/nim-lang/cairo</a>).  I would like to compare that picture to another using diffimg (<a href="https://github.com/SolitudeSF/diffimg" rel="nofollow noreferrer">https://github.com/SolitudeSF/diffimg</a>, <a href="https://github.com/SolitudeSF/imageman" rel="nofollow noreferrer">https://github.com/SolitudeSF/imageman</a>).</p>
  <p>But there does not seem to be a standard in memory image type.  Is there any way to do this that does not involve saving the image to a file first?</p>