What is the right way to set the Kinfu raycaster to use an off-axis projection? I can set the intrinsics (fx, fy, cx, cy), but I am not sure how to derive the latter two values from an existing projection matrix (such as from OpenGL).
So far I am using this psudocode:
float Fx = width / (2.f * tan(hFov / 2.f)); // Convert FOV to focal length
float Fy = height / (2.f * tan(vFov / 2.f));
float Cx = projectionMatrix[0,2]; // I suspect this line is incorrect
float Cy = projectionMatrix[1,2];