for (; anIter.More(); anIter.Next()) {
if (anIter.Value()->IsKind(STANDARD_TYPE(StepRepr_MappedItem))) {
Handle(StepRepr_MappedItem) anItem = Handle(StepRepr_MappedItem)::DownCast(anIter.Value());
- Handle(StepRepr_Representation) aRepr = anItem->MappingSource()->MappedRepresentation();
- collectViewShapes(theWS, theDoc, aRepr, aShapes);
+ if (Handle(StepRepr_Representation) aRepr = anItem->MappingSource()->MappedRepresentation())
+ {
+ collectViewShapes(theWS, theDoc, aRepr, aShapes);
+ }
}
else if (anIter.Value()->IsKind(STANDARD_TYPE(StepVisual_AnnotationOccurrence)) ||
anIter.Value()->IsKind(STANDARD_TYPE(StepVisual_DraughtingCallout))) {
--- /dev/null
+puts "======="
+puts "0031786: Data Exchange - After the importing STEP file the free shape is empty"
+puts "======="
+puts ""
+
+pload ALL
+
+ReadStep D [locate_data_file bug31786_InternalUseOnly_714-236074-105_NXMBD_A_PNL_SIDE_ENCL_AC_DC_242.stp]
+XGetOneShape result D
+
+vinit
+vdisplay result
+vfit
+
+vdump $imagedir/${casename}.png
\ No newline at end of file