CN-122020790-A - Dynamo-based revit terrain and family one-key alignment method
Abstract
The invention discloses a Revit terrain and family one-key alignment method based on Dynamo, which relates to the technical field of constructional engineering design, realizes one-key alignment of any family model with complex and uneven terrains in Revit by running Dynamo program, solves the problem that original Revit cannot perform one-key alignment on uneven terrains in batches, and can control the up-and-down offset distance of the family model on the surface of the terrains through distance data input in Number nodes without manually adjusting and aligning a large Number of family models one by one, and is convenient and efficient to operate.
Inventors
- JIANG HAILONG
- YIN HONGYUAN
- HE CONG
- WU LINYU
- HAN XINKAI
- JIA BAOYING
- ZHU WEIZHI
- WANG KEHUI
Assignees
- 中建八局浙江建设有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20260127
Claims (5)
- 1. A revit terrain and family one-key alignment method based on Dynamo is characterized by comprising the following steps: step 1, creating a topography in revit, placing a plurality of family models above the topography, and opening Dynamo a management interface of revit; Step 2, obtaining the primitive positions of all the group models placed in the step 1 through Dynamo; step 3, converting the created form in the step 1 into a grid body, and acquiring all index points in the grid body; step 4, connecting Dynamo mesh.Facendaces nodes with the group of index points; step 5, obtaining the point of each triangular surface in the grid body through Dynamo; Step 6, connecting Dynamo three List. GetletemAtlndex nodes with LIST CREATE nodes, combining all triangular surface points into a list, connecting LIST CREATE nodes with List. Transose nodes, and combining three points in each triangular surface into a group; Step 7, connecting LIST CREATE nodes of Dynamo with surface. ByPerimerPoints nodes for operation, connecting surface. ByPerimerPoints nodes with Polysurface. ByOanedSurfaces nodes, and combining all the combinations in the step 6 into an integral surface; step 8, connecting Dynamo element. GetLocation nodes with geometry. Transfer nodes, and dotting the group model downwards; Step 9, connecting Dynamo vector.ZAxis nodes with vector.reverse nodes, and connecting vector.ZAxis nodes with geometry.translate nodes; Step 10, inputting the downward dotting distance of the group model in a Number node Dynamo, and connecting the vector. ZAxis node and the Number node with a geometry. Transfer node; step 11, connecting Dynamo geometry/transfer node to line/ByStartPointEndPoint node, and connecting Dynamo element/GetLocation node to line/ByStartPointEndPoint node; Step 12, connecting Dynamo line ByStartPointEndPoint nodes with geometry nodes, and connecting Polysurface ByOnnedSurfaces nodes with geometry nodes to obtain the intersecting part of each line of the grid body and the terrain; Step 13, connecting Dynamo geometry/intersect node to List/Flatten node, leveling the List/Flatten node, connecting line/ByStartPointEndPoint node to List/Flatten node, and connecting line/ByStartPointEndPoint node to element/GetLocationnode in step 11; Step 14, connecting Dynamo line. ByStartPointEndPoint nodes with Curve. Length nodes to obtain lengths from each group of models to the terrain; Step 15, writing the elevation in elevation of the attribute of the family model in a String node Dynamo, adopting a Number node and a Code Block node to control the on-line and up-down offset of the family model, inputting an 'a+b' in the Code Block node Dynamo, and connecting the Curve. Length node and the Number node of Dynamo with the Code Block node; Step 16, connecting Select Model Elements node Dynamo with ElementSetParameterByName node, code Block node ElementSetParameterByName node, string node ElementSetParameterByName node, and controlling the shift of the group model on the surface of the terrain by the distance data in Number node.
- 2. The method for one-touch alignment of revit terrain and family based on Dynamo as claimed in claim 1, wherein said step 2 comprises the sub-steps of: step 21, acquiring all the group models placed in the step 1 by adopting Select Model Elements nodes of Dynamo; And 22, acquiring the primitive position of the group model acquired in the step 21 by adopting Dynamo element.
- 3. The method for one-touch alignment of revit terrain and family based on Dynamo as claimed in claim 1, wherein said step 3 comprises the sub-steps of: step 31, adopting Dynamo's Select Model Elements node to select the topography created in step 1; Step 32, connecting Select Model Elements nodes of Dynamo with Topograph mesh nodes, and converting the topography into a grid body capable of performing point and line intersection calculation, wherein each grid unit of the grid body is a triangular surface formed by three index points; Step 33, connecting Dynamo Topograph nodes with mesh nodes, extracting groups of index points, and respectively marking three index points of all grid units as IndexGroup.A, indexGroup.B and IndexGroup.C; And step 34, connecting the Topograph node with the mesh node to obtain all index points.
- 4. The method for one-touch alignment of revit terrain and family based on Dynamo as claimed in claim 1, wherein said step 5 comprises the sub-steps of: step 51, creating three List.GetletemAtlndex nodes in Dynamo, and connecting the mesh.Vertex positions nodes with the three List.GetletemAtlndex nodes respectively; and 52, respectively connecting the IndexGroup.A, indexGroup.B and IndexGroup.C nodes with three List.GetletemAtlndex nodes to obtain the points forming each triangular surface.
- 5. The method according to claim 1, wherein in the step 10, each distance data input through the Number node does not exceed a distance between the corresponding family model and the topography.
Description
Dynamo-based revit terrain and family one-key alignment method Technical Field The invention relates to the technical field of constructional engineering design, in particular to a revit terrain and group one-key alignment method based on Dynamo. Background When using revit software to design a building engineering structure, a family model is often required to be placed on a complex and uneven terrain, and the elevation of the family model needs to be adjusted one by one due to the fluctuation of the terrain. For example, in a landscape model, a large number of tree families (i.e., family models) need to be placed over uneven terrain, and the tree families need to be adjusted one-to-one to align with the terrain. At present, a large number of family models cannot be aligned with uneven terrains at a time in revit, manual alignment adjustment is needed to be carried out on each family model, and the manual alignment adjustment needs to consume a large amount of time and is low in efficiency. Therefore, it is desirable to provide a revit terrain-to-family one-key alignment method based on Dynamo, which can solve the problem that a large number of family models cannot be aligned with high-low undulating terrain at one time in the prior art revit. Disclosure of Invention The invention aims to provide a revit terrain and family one-key alignment method based on Dynamo, which can solve the problem that a large number of family models cannot be aligned with high-low fluctuation terrains at one time in the prior art revit. The invention is realized in the following way: a Dynamo-based revit terrain-to-family one-key alignment method comprising the steps of: step 1, creating a topography in revit, placing a plurality of family models above the topography, and opening Dynamo a management interface of revit; Step 2, obtaining the primitive positions of all the group models placed in the step 1 through Dynamo; step 3, converting the created form in the step 1 into a grid body, and acquiring all index points in the grid body; step 4, connecting Dynamo mesh.Facendaces nodes with the group of index points; step 5, obtaining the point of each triangular surface in the grid body through Dynamo; Step 6, connecting Dynamo three List. GetletemAtlndex nodes with LIST CREATE nodes, combining all triangular surface points into a list, connecting LIST CREATE nodes with List. Transose nodes, and combining three points in each triangular surface into a group; Step 7, connecting LIST CREATE nodes of Dynamo with surface. ByPerimerPoints nodes for operation, connecting surface. ByPerimerPoints nodes with Polysurface. ByOanedSurfaces nodes, and combining all the combinations in the step 6 into an integral surface; step 8, connecting Dynamo element. GetLocation nodes with geometry. Transfer nodes, and dotting the group model downwards; Step 9, connecting Dynamo vector.ZAxis nodes with vector.reverse nodes, and connecting vector.ZAxis nodes with geometry.translate nodes; Step 10, inputting the downward dotting distance of the group model in a Number node Dynamo, and connecting the vector. ZAxis node and the Number node with a geometry. Transfer node; step 11, connecting Dynamo geometry/transfer node to line/ByStartPointEndPoint node, and connecting Dynamo element/GetLocation node to line/ByStartPointEndPoint node; Step 12, connecting Dynamo line ByStartPointEndPoint nodes with geometry nodes, and connecting Polysurface ByOnnedSurfaces nodes with geometry nodes to obtain the intersecting part of each line of the grid body and the terrain; Step 13, connecting Dynamo geometry/intersect node to List/Flatten node, leveling the List/Flatten node, connecting line/ByStartPointEndPoint node to List/Flatten node, and connecting line/ByStartPointEndPoint node to element/GetLocationnode in step 11; Step 14, connecting Dynamo line. ByStartPointEndPoint nodes with Curve. Length nodes to obtain lengths from each group of models to the terrain; Step 15, writing the elevation in elevation of the attribute of the family model in a String node Dynamo, adopting a Number node and a Code Block node to control the on-line and up-down offset of the family model, inputting an 'a+b' in the Code Block node Dynamo, and connecting the Curve. Length node and the Number node of Dynamo with the Code Block node; Step 16, connecting Select Model Elements node Dynamo with ElementSetParameterByName node, code Block node ElementSetParameterByName node, string node ElementSetParameterByName node, and controlling the shift of the group model on the surface of the terrain by the distance data in Number node. The step 2 comprises the following sub-steps: step 21, acquiring all the group models placed in the step 1 by adopting Select Model Elements nodes of Dynamo; And 22, acquiring the primitive position of the group model acquired in the step 21 by adopting Dynamo element. The step 3 comprises the following sub-steps: step 31, adopting Dynamo's Select Model Elements node to se