Table of Contents

Method FindPlanes

Namespace
OpenCvSharp
Assembly
OpenCvSharp.dll

FindPlanes(InputArray, InputArray, OutputArray, OutputArray, int, int, double, double, double, double, RgbdPlaneMethod)

Finds the planes in a depth image.

public static void FindPlanes(InputArray points3d, InputArray normals, OutputArray mask, OutputArray planeCoefficients, int blockSize = 40, int minSize = 1600, double threshold = 0.01, double sensorErrorA = 0, double sensorErrorB = 0, double sensorErrorC = 0, RgbdPlaneMethod method = RgbdPlaneMethod.Default)

Parameters

points3d InputArray

the 3d points organized like the depth image: rows x cols with 3 channels.

normals InputArray

the normals for every point in the depth image; optional, can be empty.

mask OutputArray

an image where each pixel is labeled with the plane it belongs to (255 if none).

planeCoefficients OutputArray

the coefficients of the corresponding planes (a,b,c,d) such that ax+by+cz+d=0.

blockSize int

the size of the blocks to look at for a stable MSE.

minSize int

the minimum size of a cluster to be considered a plane.

threshold double

the maximum distance of a point from a plane to belong to it (in meters).

sensorErrorA double

coefficient of the sensor error (0 by default, use 0.0075 for a Kinect).

sensorErrorB double

coefficient of the sensor error (0 by default).

sensorErrorC double

coefficient of the sensor error (0 by default).

method RgbdPlaneMethod

the method to use to compute the planes.