Shape Type of Compounds with All Geometry Children

As you can see on screenshot and step file in zip archive, Wood Top is a sub-assembly with only solid/geometry based children.
If I try to get its type name with TopoDS_Shape::ShapeType(), it says COMPOUND

But using these two return false.

bool bHasChild = TDF_Label::HasChild();
TDF_LabelSequence Children_Counter;
this->Assembly->GetComponents(Referred_Label, Children_Counter, false);
bool bHasChild = Children_Counter.Length() > 0;

I need to differentiate between a sub-assembly with actually zero children and with only geometry based children.
Is there any suggestion for that ?
Shouldn't ShapeType() return COMPSOLID ?

Attachments: 
gkv311 n's picture

TopAbs_COMPSOLID means 'Composite Solid', not 'Compound of Solids'. Within composite solid, solids should share common faces where they touch each other. But if we'll take a look at 'Wood Top' within your model, we'll see no shared faces.

pload OCAF XDE VISUALIZATION
ReadStep D test_1.step
XGetShape s D 0:1:1:1:1
whatis s
# s is a shape COMPOUND FORWARD Modified
explode s
# s_1 s_2 s_3 s_4
whatis s_1
# s_1 is a shape SOLID FORWARD Modified
vdisplay s_1 s_2 s_3 s_4 -dispMode 1
vfit
vaspects s_1 s_2 s_3 s_4 -faceBoundaries 1
verase s_2 s_3 s_4

You may see that the main solid doesn't share common faces/wires with other solids in compound.

wood_top compound wood_top main solid

Eray Ozer's picture

So, how can I differentiate wood top like object and a sub-assembly which doesn't have a child with C++ ? I am working on Unreal Engine 5 wrapper and I need to know that when should I create scene component or static mesh component