voxelizer
floodfilling and distance map generation for 3d surfaces
Dan Morris - Stanford University Haptics Lab

overview

using voxelizer interactively

using the voxelizer .ini file

output format

download / source

sample meshes

technical information

contact

 

overview

This program floodfills a surface mesh (which must be very nearly watertight) to produce a voxel array, optionally computing a distance field in the process (the distance from each voxel to the surface and the corresponding closest surface point). The program can also compute shortest distances for each voxel to a series of additional meshes (up to 5). It can load models in 3ds, obj, and ply formats, and the .node/.face format used by TetGen. The output format is a ".voxels" file, which is a binary format described in voxel_file_format.h . The program can also output tetrahedral meshes in TetGen format; the floodfilling process is identical to that used for voxelization, and each voxel is simply split into five tets (so the mesh is not conformal). Voxelization can be initiated interactively or from an .ini file. A Matlab script is included to read the resulting files into Matlab.

The application was developed in C++ and is based on CHAI and WinMeshView.



using voxelizer interactively

When voxelizer starts up, you'll see the GUI pictured at the right. To voxelize a model, click "load model" and choose the model you want to voxelize.

Before voxelizing an object, you may want to click "test voxelization" just to confirm that the floodfill is successful and that the mesh is watertight (if it's not, the whole bounding box of the mesh will get filled). When you're ready to voxelize, just click "voxelize". If the object is "hello.obj", you'll get a file called "hello.v[nn].voxels", where "nn" indicates the resolution of voxelization (see below).

Other parameters you can change: