0023384: Translate sub-shape names between XDE document and STEP

Sub-shapes naming translation between XDE and STEP implemented as an optional mode of Reader/Writer.
New static variables are now available: write.stepcaf.subshapes.name for Writer and read.stepcaf.subshapes.name for Reader (both have 0 values by default).
XOpen command implemented in scope of XDEDRAW asset.

Added test case bugs xde CR23384
This commit is contained in:
apn
2012-09-07 13:03:39 +04:00
committed by ssv
parent 9fe1ada847
commit 02a0b964f2
6 changed files with 459 additions and 7 deletions

View File

@@ -53,7 +53,10 @@ uses
ShapeTool from XCAFDoc,
Label from TDF,
LabelSequence from TDF,
HSequenceOfTransient from TColStd
HSequenceOfTransient from TColStd,
RepresentationItem from StepRepr,
TransientProcess from Transfer,
ConnectedFaceSet from StepShape
is
@@ -204,6 +207,51 @@ is
---Purpose: Reads materials for instances defined in the STEP model and
-- set reference between shape instances from different assemblyes
SettleShapeData(me; theItem: RepresentationItem from StepRepr;
theLab: out Label from TDF;
theShapeTool: ShapeTool from XCAFDoc;
theTP: TransientProcess from Transfer)
returns Label from TDF is protected;
--- Purpose: Populates the sub-Label of the passed TDF Label with shape
-- data associated with the given STEP Representation Item,
-- including naming and topological information.
ExpandSubShapes(me; theShapeTool: ShapeTool from XCAFDoc;
theShapeLabelMap: DataMapOfShapeLabel from XCAFDoc;
theShapePDMap: DataMapOfShapePD from STEPCAFControl)
is protected;
--- Purpose: Given the maps of already translated shapes, this method
-- expands their correspondent Labels in XDE Document so that
-- to have a dedicated sub-Label for each sub-shape coming
-- with associated name in its STEP Representation Item.
ExpandManifoldSolidBrep(me; theLab: out Label from TDF;
theItem: RepresentationItem from StepRepr;
theTP: TransientProcess from Transfer;
theShapeTool: ShapeTool from XCAFDoc)
is protected;
--- Purpose: Expands the topological structure of Manifold Solid BRep
-- STEP entity to OCAF sub-tree. Entities having no names
-- associated via their Representation Items are skipped.
ExpandSBSM(me; theLab: out Label from TDF;
theItem: RepresentationItem from StepRepr;
theTP: TransientProcess from Transfer;
theShapeTool: ShapeTool from XCAFDoc)
is protected;
--- Purpose: Expands the topological structure of Shell-Based Surface
-- Model STEP entity to OCAF sub-tree. Entities having no names
-- associated via their Representation Items are skipped.
ExpandShell(me; theShell: ConnectedFaceSet from StepShape;
theLab: out Label from TDF;
theTP: TransientProcess from Transfer;
theShapeTool: ShapeTool from XCAFDoc)
is protected;
--- Purpose: Expands STEP Shell structure to OCAF sub-tree. Entities
-- having no names associated via their Representation Items
-- are skipped.
FindInstance (myclass; NAUO: NextAssemblyUsageOccurrence from StepRepr;
STool: ShapeTool from XCAFDoc;
Tool: Tool from STEPConstruct;