mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-09 18:50:54 +03:00
0023819: Naming failures
Fixed regression with DummyVertex processing. Correction test cases for CR23819
This commit is contained in:
parent
b62b93ac30
commit
456b8422e1
@ -833,7 +833,28 @@ void TNaming_Builder::Modify(const TopoDS_Shape& oldShape,
|
|||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
static TopoDS_Vertex theDummyVertex (BRepBuilderAPI_MakeVertex(gp_Pnt(0.,0.,0.)).Vertex());
|
//function : DummyShapeToStoreOrientation
|
||||||
|
//=======================================================================
|
||||||
|
static const TopoDS_Shape& DummyShapeToStoreOrientation (const TopAbs_Orientation Or)
|
||||||
|
{
|
||||||
|
gp_Pnt aPnt(0,0,0);
|
||||||
|
static TopoDS_Vertex aVForward, aVRev;
|
||||||
|
switch(Or) {
|
||||||
|
case TopAbs_FORWARD:
|
||||||
|
if(aVForward.IsNull()) {
|
||||||
|
aVForward = BRepBuilderAPI_MakeVertex (aPnt).Vertex();
|
||||||
|
aVForward.Orientation(TopAbs_FORWARD);
|
||||||
|
}
|
||||||
|
return aVForward;
|
||||||
|
case TopAbs_REVERSED:
|
||||||
|
if(aVRev.IsNull()) {
|
||||||
|
aVRev = BRepBuilderAPI_MakeVertex (aPnt).Vertex();
|
||||||
|
aVRev.Orientation(TopAbs_REVERSED);
|
||||||
|
}
|
||||||
|
return aVRev;
|
||||||
|
}
|
||||||
|
return aVForward;
|
||||||
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : Select
|
//function : Select
|
||||||
@ -849,15 +870,15 @@ void TNaming_Builder::Select (const TopoDS_Shape& S,
|
|||||||
}
|
}
|
||||||
|
|
||||||
TNaming_RefShape* pos;
|
TNaming_RefShape* pos;
|
||||||
if(S.ShapeType() != TopAbs_VERTEX) {
|
|
||||||
TopoDS_Shape aV = theDummyVertex;
|
if(S.ShapeType() != TopAbs_VERTEX &&
|
||||||
aV.Orientation (S.Orientation());
|
(S.Orientation() == TopAbs_FORWARD || S.Orientation() == TopAbs_REVERSED)) {
|
||||||
|
const TopoDS_Shape& aV = DummyShapeToStoreOrientation (S.Orientation());
|
||||||
if (!myShapes->myMap.IsBound(aV)) {
|
if (!myShapes->myMap.IsBound(aV)) {
|
||||||
pos = new TNaming_RefShape(aV);
|
pos = new TNaming_RefShape(aV);
|
||||||
myShapes->myMap.Bind(aV,pos);
|
myShapes->myMap.Bind(aV,pos);
|
||||||
}
|
} else
|
||||||
else
|
pos = myShapes->myMap.ChangeFind(aV);
|
||||||
pos = myShapes->myMap.ChangeFind(aV);
|
|
||||||
} else {
|
} else {
|
||||||
if (!myShapes->myMap.IsBound(InS)) {
|
if (!myShapes->myMap.IsBound(InS)) {
|
||||||
pos = new TNaming_RefShape(InS);
|
pos = new TNaming_RefShape(InS);
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#1 - create box using more flexible set of commands
|
#1 - create box using more flexible set of commands
|
||||||
NewCommand D
|
NewCommand D
|
||||||
set B2 [AddObject D]; ## add object
|
set B2 [AddObject D]; ## add object
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#Drivers' nick-names:
|
#Drivers' nick-names:
|
||||||
#Box|Sph|Cyl|Cut|Fuse|Prism|Revol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
#Box|Sph|Cyl|Cut|Fuse|Prism|Revol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
||||||
# order of functions recomputation should be defined out of the tool (by end user)
|
# order of functions recomputation should be defined out of the tool (by end user)
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
||||||
#1 Box creation
|
#1 Box creation
|
||||||
NewCommand D
|
NewCommand D
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
||||||
|
|
||||||
#1 Create Box
|
#1 Create Box
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
||||||
|
|
||||||
#1 Create Box
|
#1 Create Box
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
#1 - create Box using short-cut
|
#1 - create Box using short-cut
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D Box; ## add box driver to driver table
|
AddDriver D Box; ## add box driver to driver table
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#Drivers' nick-names:
|
#Drivers' nick-names:
|
||||||
#Box|Sph|Cyl|Cut|Fuse|Prism|SecRevol|FulRevol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
#Box|Sph|Cyl|Cut|Fuse|Prism|SecRevol|FulRevol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
||||||
# order of functions recomputation should be defined out of the tool (by end user)
|
# order of functions recomputation should be defined out of the tool (by end user)
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#Drivers' nick-names:
|
#Drivers' nick-names:
|
||||||
#Box|Sph|Cyl|Cut|Fuse|Prism|SecRevol|FulRevol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
#Box|Sph|Cyl|Cut|Fuse|Prism|SecRevol|FulRevol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
||||||
# order of functions recomputation should be defined out of the tool (by end user)
|
# order of functions recomputation should be defined out of the tool (by end user)
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#1 - create Box using short-cut
|
#1 - create Box using short-cut
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D Box; ## add box driver to driver table
|
AddDriver D Box; ## add box driver to driver table
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
AddDriver D Box Cyl Sph Attach XAttach PTxyz PTALine PRLine PMirr Cut Fuse Prism FulRevol SecRevol Fillet
|
||||||
|
|
||||||
#1 Create Box
|
#1 Create Box
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
#1 - create Box using short-cut
|
#1 - create Box using short-cut
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D Box; ## add box driver to driver table
|
AddDriver D Box; ## add box driver to driver table
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#1 - create Box using short-cut
|
#1 - create Box using short-cut
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D Box; ## add box driver to driver table
|
AddDriver D Box; ## add box driver to driver table
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
#Drivers' nick-names:
|
#Drivers' nick-names:
|
||||||
#Box|Sph|Cyl|Cut|Fuse|Prism|SecRevol|FulRevol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
#Box|Sph|Cyl|Cut|Fuse|Prism|SecRevol|FulRevol|PTxyz|PTALine|PRLine|PMirr|Fillet|Attach|XAttach
|
||||||
# order of functions recomputation should be defined out of the tool (by end user)
|
# order of functions recomputation should be defined out of the tool (by end user)
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
#1 - create 4 Pnts
|
#1 - create 4 Pnts
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D PntXYZ PntRLT Line3D Attach;
|
AddDriver D PntXYZ PntRLT Line3D Attach;
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
puts "TODO ?CR23788 ALL: DNaming_SolveFlatFrom: Driver failed"
|
|
||||||
#1 - create 4 Pnts
|
#1 - create 4 Pnts
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D PntXYZ PntRLT Line3D Attach;
|
AddDriver D PntXYZ PntRLT Line3D Attach;
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
#1 - create 4 Pnts
|
#1 - create 4 Pnts
|
||||||
NewCommand D
|
NewCommand D
|
||||||
AddDriver D PntXYZ PntRLT Line3D Attach;
|
AddDriver D PntXYZ PntRLT Line3D Attach;
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# ============= OCAF ============================
|
# ============= OCAF ============================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# ============= OCAF ============================
|
# ============= OCAF ============================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# ============= OCAF ============================
|
# ============= OCAF ============================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# ============= OCAF ============================
|
# ============= OCAF ============================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# ============= OCAF ============================
|
# ============= OCAF ============================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
@ -1,5 +1,3 @@
|
|||||||
puts "TODO ?CR23788 ALL: Failed units"
|
|
||||||
|
|
||||||
# =================== OCAF ======================
|
# =================== OCAF ======================
|
||||||
# Naming
|
# Naming
|
||||||
#
|
#
|
||||||
|
Loading…
x
Reference in New Issue
Block a user