SetMaterial in OpenCascade

ThomasSchmid

Looking around for some CAD
Hello!
We're currently working on a way to convert Gerber to Step files. very rudimentery, internal product.
As of right now, we get the Pcb as a TopoDS_Shape, which we than extrude and handle. Color work already. Next task would be to set a Material Lable to out output .stp-file.
Has anyone worked with it before? We get the layer material as a param from a .txt file, for exsample "Copper".

All the best
Thomas
 

Quaoar

Administrator
Staff member
Hello Thomas.

Have you tried using XCAFDoc_MaterialTool to put material layers into an XDE document and export it to STEP? The mechanics should resemble working with the colors quite a bit.
 

ThomasSchmid

Looking around for some CAD
Hey,
This is what i am currently trying to do. Do i need to add every material i need to use beforehand using the material aspect from graphic3d_materialaspect?
Would it make sense for me to use the ambient color from the MaterialTool as my layer color instead of using the ColorTool?

(sorry if my questions are very incoherrant to you, i'm very new to this)
 
Top