mirror of
https://github.com/Open-Cascade-SAS/OCCT.git
synced 2026-05-15 05:28:47 +08:00
Protect Expand compounds against problems with located subshapes. Add method XCAFDoc_ShapeTool::AddSubShape() with Boolean output parameter. Speed up XCAFDoc_ShapeTool::Expand(). Speed up XCAFDoc_ShapeTool::FindSubShape().
28 lines
721 B
Plaintext
28 lines
721 B
Plaintext
puts "============================================================================"
|
|
puts "0030779: Data Exchange - Problems with located subshapes in expand compounds"
|
|
puts "============================================================================"
|
|
puts ""
|
|
|
|
pload DCAF
|
|
|
|
XOpen [locate_data_file bug30779.xbf] D
|
|
XExpand D 1
|
|
|
|
# check model structure after expand
|
|
set result [XGetTopLevelShapes D]
|
|
if {$result != "0:1:1:1 0:1:1:2 0:1:1:3 "} {
|
|
puts "Error: wrong result of Expand compounds."
|
|
}
|
|
|
|
# check colors of subshapes
|
|
for {set i 1} {$i <= 4} {incr i} {
|
|
set sublabel 0:1:1:3:$i
|
|
set color [XGetShapeColor D $sublabel]
|
|
if {$color != "GRAY"} {
|
|
puts "Error: wrong color after expand compounds."
|
|
}
|
|
}
|
|
|
|
Close D
|
|
|