title: Taking a screenshot of a window in C using only the X11 lib
body: <p>I am coding a raytracer engine in C using X11 on a Linux. I would like to add a screenshot feature but I can't use any other lib than the standard X11.</p>
  
  <p>Is there a "simple" way to do that, or do I have to create a bmp file myself from the pixels I have?</p>