S
by System on 26 Oct 2022, edited 5 Apr 2023
#
This discussion was created from comments split from: <a href="/discussion/201/blenderbim-duplicating-an-ifcgroup-view-collection-and-having-it-show-up-in-the-svg-drawing-list/">BlenderBIM: duplicating an IfcGroup view collection and having it show up in the SVG Drawing list</a>.
C
by Coen on 26 Oct 2022
#
+1 votes
How do you make an IfcGroup?
I modelled a truss with IfcBeamType instances and the BIM tool, it works so insanely fast with the Shift+E and miter tool, so nice:

Now I would like to make this a group and copy paste it along a grid.
T
by theoryshaw on 26 Oct 2022
#
+3 votes
I would assume you'd like to have all these trusses in a 1 to many relationship. That is, if you change one, they all change.
Unfortunately, if all the members(chords) are individual ifcbeamtype instances, there's no way that i know that you can do this.
The following conversations speak to this short coming...
If you want to make them obey a 1 to many relationship, you would have to remove the type assignment to each member(chord), and then join all these meshes into one, and then reassign it to a class like IfcElementAssemblyType, and create the instances.
I know, sad. :)
...
FYI, there is functionality in the schema where the local placement of an object can be tied to a grid or linear element.
But, from what i know, IfcOpenShell doesn't support it yet.
A
by Arv on 23 Nov 2022, edited 23 Nov 2022
#
+3 votes
this is quite a setback in preserving the construction detail and data esp when you have multiple geometries and multiple materials assigned to them :(
I did try with IfcElementAssemblyType
but without any luck.
A
by Arv on 25 Nov 2022
#
+1 votes
@theoryshaw said:
If you want to make them obey a 1 to many relationship, you would have to remove the type assignment to each member(chord), and then join all these meshes into one, and then reassign it to a class like IfcElementAssemblyType, and create the instances.
maybe to make life a bit easier you can use blender python to unlink the ifc elements with a for loop.
bpy.context.selected_objects
and bpy.ops.bim.unlink_object()
remember to select all the objects first and also to import ifcopenshell
G
by Gorgious on 25 Nov 2022, edited 25 Nov 2022
#
+3 votes
Note it's not mandatory to select the objects beforehand, you can use an override :
with bpy.context.temp_override(selected_objects=objects_to_unlink):
bpy.ops.bim.unlink_object()
For anyone wondering, that's the main benefit of using the provided context
and not bpy.context
in an operator execute
.
Link to the operator class
C
by Coen on 8 Dec 2022
#
@theoryshaw said:
I would assume you'd like to have all these trusses in a 1 to many relationship. That is, if you change one, they all change.
Unfortunately, if all the members(chords) are individual ifcbeamtype instances, there's no way that i know that you can do this.
The following conversations speak to this short coming...
If you want to make them obey a 1 to many relationship, you would have to remove the type assignment to each member(chord), and then join all these meshes into one, and then reassign it to a class like IfcElementAssemblyType, and create the instances.
I know, sad. :)
...
FYI, there is functionality in the schema where the local placement of an object can be tied to a grid or linear element.
But, from what i know, IfcOpenShell doesn't support it yet.
Very interesting conversations on Github,, what would be the fastest workflow at the moment for creating a truss?
Model it as one object and use the IFC array modifier? Or am I missing something?
T
by theoryshaw on 8 Dec 2022
#
+1 votes
Model it as one object and use the IFC array modifier? Or am I missing something?
Yes, probably.
From what i can gather, from this conversation here, that IfcRelDefinesByObject would be the way to accomodate a type within a type.
I also wonder, if Type Element Nesting or Type Element Aggregation could be used, somehow, as well.

T
by theoryshaw on 8 Dec 2022, edited 8 Dec 2022
#
+1 votes
@theoryshaw said:
Model it as one object and use the IFC array modifier? Or am I missing something?
Yes, probably.
... but would probably still make them type instances, but don't use IfcMaterialProfileSet in the type definition.
If they are types, they won't have to rely on the IFC array... allows you to have rogue trusses in the project, that are not tied to the array--allowing for a 1:many update, as well.....if that makes sense.
C
by Coen on 7 Feb 2023, edited 7 Feb 2023
#
I think this deserves a bump, are there any updates on the development of this? Is it possible to create an IfcGroup/IfcElementAssembly using the ifcopenshell.api
? Or is there some other hacky way to group IFC elements?
B
by brunopostle on 7 Feb 2023
#
+1 votes
@Coen an ifcelementassembly is just like any other ifcobject that can be an aggregate of other objects. So create one using root.create_entity
, then use aggregate.assign_object
to add other objects to it (implicitly making it an aggregate, and not an ifcproduct with its own representation)
T
by theoryshaw on 7 Feb 2023
#
@brunopostle but is there a way to make a type out of an aggregate? I think that's the hard ceiling in the schema at the moment, as i understand it.
B
by brunopostle on 7 Feb 2023
#
+3 votes
@theoryshaw sometimes life is just a mystery, there are things that are unknowable to the human mind
T
by theoryshaw on 7 Feb 2023
#
haha.. yep. We're just reached that ceiling where no one knows, and someone's just gotta make a decision, and have others adopt it. The nice thing, however, is the problem, and the need, is crystal clear.
B
by brunopostle on 8 Feb 2023
#
Back to the truss example: couldn't this be an ifc type definition with a body representation that consists of lots of sweptsolid extrusions? In principle this would be editable, but the individual members would be just extrusions (with materials, lengths and profiles) rather than distinct ifcmembers.
R
by RaphaëlVouilloz on 8 Feb 2023
#
Great discussion! I need to model these trusses:

I have created IfcMemberTypes, and plane to aggregate the IfcMembers to Empties which I will declare as IfcElementAssemblies. Are you suggesting that I should go for now with four independent IfcElementAssemblies that don't depend on an IfcElementAssemblyType ?
This will be an important topic for stairs too.
C
by Coen on 8 Feb 2023
#
@"RaphaëlVouilloz" said:
Great discussion! I need to model these trusses:

I have created IfcMemberTypes, and plane to aggregate the IfcMembers to Empties which I will declare as IfcElementAssemblies. Are you suggesting that I should go for now with four independent IfcElementAssemblies that don't depend on an IfcElementAssemblyType ?
This will be an important topic for stairs too.
Cool stuff! How did you create the IFC array for those trusses?
B
by brunopostle on 8 Feb 2023, edited 8 Feb 2023
#
+2 votes
@"RaphaëlVouilloz" I think so, you need four element assemblies that coincidentally include the same typed members.
Alternatively you can model the whole truss as a single blender object and create a type out of that. You can give different faces in this object different materials, and blenderbim will produce a separate 'representation item' per material. If you want volume/weight calculations to work later, then ensure that the faces assigned to each material form closed manifolds - a gotcha here is that blenderbim will merge coincident vertices, breaking your manifolds, so move vertices apart that you don't want merged.
The disadvantage of the second approach is that, although you can collect the total volume of each material, you lose the section properties - this is just a mass of timber in a funny shape.
The first approach will retain the section properties, so if you later want to retrieve the length of 38x89CLS in the building it is a straightforward query.
R
by RaphaëlVouilloz on 8 Feb 2023
#
@brunopostle Ok nice, thank a lot for the clarification, I'll go for the first option
@Coen I didn't yet! The screenshot is from Revit. I'm not sure if the IFC Array will work for an aggregate? I'll test and come back
C
by Coen on 8 Feb 2023
#
+1 votes
@RaphaëlVouilloz"
I didn't yet! The screenshot is from Revit. I'm not sure if the IFC Array will work for an aggregate? I'll test and come back
Very curious if this will work. I really hope so.
R
by RaphaëlVouilloz on 21 Feb 2023, edited 21 Feb 2023
#
@Coen said:
@RaphaëlVouilloz"
I didn't yet! The screenshot is from Revit. I'm not sure if the IFC Array will work for an aggregate? I'll test and come back
Very curious if this will work. I really hope so.
Coming back from tests... It seems complicated, since an Empty just doesn't have the Modifiers menu...

Also, in Blender's Outliner you can directly copy a collection and its content. But unfortunately that is not saved in the IFC. Such an evolution would be possible?

The only solution I have now is to duplicate the whole with Shift-D in the 3D Zone, then manually reaggregate each IfcMember of the duplicate to the right IfcElementAssembly.
R
by RaphaëlVouilloz on 21 Feb 2023
#
+4 votes
@brunopostle said:
@"RaphaëlVouilloz" I think so, you need four element assemblies that coincidentally include the same typed members.
Alternatively you can model the whole truss as a single blender object and create a type out of that. You can give different faces in this object different materials, and blenderbim will produce a separate 'representation item' per material. If you want volume/weight calculations to work later, then ensure that the faces assigned to each material form closed manifolds - a gotcha here is that blenderbim will merge coincident vertices, breaking your manifolds, so move vertices apart that you don't want merged.
The disadvantage of the second approach is that, although you can collect the total volume of each material, you lose the section properties - this is just a mass of timber in a funny shape.
The first approach will retain the section properties, so if you later want to retrieve the length of 38x89CLS in the building it is a straightforward query.
But the good news is that I can still create an IfcElementAssemblyType and assign it to the Empty element declared as IfcElementAssembly afterwards. It works :


C
by Coen on 21 Feb 2023
#
@RaphaëlVouilloz
Could you make a tutorial on how you did this please? I'm getting a bit lost.
R
by RaphaëlVouilloz on 21 Feb 2023
#
+1 votes
@Coen
Sure, that's for the next chapter I'm writing for the Villa Le Sextant. I hope to publish it within the week.