title: After byte shifitng a int to 4 bytes, how can I shift back to int (C)
body: <p>So I byte shift a integer into 4 bytes of data.</p>
  
  <pre><code>img[4] = (imagewidth &gt;&gt; 24) &amp; 0xFF;
  img[5] = (imagewidth &gt;&gt; 16) &amp; 0xFF;
  img[6] = (imagewidth &gt;&gt; 8) &amp; 0xFF;
  img[7] = imagewidth &amp; 0xFF;
  
  img[8] = (imageheight &gt;&gt; 24) &amp; 0xFF;
  img[9] = (imageheight &gt;&gt; 16) &amp; 0xFF;
  img[10] = (imageheight &gt;&gt; 8) &amp; 0xFF;
  img[11] = imageheight &amp; 0xFF;
  </code></pre>
  
  <p>Now how would I go about shifting it back to an integer. so <code>img[8]</code> - <code>img[11]</code> back to a single <code>int</code> or <code>img[4]</code> - <code>img[7]</code> back to a single <code>int</code></p>