MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0023011Community[OCCT] OCCT:Shape Healingpublic2012-03-05 15:042017-07-13 17:04
Reporterkapilbhudhia 
Assigned Togka 
PriorityhighSeveritymajor 
StatusassignedResolutionopen 
PlatformVisual Studio 9, Win32OSWIndowsOS VersionWin 7
Product Version[OCCT] 6.5.2 
Target VersionFixed in Version 
Summary0023011: ShapeAnalysis_Wire returns an incorrect CheckOrder
DescriptionCreate a Solid Cube and do some Analysis on it. So, I go through its faces and foreach face through all its wires (it is 1 in this case) and foreach wire I check the order.

To my utter shock the method
ShapeAnalysis_Wire::CheckOrder() returns true -- which basically means that the wire is not ordered correctly.

Either the solid cube is created wrong or the CheckOrder API is returing a wrong result or I am doing something utterly silly.

----------- THE CODE ---------

// create a solid bounding box
BRepPrimAPI_MakeBox outerBox(gp_Pnt(-10000, -10000, -10000), gp_Pnt(10000, 10000, 10000));

for (TopExp_Explorer faceIter(outerBox.Solid(), TopAbs_FACE);
faceIter.More();
faceIter.Next())
{
const TopoDS_Face& aFace = TopoDS::Face(faceIter.Current());

for (TopExp_Explorer wireIter(aFace, TopAbs_WIRE);
wireIter.More();
wireIter.Next())
{
const TopoDS_Wire& aWire = TopoDS::Wire(wireIter.Current());
double precision = 1e-04;
ShapeAnalysis_Wire saw(aWire, aFace, precision);
if (saw.CheckOrder())
{
throw gcnew Exception("Wire not ordered properly");
}
}
}
Steps To ReproduceCreate a small console app with the following code

// create a solid bounding box
BRepPrimAPI_MakeBox outerBox(gp_Pnt(-10000, -10000, -10000), gp_Pnt(10000, 10000, 10000));

for (TopExp_Explorer faceIter(outerBox.Solid(), TopAbs_FACE);
faceIter.More();
faceIter.Next())
{
const TopoDS_Face& aFace = TopoDS::Face(faceIter.Current());

for (TopExp_Explorer wireIter(aFace, TopAbs_WIRE);
wireIter.More();
wireIter.Next())
{
const TopoDS_Wire& aWire = TopoDS::Wire(wireIter.Current());
double precision = 1e-04;
ShapeAnalysis_Wire saw(aWire, aFace, precision);
if (saw.CheckOrder())
{
throw gcnew Exception("Wire not ordered properly");
}
}
}
TagsNo tags attached.
Test case number
Attached Files

- Relationships

-  Notes
(0068270)
mkv (tester)
2017-07-13 17:04

Dear GKA,
could you put your opinion about it.

- Issue History
Date Modified Username Field Change
2012-03-05 15:04 kapilbhudhia New Issue
2012-03-05 15:04 kapilbhudhia Assigned To => gka
2017-07-13 17:04 mkv Note Added: 0068270
2017-07-13 17:04 mkv Status new => assigned


Copyright © 2000 - 2021 MantisBT Team
Powered by Mantis Bugtracker