What in the world is a ‘Brep’? We’ve all been there: Grasshopper’s terminology can be confusing. Grasshopper can greatly enhance a designer’s workflow, but it can also be intimidating for those who are not familiar with its terminology.
This blog post aims to help make sense of the terms that are used in Grasshopper that either don’t exist in Rhino or that are called differently there. It is aimed for beginners as well as people who are familiar with Grasshopper but are confused about certain words and terms. Let’s get started!
Here are the terms explained in this post:
- Brep
- NURBS
- Boundary surface
- Region operations
- Solid operations
- Shatter
- Boolean Operators
- Domains
- Cull Pattern
- List
- Data Tree
- Data matching
Geometry terminology
Grasshopper uses different kinds of geometry types for the shapes and forms that make up a model. Understanding the differences is essential to know which commands we can run on which geometry. While most terms are the same as in Rhino, some commands go by a different name in Grasshopper.
Brep
Brep is short for Boundary Representation. In Grasshopper, a Brep in Grasshopper is what Rhino calls a Polysurface. It is a geometry type that represents the surface of an object with a set of connected surfaces. Just like Polysurfaces, a Brep can be open, or closed. If we want to reference a closed volume from Rhino to a Grasshopper container, we have to use the ‘Brep’ container. A surface container will not allow the reference a polysurface from Rhino. A Brep container on the other hand can references both single surfaces and polysurfaces.
If you want to be able to reference a variety of geometries, you can use the ‘Geometry’ container, which takes any type of geometry, from points to Polysurfaces.
NURBS
If you are using Rhino, you are most likely already familiar with the term NURBS (non-uniform rational B-spline). NURBS is a mathematical representation of 3D geometry that Rhino uses to create smooth surfaces. It is at the core of Rhino and it differs from Mesh-modeling, which is a type of 3D modelling that is made up of a series of connected points, or vertices. NURBS models are mathematically accurate, meaning that we can define perfectly smooth surfaces, as opposed to meshes which will be facetted at a certain resolution. Rhino and Grasshopper allow us to create NURBS curves as well as NURBS surfaces.
Boundary Surface
Time and time again we’ll want to turn a closed, planar curve into a surface, both in Rhino and in Grasshopper. In Rhino, we would use the ‘PlanarSrf’ command to do that. In Grasshopper the command goes by a different name: it is called ‘Boundary Surface‘. You can use it to turn one or multiple closed curves into a surface. If some of the closed curves are within another closed curve, this command will create a perforated surface. All interior curves will be assumed to be openings in the curve containing them.
Tip: This component will not maintain the List structure of the input curves. For example if you have a list of closed curves and you run them through the Boundary Surface component, the resulting surfaces will not be in the same order. If you want to retain the order, Graft the curves at the input.
Region Operations
If you want to subtract one closed curve from another in Rhino, you can use the ‘CurveBoolean’ command. It will allow you to click into the overlapping or intersecting regions of a set of selected curves, and output that outline as a separate curve.
In Grasshopper, we can do the same with Region components. Instead of a single command as in Rhino, in Grasshopper we get three separate components for different use cases: Region Union, Region Difference and Region Intersection. These commands work just like Boolean Operations in Rhino, just with curves.
Keep in mind that all the curves need to be closed and on the same plane for these components to work.
Solid Operations
If you want to subtract one closed polysurface from another in Rhino, you run a Boolean Difference operation. In Grasshopper, we can use the same commands, but the components are called differently: instead of Boolean operations, they are called Solid operations. Type the following name into the component search bar to add them to your scripts:
- Boolean Union -> Solid Union
- Boolean Difference -> Solid Difference
- Boolean Intersection -> Solid Intersection
In Grasshopper, just like in Rhino, solid operations require two closed Brep in order to work.
Tip: Use these components with caution, as they are very computation heavy. Avoid processing multiple objects at once, if possible.
Shatter
In Rhino, we can split any curve by selecting the curve to split and the geometry to split it with. In Grasshopper, the process is a bit different. There is no ‘Split Curve’ component. Instead, splitting a curve works as follows:
- Find the intersection point between the curve and another object (curve, point, surface or polysurface/brep)
- Extract the curve parameter at the intersection point
- Use the Shatter component to ‘shatter’ or split the curve at that specific point.
Consequently, the ‘Shatter’ component is a crucial component to know, and the fact that it has a different name entirely, is not making our lives easier!
Splitting surfaces on the other hand, has a dedicated component called ‘Split Surface’.
Understanding the terms used to describe these shapes and commands is important for effectively creating Grasshopper scripts. Familiarize yourself with these terms and you’ll always know what component to look for to get the job done!
Logic and Math terminology
Besides terms that refer to geometry types and geometric operations, there are many logic and math-related components in Grasshopper. Understanding what they mean and what they do will open new possibilities within your scripts. Here are some of most powerful yet also most confusing terms:
Boolean Operators
Although they sound the same, Boolean operators have nothing to do with Boolean Unions or Differences. Boolean operators, also called logical operators, are a set of components that allow us to check whether data meets certain conditions or not. The input for these components are always Boolean values, which is to say a True or False value, or a 0 or a 1.
Here are the most common logical operators and what they do:
OR – the OR component has two Boolean value inputs. If one OR the other is True, the output will be True.
NOT – the NOT component will invert whatever Boolean value it receives as input.
AND – the AND component will return True only if both provided inputs are True.
You can use these components to select objects in a list that meet certain conditions. Once you have a list of True or False values, you can process a list with the ‘Cull Pattern’ component.
Domains
A domain is a special numerical data type in Grasshopper. It is made of a pair of numbers that describe the minimum and maximum value, thereby defining a range. We can use number ranges for a variety of things in Grasshopper, for example to extract a sub-section of a curve by specifying a curve parameter range to extract.
Domains come in multiple forms:
1-dimensional, meaning they have a single minimum and maximum value.
2-dimensional, in which case they have tow pairs of minimum and maximum values. Two-dimensional domains can be used to describe a subset of a surface by specifying an evaluation range in both the U and V direction.
There are multiple ways to interact with domains. We can create them from scratch with two values, divide them, and deconstruct them.
Cull Pattern
The Cull Pattern is one of the most powerful components in Grasshopper. It’s an essential tool to select objects in a collection that meet certain conditions. Here is how it works:
It takes a list of data in the first input and a second list of True or False values in the second input.
The component will then apply the True or False pattern to the first list, keeping elements if the Boolean is True, and deleting them if it is False.
Here is an example:
Let’s say you generated a field of curves of a random length. Now you only want to keep the curves that have a certain minimum length. To do that, you can get the length of each curve, and then use a simple expression component that tests whether the length value is bigger or smaller than the value you specify. The output will be a list of True or False values. You can then use this output and feed it into the Cull Pattern component. The output will only contain the curves that are longer than the value you specified.
Data management terms
Mastering the data management terminology in Grasshopper is essential for effectively working with the software. It can be a little overwhelming to start with, but with practice, it becomes more intuitive. Here are the essential terms to know:
List
The list is most basic building block all the data management within Grasshopper is built on. Every programming environment uses lists, as they are an essential but extremely effective way of storing information. In Grasshopper a list is just what you would imagine: a list of values that are stored in a one-dimensional table, just like data in a column in Google Sheets or Excel.
Every item in a list has a specific position in that list, which is described by a number, called the ‘index’. We can select and delete items by using their index.
We can manipulate lists in a variety of ways: we can reverse the list, shift the list by a specified amount, get a subset from a list and so on. You can find all the List-components in a dedicated component tab. Take a look and see what’s possible!
Data Tree
Sometimes a list is not enough to describe data. As soon as we are dealing with many groups of objects at once, we are dealing with lists of lists. That’s where Data Trees come in.
A Data tree is a hierarchical structure that organizes data in Grasshopper. It is used to manage data flow between components, keeping track of which data is connected to which component. Grasshopper’s data management system uses the metaphor of a tree to explain how data is stored in a database. Just like in a tree, all branches are attached to the tree trunk, which in data management terms means that they share the same origin. Grafting on the other hand, means that a new sub-branch is created for each data item.
Data Matching
Data matching is the process of coordinating the data structure from two separate sources to make sure that a component processes the right two (or several) elements together.
Visual examples and diagrams can be helpful in understanding these data management concepts, so try to include some in your study material. Additionally, it is important to keep in mind that practice makes perfect, so don’t be afraid to experiment and try different things to get a better understanding of how these basic elements work together.
In summary, managing data is crucial in Grasshopper, as it ensures that the correct data is flowing through the correct components. Understanding the terms used to describe data management will help you effectively work with the software. Always keep track of the data you are working with, and you’ll be in full control.
Final thoughts
In conclusion, Grasshopper has many terms and commands that are different from Rhino, but once you understand them, it can greatly enhance your design workflow. Now that you know what a Brep is in Grasshopper, how to split a curve in Grasshopper and how to find the counterparts of Rhino commands in Grasshopper, nothing can stop you!
If you are an architect and you would like to get a complete training for Grasshopper, check out our Grasshopper Pro online course. This zero-to-hero course not only teaches you Grasshopper, but also all the core algorithms used in the leading architecture offices!
So go ahead, dive into the exciting world of Grasshopper and discover all the amazing things you can do with it!