Hi, I am trying to convert an IFC file into a step file, but I also need not lose the information about the material. In particular, while converting I need to create elements with different colors corresponding to element with different material. Do you have any hints? Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Tbh I think this is a fairly difficult undertaking.
Good news is that we have access to the ifcopenshell serializers from python as ifcopenshell.geom.serializers, bad news is that STP and IGS have never been added there (because of lack of interest probably)
But even then, it would allows for some control over what is being serialized, but not to the extent that you can tweak colors.
What I'd suggest is reading the OCCT guide [0] wrt to their step writer (that's what we use for the serializer) and see if you can influence the required behaviour. Then see if you want to approach that from C++ or Python.
Hi, I am trying to convert an IFC file into a step file, but I also need not lose the information about the material. In particular, while converting I need to create elements with different colors corresponding to element with different material. Do you have any hints? Thanks.
Tbh I think this is a fairly difficult undertaking.
Good news is that we have access to the ifcopenshell serializers from python as
ifcopenshell.geom.serializers
, bad news is that STP and IGS have never been added there (because of lack of interest probably)But even then, it would allows for some control over what is being serialized, but not to the extent that you can tweak colors.
What I'd suggest is reading the OCCT guide [0] wrt to their step writer (that's what we use for the serializer) and see if you can influence the required behaviour. Then see if you want to approach that from C++ or Python.
[0] https://dev.opencascade.org/doc/overview/html/occt_user_guides__step.html#occt_step_3