FamilyInstance from Geometry in the same place of geometry

Hi again guys. I had this code that worked well on revit 2021, but with 2022 everything has stopped working. I had to create a generic model from an imported DWG. I used Spirn Nodes FamilyInstance.ByGeometry, it works, but the scale of the instance is wrong. I don’t know why this it happens, the family template is set in millimeters and so my project. The same thing happens with FamilyType.ByGeometry and with FamilyInstance.ByPoint, the scale is wrong and i don’t know how to get the solid origin point to place the instance family in the exact place where the solid is. The solid is an extrusion from DWG and it is of the correct shape. When i create the family everything blows up, i don’t know if it is the template for the generic model of Revit 2022. The same procedure worked well with revit 2021, but i can’t simply re download it since i can’t open my current model on it.

Revit 2022 changed the way units are handled, so scaling is off with this node. Best to pre-scale the geometry as needed before making the family instance, or use the out of the box family type by geometry node followed by the family instance by point node.

1 Like

Thank you, but the geometry generated is in the rigth place and with the right dimension (is the orange one in the pictures) Is the node FamilyType.ByGeometry which changes the scale (the instance is 3.3 times bigger). I have to scale the family type before placing the instance?

So, since i’m working with metric system and Revit units are imperial, inside the node FamilyType.ByGeometry he read the units of the geometry (metric) as if they were imperial?

No - he reads the geometry with the old method of importing geometry via the API, but the new one has additional variables which need to be taken into account.

While your geometry may be right in Dynamo, that’s a temporary state (nothing in a DYN persists after you close Dynamo), so scaling it up by whatever need be prior to sending to Revit to get the right results should solve the issue where it matters (the Revit file where you want the family instance).

1 Like

Hi,
Did you get any further in solving your problem of the scaled geometry? Im having the same issue here.
If you have any suggestion how to solve it I would like to hear.

Wouter Hilhorst

Hello @wouter.hilhorst …this one here should work in 2022 as springs does in previus versions…give it a try.

2 Likes

Thanks a lot!

1 Like

Hey, @sovitek I have been looking for this for ages. Thanks a lot!

1 Like

Also take a look at my solution here using Spring nodes.

2 Likes

Hello @sovitek,

So I tried using this node that you recommended, it created according to its geometry; however, there is an issue:

I’m trying to create solids for each rooms, therefore I plugged in the room geometries into the node, and also create a list for the room name and its department- for each of the room solids. The node however generated solids for the whole building multiple times according to the list of names I created instead of generating single blocks of the room.

Would you know how to solve it?

Hi @larismanis try something here…i assume you are in 2022…

not sure could you show an image with your browser with family data and your graph with all nodes expanded…be sure the lacing in the synthezise node is set to shortest…and input geometry in @L3…i know a really crazy node :wink:

Thank you! @sovitek It worked as expected :smiley:

I have a further issue with overriding the color of the blocks and getting them from the color scheme.

My script seems fine, but the colors haven’t changed.
Here’s my script attached below
Room2Volume.dyn (69.2 KB)

You are welcome :wink: … but please create a new topic with that…lets close it here