View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0014563VTK(No Category)public2014-02-10 10:302016-08-12 09:55
ReporterGerrick Bivins 
Assigned ToWill Schroeder 
PriorityhighSeverityminorReproducibilityhave not tried
StatusclosedResolutionmoved 
PlatformOSOS Version
Product Version5.10.1 
Target VersionFixed in Version 
Summary0014563: vtkPolyDataNormals detecting feature edges incorrectly with vtkCutter
DescriptionHi All,
I’ve run into a situation where vtkPolyDataNormals is producing “incorrect” results for a plane in the x vs a plane in the y.
Using the default settings for “FeatureAngle” ie 30, and creating a slice plane in the x and y directions of my dataset, the attached
result is produced.
The issue is the edge is being detected as a “FeatureEdge” and so it’s vertices are duplicated, despite the faces being coplanar.
So when I looked at the code in vtkPolyDataNormals, I found the following code:

if ( vtkMath::Dot(thisNormal,neiNormal) > CosAngle )
{
   //found feature edge
….
}

In my case, the CosAngle is cos(30) so this is positive but I’m guessing(because I’m just looking at the code)
that the cutter has produced polygons whose normals are opposite each other, ie 180 so this is ~ -1, which is less than cos(30),
which results in the duplication of the vertices.

Is there a way around this without modifying VTK source? I tried calling polydatanormals in two passes,
one that does the orientation and then connect the output of that to a new polydatanormals that only performs the splitting but this didn’t seem
to have an effect on the output.
TagsComputeNormal, hackaton, normal of polygon, polyhedron, VTK
ProjectTBD
Typeincorrect functionality
Attached Filespng file icon polydata-normals-with-cutter-bug.png [^] (61,687 bytes) 2014-02-10 10:30


png file icon polydata-normals-with-cutter-bug-with-glyphs.png [^] (63,541 bytes) 2014-02-10 16:29

 Relationships

  Notes
(0032310)
Gerrick Bivins (reporter)
2014-02-12 09:31

In further testing I was able to work around this by using vtkPolydataNormals in twice.
1) consistency on, splitting and auto-orient off
2) consistency on, splitting on, auto-orient on

Looking at the code, it seems that auto-orient is the root cause in this issue but without it, some output is "dark" ie normals are inward.
(0033615)
Will Schroeder (manager)
2014-10-07 21:09

Do you have sample data and/or test program? The cutter should not be producing two polygons on top of each other, something else is going on.
(0033616)
Will Schroeder (manager)
2014-10-07 21:10

Please provide data or example test
(0036244)
Berk Geveci (administrator)
2016-07-06 16:48

Setting to status of bugs that have not been updated in the last year to expired. Please re-open if still important.
(0037320)
Kitware Robot (administrator)
2016-08-12 09:55

Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current VTK Issues page linked in the banner at the top of this page.

 Issue History
Date Modified Username Field Change
2014-02-10 10:30 Gerrick Bivins New Issue
2014-02-10 10:30 Gerrick Bivins File Added: polydata-normals-with-cutter-bug.png
2014-02-10 16:28 Gerrick Bivins Tag Attached: ComputeNormal
2014-02-10 16:28 Gerrick Bivins Tag Attached: normal of polygon
2014-02-10 16:28 Gerrick Bivins Tag Attached: VTK
2014-02-10 16:28 Gerrick Bivins Tag Attached: polyhedron
2014-02-10 16:29 Gerrick Bivins File Added: polydata-normals-with-cutter-bug-with-glyphs.png
2014-02-12 09:31 Gerrick Bivins Note Added: 0032310
2014-10-02 09:45 Will Schroeder Assigned To => Will Schroeder
2014-10-02 10:02 Will Schroeder Tag Attached: hackaton
2014-10-07 21:09 Will Schroeder Note Added: 0033615
2014-10-07 21:10 Will Schroeder Note Added: 0033616
2014-10-07 21:10 Will Schroeder Status backlog => active development
2016-07-06 16:48 Berk Geveci Status active development => expired
2016-07-06 16:48 Berk Geveci Note Added: 0036244
2016-08-12 09:55 Kitware Robot Note Added: 0037320
2016-08-12 09:55 Kitware Robot Status expired => closed
2016-08-12 09:55 Kitware Robot Resolution open => moved


Copyright © 2000 - 2018 MantisBT Team