Commit Graph

9459 Commits

Author SHA1 Message Date
Dion Moult b07f7bcc58 get_footprint_area now unions 2D polygons to prevent double counting 2024-04-16 11:05:23 +02:00
Dion Moult cdc3f70ff4 Fix #3939. Bug where IfcLabel data type was incorrectly used for longer text data. 2024-04-16 11:05:23 +02:00
Ryan Schultz e641120166 Updated default JoinCriteria to accommodate new facet selector for statuses. 2024-04-16 11:05:23 +02:00
Andrej730 371c54036d test creating mep transition 2024-04-16 11:05:23 +02:00
Andrej730 1647acf0ca ifc2x3 pset library - fix bunch of unit related vlaidation errors #3929 2024-04-16 11:05:23 +02:00
Dion Moult 682990a30d Minor fixes 2024-04-16 11:05:23 +02:00
Dion Moult 11eefab4fc Add support for latest uniclass and add Uniclass July 2023 2024-04-16 11:05:23 +02:00
Sigma Dimensions (Yass) aa0d1cc230 fix displaying undefined or userdefined units in cost schedules 2024-04-16 11:05:23 +02:00
Sigma Dimensions (Yass) c18d756e74 fix displaying cost item totals 2024-04-16 11:05:23 +02:00
Massimo Fabbro b111d85830 New operator that creates a ceiling from cursor position in covering tool 2024-04-16 11:05:23 +02:00
Andrej730 056e0b050d fixed core tests after switch_representation changes 2024-04-16 11:05:23 +02:00
Andrej730 e09a57a9d3 "Edit Profile" in BIM Tool for mapped representations
basically now "edit profile" will be shown in BIM Tool UI and will work from shift+e hotkey if the active element's representation is mapped (for example, if it has openings)
2024-04-16 11:05:23 +02:00
Andrej730 746053eefb switch_representation to automatically switch to unresolved mapped representation
The cool thing about it now that it will automatically create a new mesh for "unresolved" representation if element has openings, otherwise it'll stick to the same mesh representation as the type object.

This fixed a few bugs:
- similar to b9a9abd but during extrusion profile edit
- applying void to the occurence used to remove the type and other occurences. Apparently it occured after 744c08e - previously we seems to rely on `ifcopenshell.geom.create_shape(settings, element)` to unresolve the representations. Though before 744c08e there still was an issue - it would apply the same opening to the all occurences and the type meshes but wasn't removing them.

Probably fixed a few other similar issues.
2024-04-16 11:05:23 +02:00
Andrej730 79b8125916 switch_representation not to break with temporary mesh representations
I've found a bug that if you have some object that consists of extrusion and can be edited in profile edit mode, when you finish editing, it would remove the type object (and I guess the other occurences objects).

It happened because during edit mode it's using temporary mesh data and `switch_representation` would replace this temp mesh data with new representation and remove the old mesh data that might still used by the other occurences and the type.

The issue also was leading to a crash during `box.template_icon(icon_value=AuthoringData.data["type_thumbnail"], scale=5)` if you had BIM Tool thumbnail preview opened in the process - removing type object would make thumbnail icon become invalid leading to the crash.

Crash mentioned here: https://community.osarch.org/discussion/1753/bbim-two-door-types-with-connected-properties
2024-04-16 11:05:22 +02:00
Dion Moult f30ceae7da Update beginners tutorial documentation with images from new UI. 2024-04-16 11:04:29 +02:00
Dion Moult f9236f8b42 You can now assign and unassign styles to materials 2024-04-16 11:04:29 +02:00
Dion Moult ca1925cc9f You can now specify a name when adding materials 2024-04-16 11:04:29 +02:00
Ryan Schultz acb29b5275 Additional clarification on save and save as 2024-04-16 11:04:29 +02:00
Dion Moult 13446cf6db Reorganise new stakeholders panel, move profiles into geometry tab. General UI polish. 2024-04-16 11:04:29 +02:00
Andrej730 fb650a8516 option to set active system
Now it's possible to set in UI active system (currently it's done "select" button next to the system).

Also changed the elements that are going to be decorated with system decorator. Previously it was decorating all the mep elements in the projects which was very performance heavy on large projects.
2024-04-16 11:04:29 +02:00
Andrej730 424042474b Merge systems UI into one
We had two very similar systems panels that were part of the old UI.
2024-04-16 11:04:29 +02:00
Dion Moult 5bb04010ae Fix #3095. Very basic implementation of a new zones panel. 2024-04-16 11:04:29 +02:00
Andrej730 91c7fe4628 Fixed tests after selector syntax update 2024-04-16 11:04:29 +02:00
Dion Moult c5e5f4ab6a Fix #3901. Add configurable list concatenation support in IfcFM. 2024-04-16 11:04:29 +02:00
Dion Moult eff68dda38 Fix #3903. Bug where stairs started off with an empty mesh and had a representation added, resulting in an invalid empty point cloud.
Now stairs have should_add_representation=False when creating the IfcStairFlight, and the representation is updated explicitly, similar to how parametric doors and windows etc have their representations updated.
2024-04-16 11:04:29 +02:00
Dion Moult afd3ac1881 Fix regression from 744c08e where type products cannot have an instance specified in create_shape 2024-04-16 11:04:29 +02:00
Dion Moult b5253556a9 Adding / editing shading / rendering styles in the style manager now updates Blender materials 2024-04-16 11:04:29 +02:00
Andrej730 bc9fc0b462 Forgot to fix test after 35d66f5 2024-04-16 11:04:29 +02:00
Andrej730 5d051b5bdd Fixed issue unlinking mesh objects
After d67eae5 delete_ifc_object is removing the meshes and it end up invalidating the unlinked object. Now mesh is copied before running delete_ifc_object
2024-04-16 11:04:29 +02:00
Andrej730 64f1ea9034 Fix tests after 808ff54 2024-04-16 11:04:29 +02:00
Andrej730 a5e667230d Minor fix after a47c57c 2024-04-16 11:04:29 +02:00
Andrej730 6297afa04c Fixed test after c34a9c5
Also fixed bug in the sheeter
2024-04-16 11:04:29 +02:00
Andrej730 219a5bbcf7 Fixed test after 418444a 2024-04-16 11:04:29 +02:00
Andrej730 ab39983d26 Fixed test after 90b40ff 2024-04-16 11:04:29 +02:00
Andrej730 52d67052bd Fixed test after 88d96f7 2024-04-16 11:04:29 +02:00
Andrej730 834bde2b63 Fixed test after 6e9639446 2024-04-16 11:04:29 +02:00
Andrej730 ec97b04bde Fixed #3907 after dd7a6a80e 2024-04-16 11:04:29 +02:00
Dion Moult 9c99085413 You can now edit rendering styles in the style manager 2024-04-16 11:04:28 +02:00
Andrej730 526dbd9e44 Added IfcZone to systems UI in IFC2X3 #3905
In IFC2X3 IfcZone is a subtype of IfcGroup but not subtype of IfcSystem (it become one after IFC4), therefore IfcZone wasn't presented anywhere in BBIM UI.
It's a bit confusing though to include IfcZone in systems when it's not actually a IfcSystem but having it in IfcGroups would be confusing too.
2024-04-16 11:04:28 +02:00
Andrej730 a43fd7f066 Fixed #3901
It was throwing an error because was failing to write a list to an excel cell, now it's explicitly converting the value to string.

Python: Traceback (most recent call last):
  File "\blenderbim\bim\module\fm\operator.py", line 102, in execute
    writer.write_xlsx(filepath)
  File "\blenderbim\libs\site\packages\ifcfm\__init__.py", line 259, in write_xlsx
    cell = worksheet.cell(row=r, column=c, value=col)
  File "\blenderbim\libs\site\packages\openpyxl\worksheet\worksheet.py", line 247, in cell
    cell.value = value
  File "\blenderbim\libs\site\packages\openpyxl\cell\cell.py", line 218, in value
    self._bind_value(value)
  File "\blenderbim\libs\site\packages\openpyxl\cell\cell.py", line 187, in _bind_value
    raise ValueError("Cannot convert {0!r} to Excel".format(value))
ValueError: Cannot convert ['USE TYPE CATALOG'] to Excel
2024-04-16 11:04:28 +02:00
Andrej730 c8e9acce8c ifcfm symlink to dev environment setup script 2024-04-16 11:04:28 +02:00
Andrej730 ea2120aa00 bim.switch_representation to switch to exact representation
previously it was switching to the first representation that matches the context, so it wasn't possible to switch to the second one if you had more than 1 representation in the same context

using always both element and representation in `geometry.import_representation` so it will import the exact representation and not the first one found by `ifcopenshell.geom.create_shape`
2024-04-16 11:04:28 +02:00
Andrej730 915a892479 activate_drawing to prioritize already active representation
If there are multiple representations in the same subcontext, when it was searching for the representation for some specific subcontext, it would previously always switch to the first representation from the list, now it's going to prioritize the one that's already active.
2024-04-16 11:04:28 +02:00
Andrej730 b83732a92e bim.create_all_shapes info message 2024-04-16 11:04:28 +02:00
Andrej730 0a309e191d Bump build version to fix #3889 2024-04-16 11:04:28 +02:00
Andrej730 1c142a34bc Some UI to mark booleans as manual #3709
Currently it allows only to either set all object's booleans to be marked as manual or all of them marked as automatic, can't change some specific boolean.

Short demo - https://imgur.com/a/bczv35N
2024-04-16 11:04:28 +02:00
Andrej730 6a7f8f65c7 move to tools methods for working with manual booleans #3709
Also fixed a bug adding boolean when pset is already added and representation type in add_boolean

```
  File "\addons\blenderbim\tool\ifc.py", line 201, in execute
    IfcStore.execute_ifc_operator(self, context)
  File "\addons\blenderbim\bim\ifc.py", line 336, in execute_ifc_operator
    result = getattr(operator, "_execute")(context)
  File "\addons\blenderbim\bim\module\model\opening.py", line 534, in _execute
    data = json.loads(pset["Data"])
  File "\addons\blenderbim\libs\site\packages\ifcopenshell\entity_instance.py", line 248, in __getitem__
    if key < 0 or key >= len(self):
TypeError: '<' not supported between instances of 'str' and 'int'
```
2024-04-16 11:04:28 +02:00
Andrej730 3c49dd15f7 localize mathutils dependency in tests #3895
replaced shapebuilder with general ifcopenshell code in `test_add_boolean` (the only place besides `test_shape_builder` where it was used), that way mathutils dependency in tests is localized only to `test_shape_builder.py`.

added test-safe option to makefile, so github workflow would ignore `test_shape_builder` tests for now and it wouldn't interrupt the entire workflow
2024-04-16 11:04:28 +02:00
Andrej730 df745345d5 refresh_aggregate to show time it took
since this can get very time consuming on large projects
2024-04-16 11:04:28 +02:00
Andrej730 cef9ba6001 Fix poll error after 3de9915
The error was
Traceback (most recent call last):
  File "\blenderbim\bim\module\model\covering.py", line 64, in poll
    return element.is_a("IfcCovering")
AttributeError: 'NoneType' object has no attribute 'is_a'
2024-04-16 11:04:28 +02:00