This commit is contained in:
Andrej730
2025-01-15 18:41:13 +05:00
parent 65c99c57cd
commit 2fdcb41c4e
2 changed files with 4 additions and 3 deletions
+3 -1
View File
@@ -829,7 +829,9 @@ class BIMRoofProperties(PropertyGroup):
soft_max=to_percentage(radians(60.0)),
)
roof_thickness: bpy.props.FloatProperty(name="Roof Thickness", default=0.1, subtype="DISTANCE")
rafter_edge_angle: bpy.props.FloatProperty(name="Rafter Edge Angle", min=0, max=pi / 2, default=pi / 2, subtype="ANGLE")
rafter_edge_angle: bpy.props.FloatProperty(
name="Rafter Edge Angle", min=0, max=pi / 2, default=pi / 2, subtype="ANGLE"
)
def get_general_kwargs(self, generation_method=None, convert_to_project_units=False):
if generation_method is None:
+1 -2
View File
@@ -198,11 +198,10 @@ def generate_hipped_roof_bmesh(
new_edges = [bm.edges.new([new_verts[vi] for vi in edge]) for edge in edges]
new_faces = [bm.faces.new([new_verts[vi] for vi in face]) for face in faces]
if mode == "HEIGHT": # Calculate the angle we ended up with.
if mode == "HEIGHT": # Calculate the angle we ended up with.
new_faces[0].normal_update()
angle = new_faces[0].normal.angle(Vector((0, 0, 1)))
# bpypolyskel performs a straight skeleton with equal weights. Ideally, we
# need support for weighted straight skeletons (CGAL has this function) to
# calculate skeletons of varying angles. Doing anything else, such as