step-examples/12-3a-shells/Tsh074.stp
Sources
- OCCT method line ShapeFix_Shell.FixFaceOrientation:1440 (FixFaceOrientation_at1428)
Description
aMapAdded tracks duplicate geometry but only warns; duplicate ADVANCED_FACE entities with identical topology are processed independently, resulting in inconsistent outward orientation fixes during shell healing.
Reproducer recipe
Create a CLOSED_SHELL containing two ADVANCED_FACE entities with identical edge loops, vertices, and plane reference. Call ShapeFix_Shell.Perform(). Observe that FixFaceOrientation fixes one face but not the other, leaving inconsistent orientations.
Expected kernel behavior
Kernel should reject duplicate face detection or unify orientation across all geometry instances.
Expected validation
occt=unknown/unknown gmsh=unknown ifc=schema_n/a
Tier-3 assertions
n_faces_total == 2
Live oracle output
No live oracle data — run _run_corpus to populate.
Fixture content
Show fixture bytes
1ISO-10303-21; 2/* Tsh074 - ShapeFix_Shell duplicate-face detection 3 * Defect: aMapAdded tracks duplicate geometry but only warns; duplicate 4 * ADVANCED_FACE entities with identical topology/geometry processed 5 * independently, resulting in inconsistent outward orientation fixes. 6 * Source: ShapeFix_Shell.FixFaceOrientation line 1440 (FixFaceOrientation_at1428). */ 7HEADER; 8FILE_DESCRIPTION(('Tsh074 test case','Duplicate faces in shell'),'2;1'); 9FILE_NAME('Tsh074.stp','2026-06-16T00:00:00',('auto-generated'),(''),'auto-generated','',''); 10FILE_SCHEMA(('AUTOMOTIVE_DESIGN { 1 0 10303 214 3 1 1 }')); 11ENDSEC; 12DATA; 13#1=APPLICATION_CONTEXT('automotive_design'); 14#2=APPLICATION_PROTOCOL_DEFINITION('international standard','automotive_design',2000,#1); 15/* Two square plates: one at z=0, one at z=0 (duplicate geometry) */ 16#100=CARTESIAN_POINT('',(0.0,0.0,0.0)); 17#101=CARTESIAN_POINT('',(1.0,0.0,0.0)); 18#102=CARTESIAN_POINT('',(1.0,1.0,0.0)); 19#103=CARTESIAN_POINT('',(0.0,1.0,0.0)); 20#110=VERTEX_POINT('',#100); #111=VERTEX_POINT('',#101); 21#112=VERTEX_POINT('',#102); #113=VERTEX_POINT('',#103); 22/* Plane and edges for face 1 */ 23#200=DIRECTION('',(0.0,0.0,1.0)); #201=DIRECTION('',(1.0,0.0,0.0)); 24#210=AXIS2_PLACEMENT_3D('',#100,#200,#201); #220=PLANE('',#210); 25#300=DIRECTION('',(1.0,0.0,0.0)); #301=VECTOR('',#300,1.0); 26#302=DIRECTION('',(0.0,1.0,0.0)); #303=VECTOR('',#302,1.0); 27#310=LINE('',#100,#301); #311=EDGE_CURVE('',#110,#111,#310,.T.); 28#312=LINE('',#101,#303); #313=EDGE_CURVE('',#111,#112,#312,.T.); 29#314=LINE('',#103,#301); #315=EDGE_CURVE('',#113,#112,#314,.T.); 30#316=LINE('',#100,#303); #317=EDGE_CURVE('',#110,#113,#316,.T.); 31#400=ORIENTED_EDGE('',*,*,#311,.T.); #401=ORIENTED_EDGE('',*,*,#313,.T.); 32#402=ORIENTED_EDGE('',*,*,#315,.F.); #403=ORIENTED_EDGE('',*,*,#317,.F.); 33#404=EDGE_LOOP('',(#400,#401,#402,#403)); #405=FACE_OUTER_BOUND('',#404,.T.); 34/* Face 1 - outward facing */ 35#406=ADVANCED_FACE('face1',(#405),#220,.T.); 36/* Defect: Face 2 is identical geometry; duplicate detection should warn */ 37#407=ADVANCED_FACE('face1_dup',(#405),#220,.T.); 38#500=CLOSED_SHELL('shell_with_duplicates',(#406,#407)); 39/* PRODUCT chain */ 40#9000=PRODUCT_CONTEXT('',#1,'mechanical'); 41#9001=PRODUCT('Tsh074','Tsh074','',(#9000)); 42#9002=PRODUCT_DEFINITION_FORMATION('','',#9001); 43#9003=PRODUCT_DEFINITION_CONTEXT('part definition',#1,'design'); 44#9004=PRODUCT_DEFINITION('','',#9002,#9003); 45#9005=PRODUCT_DEFINITION_SHAPE('','',#9004); 46#9006=(LENGTH_UNIT()NAMED_UNIT(*)SI_UNIT(.MILLI.,.METRE.)); 47#9007=(NAMED_UNIT(*)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.)); 48#9008=(NAMED_UNIT(*)SI_UNIT($,.STERADIAN.)SOLID_ANGLE_UNIT()); 49#9009=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-7),#9006,'distance_accuracy_value',''); 50#9010=(GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#9009))GLOBAL_UNIT_ASSIGNED_CONTEXT((#9006,#9007,#9008))REPRESENTATION_CONTEXT('','3D')); 51#9021=SHELL_BASED_SURFACE_MODEL('sbsm',(#500)); 52#9022=MANIFOLD_SURFACE_SHAPE_REPRESENTATION('',(#9021),#9010); 53#9023=SHAPE_DEFINITION_REPRESENTATION(#9005,#9022); 54ENDSEC; 55END-ISO-10303-21;