title: C++: parsing a 132x65 binary file
body: <p>So here is what i have/have to do. I have a .txt file that has a big picture of 132x72. What i need to do is put that into a c array of hex values.</p>
  
  <p>I need to find a way to grab the first character of the top 8 lines and put them together horizontally so i can then convert them into hex. Then i need to do that 9 times down.</p>
  
  <p>Example:</p>
  
  <pre><code>00000
  00000
  11111
  01010
  10101
  10101
  01010
  10101
  </code></pre>
  
  <p>That i would need to turn into:</p>
  
  <pre><code>00101101
  00110010
  00101101
  00110010
  00101101
  </code></pre>
  
  <p>What is the best/simplest way to do this? I honestly do not know where to start.</p>