Create_Surfaces


1. Installation

Download IntSeg_3D.jar and copy it to the plugins directory of ImageJ or Fiji. On ImageJ, you will also need to install ImageJ 3D Viewer.



2. Purpose

This plugin takes as input either a binary image or an image in the Amira labelfield format and creates smooth surfaces from them, using the marching cubes method. The resulting meshes are displayed in the 3D viewer, and can subsequently be decimated to a user-defined extent.

More information about the theoretical background can be found in this manuscript and in chapter 4 of my thesis.



3. Starting the software

Open a binary image stack (in the example below showing the mushroom bodies of a Drosophila brain) and select 'Create Surfaces' from ImageJ's 'Plugins' menu. A dialog opens, which allows you to specify a name for the new surface and a color. Click 'OK' after providing the corresponding values.



4. Mesh simplification

The software will first smooth your image, using Gaussian blurring, and then extract a surface using the marching cubes method. Once the surface is generated, it is displayed in the 3D Viewer. You can now decimate this mesh (i.e. decrease the number of vertices), by iteratively contracting edges. The plugin will automatically identify the edges to fuse next in an order which preserves the shape of the mesh as much as possible.

A dialog opens up:

Contract n edges.
Specify the number of edges which should be fused after clicking on 'Simplify'. Fusing one edge effectively reduces the number of vertices by one.
9858 remaining vertices
This means that the surface currently consists of 9858 vertices.
Simplify
Click on 'Simplify' to remove the specified number of vertices. Once this is performed, the displayed surface will be updated. The dialog will remain open for optional further mesh simplification.
Save
Click on 'Save' to save the currently displayed surface in OBJ format. This format can be read by the 3D viewer. After saving, the dialog will remain open for optional further mesh simplification.
Cancel
Click on 'Cancel' to cancel mesh simplification. The surface will remain displayed in the 3D viewer, for further processing.


5. Results

Shown below are the extracted surfaces of the mushroom bodies, with a different degree of simplification:



5. Creating surfaces from Amira labelfields

When starting the plugin on an Amira labelfield image (the image below shows some neuropils in a Drosophila brain), the plugin automatically reads the material information and displays a list of materials from which you can select those for which surfaces should be extracted:

After clicking 'OK', the surfaces are extracted as they are in the case of binary images, for all materials one after another. Once this is finished, all the extracted surfaces are shown in the 3D Viewer.

Mesh simplification is applied as described above. The whole surface (comprising all the materials) is simplified together, to yield a uniformly decimated mesh.

This is the result of mesh decimation. The original surface consisted of 75538 vertices: