ENH: improve distanceSurface handling (issue #1012)

- 'signed' input parameter only mandatory for distance > 0.
  A distance <= 0 is always signed and the input parameter is ignored.

- Use normal distance when distance == 0. This has no effect when
  the surface has no open edges, but improves on rounding issues
  around the zero crossing when the surface has open edges.

  This may still need future revisiting.
This commit is contained in:
Mark Olesen
2018-09-19 14:18:57 +02:00
parent 9973c378b9
commit 4aa94bd1d7
5 changed files with 59 additions and 27 deletions

View File

@ -42,6 +42,13 @@ debug
}
}
_disk1
{
surfaceType disk;
origin (-0.1 -0.05 0);
normal (1 1 1);
radius 0.015;
}
surfaces
(
@ -55,6 +62,16 @@ debug
surfaceName angledPlane.obj;
}
disk1
{
${_disk1}
type distanceSurface;
distance 0;
cell false;
signed true;
triangulate false;
}
iso
{
type isoSurface;