It's my old code and I don't know if it works but you can do something like this in fragment shader:
orgPos.xy = (gl_TexCoord[0].st - vec2(512/2, 424/2));
orgPos.z = texture2DRect(kinectDepthStream, gl_TexCoord[0].st).r;
orgPos.y *= -1;
orgPos.z *= 65536.0; // originally unsigned short???
// camera model
orgPos.xy *= orgPos.z / 370.0;