Rotate Section Boxes?

Is there a way to rotate Section Boxes in 3D Views using Dynamo?

Hi,

Use the View CropBox node to retrieve the section box and the Element SetRotation node of the Genius Loci package.

2 Likes

Thanks for the suggestions. I could not find “View CropBox” node. Thence, got the element a different way. I am currently stuck.


ple, not having a Location property:
image

It does have a Bounding Box with a transform:

The Python Script from the Genius Loci node:

Hi,

Please considers the use of an up-to-date package.

1 Like

Yes, the 2020 version of Genius Loci didn’t do that. I got it to work by getting those 2 DYNs from its Github. Should I have just installed the whole latest package, despite the warning, even though it is for Revit 2020?

This works:


It doesn’t seem to rotate the Section Box around its center, though:

elif ElementId(BuiltInCategory.OST_SectionBox) == element.Category.Id:
				box = doc.GetElement(ElementId(element.Id.IntegerValue + 1)).GetSectionBox()
				loca = (box.Min+box.Max)/2
				rot = 0

Submit suggestion to its Github if true?

The Genius Loci package has been updated with Revit 2021 but works from Revit 2017 to Revit 2022 so you can ignore the Dynamo version warning and update the full package.

Indeed, the transform of the bounding box must be used before calculating the centroid.

Always useful to remember the different improvements when you have accumulated more than 300 custom nodes.

2 Likes

Issue submitted.


He fixed it last July. Just updating here for posterity. :grinning:

3 Likes