Fri, 06/09/2023 - 21:17
Forums:
Hello everyone.
I want to be able to use Python to read a .STP file, exported by solidworks as STEP 242 using MBD.
In the read file, I want to be able to find the edges that I mark in the SW as weldments. By looking at the ASCII of the .STP file I can see this line:
#69=TESSELLATED_SHELL('Weld Bead1',(#57,#58,#59,#60,#61,#62,#63,#64,#65,#66,#67,#68),$);
But I'm not sure how to start, and how to interpret this.
If anyone is able to help me I appreciate it.
Thanks.
Mon, 06/12/2023 - 14:29
Hello,
Unfortunatelly, I don't know pythonOCC functionality.
But you can make a look into this topic how to get the id of entity in STEP file? - Forum Open Cascade Technology
To get some samples how to iterate model tree, extract and down cast each entity.
Best regards, Dmitrii.
Mon, 06/12/2023 - 14:44
Thanks for the reply.
I'm not very familiar with C++, but I'll give it a try.
But as far as I understand, the post you mention is similar to what I want. I want to get the entities in #69=TESSELLATED_SHELL('Weld Bead1',(#57,#58,#59,#60,#61,#62,#63,#64,#65,#66,#67,#68),$);
Is there something similar in python?
Mon, 06/12/2023 - 14:48
pythonOCC is the almost identical with c++. It is a wrapper.
So, yes. Is is possible by c++ and in the same way it should be possible by pythonOCC
Mon, 06/12/2023 - 14:55
If you find some post similar using python, please let me know.
Thanks a lot for your time.
Wed, 06/14/2023 - 11:07
Hi @Dmitrii Pasukhin
I think this gives more or less what you mention. But now I have
but I'm not sure what to do with it...
From the step file, id #30 is:
#30=TESSELLATED_SHELL('Weld Bead1',(#27,#28,#29),$);
How to extract the information?
Go ahead and use c++ terms, I'll be able to adapt.
Thanks in advance.
Tue, 04/23/2024 - 13:14
Hi @Jorge Fernandes
Did you solve the problem? I have the same question , could you tell me how to solve it .