If you're reading this, we've just migrated servers! If anything looks broken please email dion@thinkmoult.com :)

JoinCriteria on a drawing?

Anyone know what 'JoinCriteria' does on a drawing? and how to use it?

Comments

  • edited May 2023

    Nevermind... i think I pieced the answer together from below.
    That is, if no JoinCriteria is given, it defaults to join/unjoin the following things ["class", "material.Name", 'r"Pset.*Common"."Status"']
    If you want to join/unjoin just material.Name, for example, set JoinCriteria value to: material.Name
    At least that how I think it works...
    This is very cool, btw. :)

    https://github.com/IfcOpenShell/IfcOpenShell/blob/c7e288466f9693482b6210f1c23c8defb8bb7874/src/blenderbim/blenderbim/bim/module/drawing/operator.py#L826

    GorgiousAce
  • Correct, with the default setting, objects with the same class, material name, and status are joined. If any of those three differ, they are not joined.

  • Can I ask if I understand correctly the joincriteria (and metadata)?

    I have a model with only one type of wall (ex. WAL100). I have assigned a material to them (ex. brick). Some of these walls have an "EXISTING" Status, others "NEW" and others "DEMOLISH" (in the PSet_WallCommon property set on each wall object). I have defined different strokes and pattern fills in the default.css for each of them, for example:

    [class*="PsetCommonStatus-DEMOLISH"] { fill: url(#demolish); stroke: rgb(165, 162, 1); stroke-width: 0.2; }

    In the EPset_Drawing properties of the camera. I have defined /Pset_.*Common/.Status in the metadata. If I correctly understand the joincriteria, if I do not set anything for the joincriteria, the walls should be separately grouped by status. But the svg output is this (one "g" tag as example):

    <g class="2N1PZapnH0beiSO3MZ$S11 PsetCommonStatus-EXISTING PsetCommonStatus-DEMOLISH 24deEZcYXDxRc6rAX9B4dj cut IfcWall material-brick"><path d="M25.4,12.0 L24.9,12.0 L24.9,30.0 L25.4,30.0 Z"/></g>

    The "EXISTING" wall (24deEZcYXDxRc6rAX9B4dj) and the "DEMOLISH" one (2N1PZapnH0beiSO3MZ$S11) are still grouped togheter. Is it because they have the same material or are the same wall class? Having this group, I cannot assign a specific class to a single object (or a group of DEMOLISHED objects whitout affecting the EXISTING ones).

    Is it possible to generate a single svg drawing that groups togheter all the "EXISTING", all the "NEW" and all the "DEMOLISH" as separate <g> groups with the respective object paths, in order to apply different classes to the cut polygon? In Italy the building permit procedure requires to display on a single plan all the demolitions (in yellow) and the new constructions (in red).

    I have also some ifcColumns and they are correctly separated. They have an ID tag (for ex. id="product-984facbd-ca1f-4631-b809-d52a284aa5fe-body") and they are inside different tags with the correct PsetCommonStatus-DEMOLISH class. But walls do not have ID tags (at least in my model).

    Am I missing something? Thanks!
    I am using the 230902 version of blenderbim (Blender 3.6.4).

  • If I correctly understand the joincriteria, if I do not set anything for the joincriteria, the walls should be separately grouped by status. But the svg output is this (one "g" tag as example):

    That didn't work because it was using the old way of selecting.

    The following commit, I changed the default JoinCriteria to accommodate the new way of selecting.
    https://github.com/IfcOpenShell/IfcOpenShell/commit/973e4f00641700b6bdef34c5f17b366985f57dbd

    Also know there is a more global way of applying status through the EPset_Status.Status pset... you no longer have to deal with Pset_WallCommon, Pset_WindowCommon...blah, blah, blah. ;)

  • Oh, that was fast! Thank you!
    Now it works with 'EPset_Status.Status' setting in both metadata and JoinCriteria fields. The walls are now separate paths.
    That is a big feature for the laws requesting these kind of drawings. :)

Sign In or Register to comment.