fiji / 3D_Viewer

https://imagej.net/plugins/3d-viewer
GNU General Public License v3.0
19 stars 18 forks source link

3D Viewer overhaul #19

Open kephale opened 8 years ago

kephale commented 8 years ago

<edit: We have moved beyond most of these issues. Look at SciView for updated information>

3D_Viewer is problematic these days, but sometimes still does the job and is a dependency for a number of plugins.

The idea is to replace the Java3D backend of 3D_Viewer with Scenery to help transition to a more modern 3D rendering system. In doing so, a number of features that have been built directly into 3D_Viewer can be made into core code:

Dealing with 3D data structures:

Rendering and UI for 3D:

Where the action is:

Relevant Peoples: @dietz @tpietzsch @skalarproduktraum @ctrueden @rimadoma

ctrueden commented 7 years ago

Unify duplicate vertices (a number of geometric operations will fail if there are duplicate vertices)

Heh, my favorite scheme for dealing with that historically has been to randomly perturb all samples by tiny epsilons, prior to computing spatial structures such as triangulations. Very dirty, but avoids pathological situations.

Of course, I'm not suggesting we do that here... I guess it depends on the data structure. If the points are sorted, removing duplicates is easy.

acardona commented 7 years ago

The 3D Viewer contains a library within. Indeed, some operations (that I wrote years ago) such as mesh decimation and mesh smoothing, and saving and importing to wavefront .obj and STL formats. These could somewhat easily be separated into its own .jar library file.

Glad to read that the marching cubes that Benjamin Schmidt wrote has already been implemented as a library; I recall that Bene tried very hard to remove a bug in the marching cubes that created some meshes with non-manifold edges, but that bug likely was in the original graphics gems algorithm. Is the bug also in the imagej-ops library, I wonder?

kephale commented 7 years ago

@tibuch note this marching cubes comment about a potential algorithmic bug ^^^

For completeness, I'll note that we've been trying to stay close to the design choices of IJ2, which has led to:

(To be clear: not all of this has been done yet, but these are the choices that a few folks have agreed on)

tibuch commented 7 years ago

The marching cubes implementation is based on this. As far as I can tell the problem of non-manifold edges/points is present in this implementation. But I am not sure if we can call it a bug.