findPlanes
import { findPlanes } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
Find the planes in a depth image
findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number, threshold: number, sensor_error_a: number, sensor_error_b: number, sensor_error_c: number, method: number): void;8 available overloads
findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number, threshold: number): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number, threshold: number, sensor_error_a: number): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number, threshold: number, sensor_error_a: number, sensor_error_b: number): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number, threshold: number, sensor_error_a: number, sensor_error_b: number, sensor_error_c: number): void;findPlanes(points3d: Mat, normals: Mat, mask: Mat, plane_coefficients: Mat, block_size: number, min_size: number, threshold: number, sensor_error_a: number, sensor_error_b: number, sensor_error_c: number, method: number): void;points3dthe 3d points organized like the depth image: rows x cols with 3 channels
normalsthe normals for every point in the depth image; optional, can be empty
maskOutput destination, filled by the native operation. An image where each pixel is labeled with the plane it belongs to and 255 if it does not belong to any plane
plane_coefficientsOutput destination, filled by the native operation. the coefficients of the corresponding planes (a,b,c,d) such that ax+by+cz+d=0, norm(a,b,c)=1 and c < 0 (so that the normal points towards the camera)
block_sizeThe size of the blocks to look at for a stable MSE
min_sizeThe minimum size of a cluster to be considered a plane
thresholdThe maximum distance of a point from a plane to belong to it (in meters)
sensor_error_acoefficient of the sensor error. 0 by default, use 0.0075 for a Kinect
sensor_error_bcoefficient of the sensor error. 0 by default
sensor_error_ccoefficient of the sensor error. 0 by default
methodThe method to use to compute the planes.
These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.