Trouble With BoundingBox.ToCuboid Node

Hi All,

I’m a Dynamo newbie and this is my first post. So go easy :grinning:

I’m trying to fill in 3 parameters in Revit geometry for length width and height.

I successfully created a routine that did what I wanted on small sample selection in my model.

However I have yet to be able to replicate my initial success.

Having tried to run the routine on the whole model, other small sections or just one category the routine seems to fail on the BoundingBox.ToCuboid node. Returning Null for all elements.

This is the results when working

This is when not

Thanks in advance.

Grayham

Hello, but why are you using the bounding box instead of the basic elements parameters ?

Fair question.

I’m filling out parameters for NominalWidth/Length/Height for COBie placeholders.

My model geometry doesn’t have consistent parameter names to pull values from. So I was getting the bounding box size of each object to use the L,W&H dimensions to push back into parameters.

Or can I get the L,W&H values another way?

I have had better success with selecting elements rather than using elements in the active view. But I am still getting a lot of Null values.

Thanks

Remove the elements with a null bounding box as a first step. An “is null” node will create the Boolean and allow for a filter. Get a second bounding box after that and wire the rest of the graph into that.

1 Like

Hi @Roperg,

A little warning for rotated elements.
A boundingbox is always aligned to the x and y axis.
So when your element is rotated for example 45 degrees, the boundingbox will be larger to let your element fit.
The cuboid (and your parameters) will also be larger than your element.
In the link below i created a workaround workflow for that.

https://forum.dynamobim.com/t/create-cuboid-as-element-outline/12440/8?u=mjb-online

For the rest i agree with @jacob.small, first get rid of the null values.
I hope it can be of help,
Mark

1 Like

Thanks for sharing indeed :slight_smile:
A screenshot would also be nice for those who don’t download external files…

Here is the screenshot as @Yna_Db suggested (can’t add to the original topic anymore).

  1. It turns Revit elements into Dynamo solids
  2. If the angle is not 0, 90, 180, 270 or 360 degrees, it wil rotate the (dynamo)solid.
  3. Create a fitting boundingbox.
  4. Turn the boundingbox into a cuboid.
  5. rotate the cuboid back to it’s original ratation.

In my case i used the cuboids to create sectionviews.

Kind regards,
Mark

3 Likes

Thanks all, I will take a look at the suggestions