3D
MAGISCAN
Back to all articles

How to Fix Holes and Clean Up a 3D Scan

How to Fix Holes and Clean Up a 3D Scan

Fix holes and clean up a 3D scan: delete floating pieces, merge vertices, fill small holes, bridge or rescan large ones, then smooth, check and export.

To fix holes and clean up a 3D scan, work in a fixed order: delete floating fragments and stray points, merge duplicate vertices, fill the small holes automatically, then bridge or patch the large ones and smooth only where the surface is noisy. If a hole sits over a real feature, such as an edge, a hinge or a logo, rescan that area instead of inventing geometry, because no fill algorithm knows what was there.

Why does a 3D scan have holes and floating junk?

A scanner can only build surface where it collected data, whether it is a LiDAR sensor, a handheld structured-light scanner or a photogrammetry pipeline working from photos. Holes appear where the camera never saw the surface: the underside resting on the table, deep recesses, the inside of a handle, the gap between two fingers. They also appear on surfaces that return poor data, such as gloss paint, chrome, black rubber and glass. If that is your problem, capture technique matters more than cleanup, and our guide on how to 3D scan shiny, black or transparent objects covers it.

Floating junk has the opposite cause. Reflections, background objects, the turntable, dust and people walking past produce points that do not belong to the object. After meshing they turn into small disconnected islands and spikes. Artec's documentation describes exactly this: outliers that are not removed before fusion can be solidified and kept in the scene as small, distant fragments (Artec Studio 20 documentation).

Knowing which problem you have tells you which tool to reach for. Holes need filling or a new capture. Junk needs deleting. Noise, the fine roughness on a surface that was captured, needs gentle smoothing and nothing more.

Should you rescan or repair the mesh?

Decide this before you open an editor, because it changes how much time the cleanup is worth.

Repair the mesh when:

  • the hole is on a flat or gently curved patch and the surface around it is clean;
  • the model is for viewing, a product preview or a print where that area carries no function;
  • the missing area is the part the object stood on and the base is flat.

Rescan when:

  • the hole covers a feature you need, such as an edge, a screw boss, a label or a joint;
  • you will take measurements across that region, because a filled patch is interpolated, not measured (see how to get accurate measurements from a 3D scan);
  • the holes are many and scattered, which usually means the capture itself went wrong.

For a phone scan, a second capture is often less work than rebuilding a feature by hand. With an app such as MagiScan, set the object on its side or raise it on a narrow stand so the camera can see the area that was hidden, and move slowly around the part that came out empty.

What order should you clean up a 3D scan in?

The order matters because each step makes the next one easier or harder. Filling holes before deleting islands makes the filler treat every fragment's open edge as one more hole; simplifying before filling makes hole boundaries coarse; heavy smoothing before filling rounds off the edges the fill has to match.

  1. Keep the original. Save a copy of the raw export. Most cleanup steps are destructive.
  2. Delete disconnected pieces. In Artec Studio, the small-object filter's "All except largest" option erases every object except the one with the most polygons (Artec Studio 20 documentation). In Blender, Delete Loose deletes selected vertices, edges and, optionally, faces that are not connected to anything (Blender manual, Clean Up). A floating island of connected faces does not count as loose, so select such islands and delete them by hand.
  3. Remove stray points if you still have a point cloud. Open3D's statistical outlier removal drops points that sit further from their neighbours than the cloud's average. Its nb_neighbors parameter sets how many neighbours are counted, and std_ratio sets the threshold: the lower it is, the more aggressive the filter (Open3D documentation). The tutorial's example uses nb_neighbors=20 and std_ratio=2.0; start there and lower std_ratio only if stray points survive.
  4. Merge duplicate vertices. Blender's Merge by Distance merges selected vertices that are closer to each other than the distance you set. Doubled vertices along a seam leave edges that look open even where the surface is continuous, and that confuses hole detection.
  5. Fill small holes, then large ones. The next two sections cover both.
  6. Smooth locally. Smooth noisy regions with a brush rather than the whole model, so sharp edges stay sharp.
  7. Simplify last. Reduce the polygon count only after the surface is closed and clean.
  8. Check and export. See the last section.

How do you fill small holes automatically?

Automatic filling works well on small holes that are completely surrounded by surface: pinholes from a missed frame, gaps on a smooth panel, a missing patch on a curved housing.

In Blender, select the mesh in Edit Mode and run Mesh, Clean Up, Fill Holes. The Sides setting is the maximum number of sides: a hole with more edges than that number is not filled, and 0 fills all holes (Blender manual, Clean Up). Start with a low value so only the small gaps close, inspect the result, then raise it step by step.

RealityScan works the same way. Its Close Holes tool closes holes that are completely enclosed by mesh geometry, on the whole model or only on a selection, and the Max edges count keeps it from closing any hole with more edges than that value. The help page also suggests running Check Topology to see how many holes the model has (RealityScan Help, Close Holes).

The edge limit exists for a reason. A small hole has a short boundary, and the surrounding surface predicts its shape well. A large hole has a long boundary, and a simple fill cuts straight across what should be a curve. Be careful with fill-everything settings: they also close boundaries you want open, such as the cut base of a bust or the open end of a pipe.

How do you fix large holes without distorting the shape?

The usual failure with a large hole is a flat cap that looks as if part of the object was sliced off. Three approaches avoid it.

Split the hole first. Artec Studio's Bridges tool connects a pair of edge fragments by constructing a surface that follows the curvature of the neighbouring surfaces (Artec Studio 20 documentation). One or two bridges across a big opening turn it into smaller holes that an automatic fill handles well. The same page offers a "Smooth edges first" checkbox to remove raggedness from the edges, and recommends clearing it when you need to preserve the original geometry.

Use a grid fill instead of a single face. The Blender manual points to Face Fill or Grid Fill for filling a large hole that has many edges. A grid gives the patch enough vertices to bend, so you can then smooth or sculpt it to match the surrounding curvature.

Watch real openings. A fill algorithm cannot tell a missing surface from a hole that exists in the object, such as the opening of a handle or a mounting hole. Check these by eye after every automatic step and undo any cap that closes a real opening.

If the patch still looks wrong after this, it is a sign the area should be rescanned rather than sculpted further.

How do you make the scan watertight for 3D printing?

A slicer needs a closed volume: no open edges, no faces pointing inward, no edges shared by more than two faces. Prusa's knowledge base notes that PrusaSlicer repairs models automatically to a certain degree, but not every corrupted model can be fixed that way. For the rest it lists free tools, including Meshmixer, whose Auto-repair is easy to use but does not always work, while Make Solid almost always works at the cost of resolution (Prusa Knowledge Base).

Scanning software can also close the mesh during processing. In Artec Studio, the Fill holes setting of the fusion step has an "All (watertight)" method that automatically fills all holes in the mesh, and the automatic hole filling in the Mesh Optimization tool has a Heal bad polygons option that handles non-manifold, dangling, crossing and folded polygons (Artec Studio 20 documentation). Use these when the print matters more than the exact shape of the filled areas.

For capture tips aimed at printing, see how to scan an object for 3D printing with a phone.

How do you check the cleaned scan before you export it?

Run four checks before you call the scan finished.

  • Holes: count the open boundaries again, with Check Topology in RealityScan or your editor's non-manifold selection. Every remaining boundary should be one you meant to keep.
  • Size: measure one distance on the real object with a ruler or calipers and compare it with the model. If the scale is off, fix it now; our guide on how to scale a 3D scan to real-world size walks through it.
  • Polygon count: simplify to what the next tool needs. In Blender, Decimate Geometry's ratio sets the target: 0.4 keeps collapsing edges until the triangle count is 40% of the original (Blender manual, Clean Up). Artec Studio can instead stop at a maximum shape deviation in millimetres, which suits parts you will measure.
  • Appearance: orbit the model under a plain light and look for flat caps, ridges along bridged seams and smoothed-away edges.

If your scans come from MagiScan, which exports scans for 3D printing, AR and e-commerce, do this cleanup on the exported file in the editor you prefer, then export again in the format the next step expects. Our guide on exporting a 3D scan to STL, OBJ or USDZ explains which to pick.

Frequently Asked Questions

Can you fill holes in a 3D scan automatically?

Yes, for small holes that are completely surrounded by surface. Tools such as Fill Holes in Blender and Close Holes in RealityScan do it in one step and let you limit the hole size by edge count. Large holes need bridging, a grid fill or a new capture.

Why does my 3D scan have a hole at the bottom?

The surface the object stood on never faced the camera, so there was no data to build it from. Rescan with the object on its side or raised on a stand, or fill the hole if the base is flat and its exact shape does not matter.

Does filling holes change the measurements of a scan?

A fill adds surface that was never captured, so every filled patch is an estimate, and so is any distance measured across it. Take measurements from captured areas, and rescan if the dimension you need runs through a hole.

Should I smooth a 3D scan before or after filling holes?

Clean ragged hole edges lightly before filling, then smooth noisy areas after the mesh is closed. Heavy smoothing before filling rounds off the boundary the fill has to match and blurs sharp edges you may want to keep.

Back to all articles