Computing multiple depth points between the closest and the farthest pixel.
Following equations are the line from the camera to the pixel then it inverse
37
Expression 38: "f" Subscript, "c" "a" "m" "e" "r" "a" "T" "o" "P" "i" "x" "e" "l" , Baseline left parenthesis, "t" , "c" , "p" , right parenthesis equals "c" plus "t" times left parenthesis, "p" minus "c" , right parenthesisfcameraToPixelt,c,p=c+t·p−c
38
Expression 39: "f" Subscript, "i" "n" "v" "C" "a" "m" "e" "r" "a" "T" "o" "P" "i" "x" "e" "l" , Baseline left parenthesis, "f" , "c" , "p" , right parenthesis equals StartFraction, left parenthesis, "f" minus "c" , right parenthesis Over left parenthesis, "p" minus "c" , right parenthesis , EndFractionfinvCameraToPixelf,c,p=f−cp−c
39
Expression 40: "t" Subscript, "c" "l" "o" "s" "e" "s" "t" "X" , Baseline equals "f" Subscript, "i" "n" "v" "C" "a" "m" "e" "r" "a" "T" "o" "P" "i" "x" "e" "l" , Baseline left parenthesis, "P" Subscript, "c" "l" "o" "s" "e" "s" "t" , Baseline . "x" , "C" . "x" , "P" . "x" , right parenthesistclosestX=finvCameraToPixelPclosest.x,C.x,P.x