Search code examples
modelingcad

How to structure data for a BIM software?


I'm working on a BIM application for generating wooden structures.

I wrote some lines of code for first tests and trial and before going further I have to make a choice about how to model the data. I wonder what would be the best way to handle beam objects. They are basically long 3D boxes with operations on them like holes of any shapes, mid depth cuts, etc...

There's plenty of ways to model their properties :

Center oriented or corner oriented: Pivot point at the center or on a corner

Work in 3D first : I mean work with vertices and faces, generating the 3D objects, then compute what kind of beam they could fit in and which steps should a CNC machinery take to make them.

Work in CNC mindset : Model beams as section dimension + length, and operations done on them. Then generate their 3D object for screen viewing.

I'm not looking for anyone to do my job and I will find solution by myself anyway. But if someone have any experience working on any existing tools in this field (Revit, Archicad, Woodwork tools) and can provide some feedback of the pro and cons of various methods, that would be great.

Edit : I finally choose to work with abstract guides to organize the parts. Beams always works together along planes. Think of a wall, or evenly distributed beams under floor. So I will create a class for generating and positioning beams along planes. Store beams data as section size + length + joints operations on them. The pivot point being in the middle of one of the shortest edge. This way aligning them on a plane is trivial and it will also hold information about how the wood fiber is oriented inside the beam (core must be placed on top and fibers direction matter). Thanks ArnoE for confirming my choice.


Solution

  • I would look at what you want to actually do with your model when you have it, and work backwards from there. For example, if you know that your architects will frequently change their work, then representing it as triangles/tesselations will probably be a bad idea.

    In general it is easier to transform more abstract representations (e.g. raw box plus destructive operations) into more concrete ones (i.e. the triangles you need for rendering). The more expressive ones would include parametric expressions like gluing faces of boxes together and such... getting complicated though.

    On the other hand, whether you start at the corner or the center is probably a matter of taste, and you will find that you will need both versions once in a while (i.e. you would likely have accessor methods in your classes that transform this stuff on the fly, anyways).

    But apart from that, it is really up to you and your main use cases.