Class StereoProc

java.lang.Object
edu.tufts.hrilab.vision.util.StereoProc

public class StereoProc extends Object
Utility methods for stereo image processing.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static double[][]
    reprojectImageTo3D(byte[] depthData, int width, int height, double f)
    Convert depth image (e.g., from kinect or xtion) into 3D points.
    static double[][]
    reprojectImageTo3D(byte[] disparity, int width, int height, double f, double T, double scale)
    Convert disparity image into 3D points.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • StereoProc

      public StereoProc()
  • Method Details

    • reprojectImageTo3D

      public static double[][] reprojectImageTo3D(byte[] disparity, int width, int height, double f, double T, double scale)
      Convert disparity image into 3D points. [X Y Z W] = Q * [x y disp(x,y) 1]^T 3dImage(x,y) = (X/W, Y/W, Z/W) Q =| 1 0 0 -Cx | | 0 1 0 -Cy | | 0 0 0 f | | 0 0 a b | ========================== X = (x-Cx)*T/disp(x,y); Y = (y-Cy)*T/disp(x,y); Z = f*T/disp(x,y); ===========================
      Parameters:
      disparity -
      width - image width (pixel units)
      height - image height (pixel units)
      f - focal length (pixel units)
      T - baseline length between optical centers (world units)
      scale - (current disparity image height) / (original disparity image height)
      Returns:
    • reprojectImageTo3D

      public static double[][] reprojectImageTo3D(byte[] depthData, int width, int height, double f)
      Convert depth image (e.g., from kinect or xtion) into 3D points.
      Parameters:
      depthData - raw depth data
      width - depth data width
      height - depth data height
      f - focal length
      Returns: