Avoid zero tangnet vectors on degenerate NURBS edges. Fixes #652#746
Avoid zero tangnet vectors on degenerate NURBS edges. Fixes #652#746phkahler merged 1 commit intosolvespace:masterfrom
Conversation
|
Calling recursively looks clean, I may change mine here to do the same. But you use the flag to avoid endless recursion (in some weird potential "NURBS universe"). I don't like the flag as an exposed interface (#736 (comment)) How does You need to pass a tolerance to Equals, IMHO the default is too big. Check "sungularities" = singularities As for my overall opinion on the "numerical" (vs. logical) approach - did you take a look at this? |
Oops. I started out thinking a weighted average so 0.99v + 0.01(1-v) and then was thinking something more like what you suggest. Brain just didn't write either one correctly. I prefer (0.5-v). Isn't LENGTH_EPS really small? Using the flag to avoid infinite recursion just seems like a good idea, especially if you want to use such a tiny movement. Like I said before, it also allows flexibility at the call site but we don't really need that once it's fixed. EDIT: hahaha joke is on me. LENGTH_EPS = 0.000001 |
|
You mean switch the order? OK. Does that mean you're ok with "check result and retry" vs the "check for degenerate curve and pre-emptively move u,v" ? |
|
This one is shorter, that is it's advantage. The other one is faster (but I need to measure, this is just based on amount of calculations) and "more correct" (whatever that meas) but more verbose... The problem is that I have not had time to work on it more... |
@ruevs This is probably the clearest and cleanest we can get. What do you think?