calculate a pixel value
<p>If I have this code in C#:</p>

<pre><code>int index = 10;
float value = 20;

float* pixels = getPixelData();

pixels[index+1] = (byte)(value/256);
pixels[index+0] = (byte)(value &amp; 0xFF);
</code></pre>

<p>Then, the question is how to calculate the 'value' if I have:</p>

<pre><code>int index = 10;

pixels[index+1] = X;
pixels[index+0] = Y;

float value = ?
</code></pre>

<p>Thanks in advance. </p>
