title: Unpacking RGBA depth value in three.js
body: <p>I'm trying to implement a simple GPU picker in three.js using the MeshDepthMaterial. I've managed to extract the color value using the following example:
  <a href="https://github.com/mrdoob/three.js/blob/master/examples/webgl_interactive_cubes_gpu.html" rel="nofollow noreferrer">https://github.com/mrdoob/three.js/blob/master/examples/webgl_interactive_cubes_gpu.html</a></p>
  
  <p>And by porting the unpackRGBAToDepth function from here to javascript to reconstruct the depth:</p>
  
  <p><a href="https://github.com/mrdoob/three.js/blob/acdda10d5896aa10abdf33e971951dbf7bd8f074/src/renderers/shaders/ShaderChunk/packing.glsl" rel="nofollow noreferrer">https://github.com/mrdoob/three.js/blob/acdda10d5896aa10abdf33e971951dbf7bd8f074/src/renderers/shaders/ShaderChunk/packing.glsl</a></p>
  
  <p>But the value comes out as a float between 0.0 and 255.0 ( I was expecting it to be between 0.0 and 1.0 or the actual depth). My question follows: how can I use this value, can it be translated to the actual depth? If so, how?</p>