# Point Cloud Tools (PLY, XYZ) > Point cloud statistics, outlier removal, voxel downsampling, normals and RANSAC plane fits. Upload a PLY, XYZ, CSV or PTS point cloud to measure it — point count, bounding box, centroid, nearest-neighbour spacing and density — and clean it: remove statistical outliers, thin it on a voxel grid and estimate normals from the nearest neighbours. Fit up to five planes (floors, walls, tables) with seeded RANSAC and get each plane’s equation, tilt and inlier report, then download the processed cloud as PLY or XYZ. Runs on the same engine as Renderloom Mesh Lab. Part of usefulweb.site (https://usefulweb.site/). Part of [Renderloom](https://renderloom.usefulweb.site/) (ownerApp: renderloom). Results are deterministic calculations from the inputs and the listed assumptions; the API returns exactly what the web page shows. ## Use it - Human interface: https://renderloompointcloudtools.usefulweb.site/ (interactive tool at https://renderloompointcloudtools.usefulweb.site/tool) - JSON API: POST https://renderloompointcloudtools.usefulweb.site/api/v1/calculate with a JSON object of inputs (schema: https://renderloompointcloudtools.usefulweb.site/api/v1/tool) - OpenAPI: https://renderloompointcloudtools.usefulweb.site/openapi.json - MCP (Streamable HTTP): https://renderloompointcloudtools.usefulweb.site/mcp - tool `renderloom_point_cloud_tools` ## Inputs - file (file): Point cloud (PLY, XYZ, CSV, TXT or PTS) - ASCII or binary PLY (vertex-only or with faces, which are ignored), or a text table with x y z per line and optional r g b and nx ny nz columns. Up to 60 MB and 1000000 points. - cloudText (textarea): Or paste points (x y z per line) - removeOutliers (boolean): Remove statistical outliers - outlierNeighbors (integer): Neighbours for outlier removal (k) - outlierStd (number): Standard deviation multiplier (α) - voxelSize (number): Voxel size for downsampling (0 = off) - In the units of the file, for example 0.05 for 5 cm voxels in a cloud in metres. - estimateNormals (boolean): Estimate normals - normalNeighbors (integer): Neighbours for normals (k) - orientation (select): Normal orientation - viewpoint (text): Viewpoint x, y, z - Where the scanner or camera stood. Normals point towards it. - fitPlane (boolean): Fit planes (RANSAC) - planes (integer): Number of planes - planeThreshold (number): Inlier distance threshold (0 = automatic) - Points closer to the plane than this count as inliers. Automatic: 2.5 × the median point spacing. - planeIterations (integer): RANSAC iterations (maximum) - seed (integer): Random seed - The same seed gives the same planes. - output (select): Download the processed cloud as - view (select): Preview view ## Method - PLY files are read by the shared Renderloom mesh reader (ASCII and binary, little and big endian); vertex x, y, z, red/green/blue and nx/ny/nz properties are kept, faces are ignored. Text tables accept spaces, commas, semicolons or tabs, an optional header row (x, y, z, r, g, b, nx, ny, nz, intensity) and the PTS point-count line. - A balanced k-d tree (median split on the widest axis) answers exact k-nearest-neighbour queries. Spacing is the distance to the nearest other point (all points up to 200000, else an even sample of 200000); local surface density is the median of k / (π·r_k²) with k = 8. - Steps run in a fixed order. Outlier removal: mean distance dᵢ to the k nearest neighbours; points with dᵢ > μ + α·σ are removed. Voxel downsampling: one point per occupied cube (grid anchored at the bounding-box minimum) at the centroid of its points, colours averaged. - Normals: eigenvector of the smallest eigenvalue of the covariance of the k nearest neighbours (Jacobi eigen decomposition), oriented towards the viewpoint (n·(v − p) ≥ 0) or away from the centroid. Surface variation λ₀/(λ₀+λ₁+λ₂) measures local curvature. - Planes: RANSAC with a seeded random generator; each hypothesis through three points is scored on an even sample of at most 50000 points, the iteration count adapts to 99 % confidence, and the best plane is refined twice by least squares (PCA) on all its inliers. The default inlier threshold is 2.5 × the median spacing. For several planes the inliers are removed and the search repeats. ## Limits - Statistics describe the points as given, in the file’s units. The tool does not reconstruct surfaces or meshes. RANSAC is randomised (with a fixed seed, so results repeat); clouds with several similar planes can need more iterations or a tighter threshold.