Contouring problem on Linux

If it doesn't fit elsewhere, it goes here
Post Reply
Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Contouring problem on Linux

Post by Unknown_User_634 » Wed Feb 07, 2007 10:58 am

Hello,

I am trying to run the Dual Contouring software at
http://www.sandboxie.com/misc/isosurf/isosurfaces.html

and finding that the programs demo1, demo2 and demo3 all exit at SDL_SetVideoMode() in demoio.cpp, i.e.: function returns null pointer.

I tried unsuccessfully the email of Dr. Tzur, whose name appears on this webpage. Can anyone suggest a way of contacting Ronen Tzur, or better still, suggest a means of determining what is going wrong?

Cheers,

Michel

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Post by Unknown_User_634 » Wed Feb 07, 2007 11:11 am

Please disregard. I found that it is a GLX Visual mismatch problem, based on the error message. I just have to set the parameters appropriately...

Michel

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Wed Feb 07, 2007 11:42 am

the email of Dr. Tzur
Nice. :)
tzuk

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Post by Unknown_User_634 » Wed Feb 07, 2007 11:48 am

When in doubt, I'd rather assume the invidual has the credentials. I have a doctorate (too), but insist on being called by my first name, which I'm finding goes against the grain here in Germany. In any event, it's useful in allowing me to call surgeons by their first name, which might not be the case otherwise :) .

In any event, I think that your contouring stuff is useful to me, for building patient-specific anatomical models for surgery simulation. I've been playing with Marching Cubes as an initialization for a discrete (simplex) surface model, whose mesh size I can control very precisely, and where the initial topology of a surface is provided by MC, but I'm open to something that is more faithful to topology and to edges than MC. So, thanks!

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Post by Unknown_User_634 » Wed Feb 07, 2007 11:51 am

One last question, while I have your attention. I found in the past that Marching Cubes was sensitive to Gaussian pre-filtering, or lack thereof. Do you find that the Dual method is less dependent on this pre-processing?

Cheers,

Michel

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Wed Feb 07, 2007 12:01 pm

I have a doctorate (too)
Oh, it was amusing to me, because I don't have one.
building patient-specific anatomical models for surgery simulation
That sounds interesting. First of all, good luck in your endeavor!
Do you find that the Dual method is less dependent on this pre-processing?
Can't help you there. First of all, I don't know what Gaussian pre-filtering is.

And secondly, I gave up (perhaps temporarily) on toying with 3D graphics shortly after I wrote this article, and I only studied Dual Contouring shortly before writing it.

But from what little I've seen, it seems that DC produces more accurate results than MC, when edges are involved, and equivalent results, when no edges or corners are involved.
tzuk

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Post by Unknown_User_634 » Wed Feb 14, 2007 8:48 am

Hi again,

whenever I run one of the demos, everything is highly magnified on my computer thereafter. Can you think of a quick fix?

Cheers,

Michel

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Post by Unknown_User_634 » Wed Feb 14, 2007 9:17 am

One more comment, this one algorithmic.

Your code assumes that it is possible to evaluate implicit functions at sub-voxel precision, such as when you do calcDensity(xt+0.001f, yt,zt), based on an analytical expression for distance in a sphere , and so on, in order to compute fNormal().

However, in applying dual contouring to volumetric data, the best one can do is compute a signed distance at every voxel, based on the Fast Marching method. It is possible to estimate this distance at sub-voxel level, but this would be based on linear interpolation, for example, between voxels, so you might as well set Epsilon= pixel_spacing_x, or ..._y, or ..._z, rather than .001.

Is this not true, or am I missing something? Can the method work then?

Just wondering.

Michel

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Wed Feb 14, 2007 4:43 pm

The normal is really a psuedo normal. After all, a point on its own doesn't have a direction. Each component of the psuedo normal (x,y, and z) is computed by looking at the evaluation of the function for two nearby points. The smaller the distance between these two points, the more accurate the psuedo normal is.
tzuk

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

Post by Unknown_User_634 » Thu Feb 15, 2007 5:21 am

Hi again,

any thoughts about the zoomed-in appearance of my screen? Is it a simple ressource to reset?

Cheers,

Michel

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Thu Feb 15, 2007 4:15 pm

I don't know. I wrote this for Windows with Cygwin and it was working just fine.
tzuk

Unknown_User_634
Posts: 0
Joined: Wed Dec 31, 1969 7:00 pm

PlanesList vs FacesList

Post by Unknown_User_634 » Tue Feb 27, 2007 12:36 pm

Hi again,

one more question... for now. A mesh seems to include a PlanesList, each member of which contains a FacesList. Can you indicate the distinction to me between the two? In the example on which I am working, I get several PlanesList members with very few Faces (sometimes 2) in them. Is a Plane a contiguous surface, possibly closed, consisting of several faces?

I'm wondering how to tweak the data or method so that I that I get fewer spurious PlanesLists...

Thanks again for your help. Cheers,

Michel

tzuk
Sandboxie Founder
Sandboxie Founder
Posts: 16076
Joined: Tue Jun 22, 2004 12:57 pm

Post by tzuk » Tue Feb 27, 2007 2:48 pm

Plane is the theoretical mathematical entity, an infinite plane in 3-space.

Face is a single triangle.

So the relationship is that a mesh contains a list of planes. Each plane contains the faces (triangles) that are aligned on that plain.

Maybe there bugs or floating point errors that cause triangles that should be on the same plane (that is, be on the same list), to appear on separate planes. But that would be bugs, not the intent.

This helps?
tzuk

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest