Rectangle Rain Grasshopper pattern: short vertical slots scattered through a solid panel

Rectangle Rain

Random slot perforation

Short vertical slots scattered at random through a solid panel, like streaks of rain. A simple perforation pattern for screens and cladding.

Want all 53 patterns? Get them in one zip →


Price

Free

Plugins

None, native components only

Works with

Rhino 7 & 8, Mac and Windows

Level

Beginner

Inputs

Reference in Rhino

Surface

The surface the pattern is built on. The slots run in its V direction. It must be a planar (flat) surface.

Main Sliders

SliderWhat it changesDefault
Columns
Rows
The number of cells across and along the surface. Columns sets the width of the slots, Rows sets the shortest slot length.60
35
Removed %The share of cells in each column that are left solid, picked at random. Higher values give fewer, shorter slots.38

Also try: change the True/False pattern that feeds Dispatch from False, True to False, False, True. The slots then sit in every third column, with wider solid strips between them.

Notes

  • The edges stay solid. The script skips the first and last column and the first and last cell of every column, so the surface keeps a closed border.
  • Slots are one cell wide and never touch sideways. Only every second column gets slots. Neighbouring open cells in a column merge into one longer slot.
  • Removed % runs from long slots to none. At 0 every slotted column becomes one long slot; at 100 every cell is left solid and the surface has no slots at all.

Design Logic

How the script builds the pattern, step by step.

Rectangle Rain Grasshopper script on the canvas
The whole script on the Grasshopper canvas. Open full size ↗
StepHow the script does it
1. Split the surface into cellsDivide Domain² and Isotrim cut the surface into a grid of small rectangles, Columns across and Rows along. Partition List groups them into columns.
2. Keep every second columnTree Statistics lists the columns and Cull Index drops the first and last. Dispatch with a False/True pattern picks every second one, and Tree Branch pulls out those columns.
3. Leave out cells at randomCull Index drops the top and bottom cell of each column. List Length and an Expression work out how many cells make Removed %, and Random Reduce removes that many at random, with a different seed per column from Random.
4. Merge the cells into slotsA Curve parameter turns the remaining cells into their outlines, and Region Union joins touching outlines in each column into one longer slot.
5. Cut the slots out of the surfaceA second Curve parameter turns your surface into its outline. Boundary Surfaces takes that outline and the slot outlines together and makes one flat surface with the slots as holes.

Want to learn how to build scripts like this on your own? Check out the Grasshopper Pro course.

On this page

Related tutorial

Free to use, also commercially

Use and change this script in your own projects, personal or commercial.

Please don't re-upload or redistribute the file. If you share it, link to this page so people always get the latest version.

© Hopific

Something not working?

If a script throws an error or doesn't do what this page describes, tell me and I'll fix it.

Tell me →