Monday, November 18, 2013

Big Mole hill to fill holes - Meshlab

For a few days I was battling holes in a very dense mesh, a taste of which you can find here - Aero3Dpro. Meshlab is pretty handy for working with these, but there was a UI bug in edit_holes plugin preventing sorting of the holes to identify and squash the biggest ones. So in addition to filing a bug I decided to look into it myself.

There was a small run into the Qt change of ownership dilemma, tracking down the tools required some digging. Eventually I tracked down a working source set, had to compile it myself since the x64 binary I was depending on was built without QtScript support which Meshlab uses. By the end of all the trial and error I had 3 versions of Qt kicking around in my system - 4.8.0, 4.8.1 and 4.8.3. At least they all work for various projects.

Time to start writing my own meshlab plugins such as polygon based selection as featured in 3D Studio Max (called Fence Selection) or Cloud Compare(called Manual Segmentation). Also the Edit holes tool can be modified to automatically select larger holes to fill. Fixing up the textures to vertex colour transfer, since only the first texture is sampled -
path = path.left(std::max(path.lastIndexOf('\\'),path.lastIndexOf('/'))+1)

Also linking up with libLAS to allow LAS format saving with offsets and scale avoiding quantisation errors. More meshlab development to come.
Post a Comment