Emgu.CV.PointCollection.ReprojectImageTo3D C# (CSharp) Метод

ReprojectImageTo3D() публичный статический Метод

Reproject pixels on a 1-channel disparity map to array of 3D points.
public static ReprojectImageTo3D ( Byte>.Image disparity, Matrix Q ) : MCvPoint3D32f[]
disparity Byte>.Image Disparity map
Q Matrix The reprojection 4x4 matrix, can be arbitrary, e.g. the one, computed by cvStereoRectify
Результат MCvPoint3D32f[]
        public static MCvPoint3D32f[] ReprojectImageTo3D(Image<Gray, Byte> disparity, Matrix<double> Q)
        {
            Size size = disparity.Size;
             MCvPoint3D32f[] points3D = new MCvPoint3D32f[size.Width * size.Height];
             GCHandle handle = GCHandle.Alloc(points3D, GCHandleType.Pinned);

             using (Matrix<float> pts = new Matrix<float>(size.Height, size.Width, 3, handle.AddrOfPinnedObject(), 0))
            CvInvoke.cvReprojectImageTo3D(disparity.Ptr, pts.Ptr, Q);

             handle.Free();
             return points3D;
        }

Same methods

PointCollection::ReprojectImageTo3D ( Int16>.Image disparity, Matrix Q ) : MCvPoint3D32f[]