title: Convert VERY large ppm files to JPEG/JPG/PNG?
body: <p>So I wrote a  C++ program that produces very high resolution pictures (fractals). 
  I use fstream to save all the data in a .ppm file.</p>
  
  <p>Everything works fine, but when I go into really high resolution (38400x21600) the ppm file has ~8 Gigabytes. 
  With my 16 Gigabytes of Ram, however, I am still not able to convert that picture. I downloaded couple of converters, but they couldn't handle it. Even Gimp crashed when I try to "export as...". </p>
  
  <p>So, does anyone know a good converter that can handle really large ppm files? In fact, I even want to go above 100 Gigabytes. I don't care if it's slow, it should just work.</p>
  
  <p>If there is no such converter: Is there a way to std::ofstream in a better way? Like maybe, is there a library that automaticly produces a PNG file?</p>
  
  <p>Thanks for you help !</p>
  
  <p>Edit: also I asked myself what might be the best format for saving these large images. I researched and JPEG looks quite pretty (small size, still good quality). But may be there a better format? Let me know. Thanks</p>