title: Fastest dithering / halftoning library in C
body: <p>I'm developing a custom thin-client server that serves rendered webpages to its clients. Server is running on multicore Linux box, with Webkit providing the html rendering engine.</p>
  
  <p>The only problem is the fact that clients display is limited with a 4bit (16 colors) grayscale palette. I'm currently using LibGraphicsMagick to dither images (RGB->4bit grayscale), which is an apparent bottleneck in the server performance. Profiling shows that more than 70% of time is spent running GraphicsMagick dithering functions. </p>
  
  <p>I've explored stackoverflow and the Interwebs for a good high performance solution, but it seems that nobody did any benchmarks on various image manipulation libraries and dithering solutions. </p>
  
  <p>I would be more that happy to find out:</p>
  
  <ol start="2">
  <li>What are the highest performance libraries in regards to dithering / halftoning / quantizing RGB images to 4bit grayscale.</li>
  <li>Are there any specilized dithering libs or any public domain code snippets that you could point me to?</li>
  <li>What libraries do you prefer for manipulating graphics in regards to high performance?</li>
  </ol>
  
  <p>C language libraries are prefered. </p>