Louver Placement and Design v1

 



Criteria for Louver Placement: Select a Face, then extract and select the NurbsCurve using [Surface.PerimeterCurves]. 
Extract the length using [Curve.Length] to extract points that can be placed at 500mm intervals. Use the [Curve.PointAtSegmentLength] node. The interval can be changed later with an input value.  
Create a rectangle assuming the NurbsCurve is flattened. 


Connecting the NurbsCurve's length to the input of [Rectangle.ByWidthLength] allows the length value to change automatically when the shape is modified later. 
Explode the rectangle into Lines using [Geometry.Explode], then select the shorter Lines. Using [Curve.Length] as the input for [List.SortByFunction], the 0 and 1 indices will be the shorter lines, and the 2 and 3 indices will be the longer lines. Selecting the two shorter lines is possible by inputting 2 into [List.TakeItems]. 
Select the longer lines using [List.TakeItems] with an input of -2, then input them into [Curve.PointAtParameter] to extract points at regular intervals. 
After checking the number of 500mm interval points on the original NurbsCurve, place points on the longer lines of the rectangle at the same intervals. 
Since each line has a different directionality, sort the point list using [List.Reverse] before creating lines. 

Create a reference line to generate a new curve that changes for curved louver placement. 

The curve can be changed according to the variation of a [Number Slider]. Set the [Number Slider] as an Input to check it as a variable in Generative Design. 


Extract the intersection points of the newly created and changing curve and the existing placement lines using [Geometry.Intersect] to extract the point Y values. This part can be changed depending on the shape, height, and direction of the generated rectangle. Since the Y values show + and - values, add the midpoint of the height, 7000, to change them to + values. 
The Sum of the extracted values is the sum of the length values of the part used in the design, so set it as OUTPUT. Connect it to a [Gate] node because this length needs to be entered into a Revit Family parameter. 



Separate the points and the louver length using the [Gate] node, then place the family using [FamilyInstance.ByPointAndLevel] and input the louver length value using [Element.SetParameterByName].

Generative Design connection possible.


댓글

이 블로그의 인기 게시물

Geometry test 0506 stair and routing

Structural Analysis Workflow with Dynamo and Robot