MantisBT - VTK | |||||
| View Issue Details | |||||
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0001868 | VTK | (No Category) | public | 2005-05-19 08:18 | 2013-04-05 19:57 |
| Reporter | Marijn van Stralen | ||||
| Assigned To | Zhanping Liu | ||||
| Priority | high | Severity | major | Reproducibility | always |
| Status | closed | Resolution | fixed | ||
| Platform | OS | OS Version | |||
| Product Version | |||||
| Target Version | Fixed in Version | ||||
| Project | |||||
| Type | |||||
| Summary | 0001868: vtkTriangle::PointInTriangle returns true if on extended line of line segment | ||||
| Description | The method vtkTriangle::PointInTriangle returns true if the point is on the full line of one of the line segments, and thus NOT in the triangle. This is not an edge problem, but a serious error. In the following code, all points are in the triangle according to vtkTriangle::PointInTriangle(...), while only the second should be: void vtkTriangleTest(){ double p1[3] = {0,7,0}; double p2[3] = {0,10,0}; double p3[3] = {5,7,0}; double x1[3] = {0,11,0}; double x2[3] = {0.0001,8,0}; double x3[3] = {0,1,0}; if (vtkTriangle::PointInTriangle(x1, p1, p2, p3, 0.01)){ std::cout << "1: " << "Point in triangle" << std::endl; } else std::cout << "1: " << "Point NOT in triangle" << std::endl; if (vtkTriangle::PointInTriangle(x2, p1, p2, p3, 0.01)){ std::cout << "2: " << "Point in triangle" << std::endl; } else std::cout << "2: " << "Point NOT in triangle" << std::endl; if (vtkTriangle::PointInTriangle(x3, p1, p2, p3, 0.01)){ std::cout << "3: " << "Point in triangle" << std::endl; } else std::cout << "3: " << "Point NOT in triangle" << std::endl; } | ||||
| Steps To Reproduce | |||||
| Additional Information | |||||
| Tags | No tags attached. | ||||
| Relationships | |||||
| Attached Files | https://www.vtk.org/Bug/file/5294/vtkTriangle.cxx.patch | ||||
| Issue History | |||||
| Date Modified | Username | Field | Change | ||
| 2008-09-23 11:30 | Berk Geveci | Assigned To | Will Schroeder => Zhanping Liu | ||
| 2008-09-25 16:23 | Zhanping Liu | Note Added: 0013585 | |||
| 2008-09-25 16:24 | Zhanping Liu | Status | tabled => @80@ | ||
| 2008-09-25 16:24 | Zhanping Liu | Resolution | open => fixed | ||
| 2011-06-16 13:11 | Zack Galbreath | Category | => (No Category) | ||
| 2013-04-05 19:57 | Berk Geveci | Status | customer review => closed | ||
| Notes | |||||
|
|
|||||
|
|
||||
|
|
|||||
|
|
||||
|
|
|||||
|
|
||||