29,99 €
For anyone working in the computer graphics industry, understanding how to use Blender’s new geometry nodes tools to manipulate and generate 3D geometry in a node-based workflow is an essential skill. In this book, you’ll learn how to use the basic and intermediate features of geometry nodes that are a crucial part of your Blender roadmap.
You’ll start by understanding the different node inputs and outputs followed by the basic nodes you’ll need throughout your geometry nodes projects. The book will show you how the node system works and enable you to put your newfound knowledge to use through exercises that involve modifying curves, meshes, and more. You’ll work on a range of interesting projects such as creating a procedural plant, where you’ll use nodes to generate the intricate details and variations of a plant in a procedural manner, and a spiderweb generator to refine your skills of cleaning up a node tree. Finally, you’ll build a procedural LED panel using geometry nodes to generate the look of an LED panel.
By the end of this book, you’ll be able to overcome any geometry node issue confidently and make complicated geometry node trees exactly how you need them.
Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:
Veröffentlichungsjahr: 2023
Discover the professional usage of geometry nodes and develop a creative approach to a node-based workflow
Siemen Lens
BIRMINGHAM—MUMBAI
Copyright © 2023 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing or its dealers and distributors, will be held liable for any damages caused or alleged to have been caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
Group Product Manager: Rohit Rajkumar
Publishing Product Manager: Vaideeshwari Muralikrishnan
Senior Content Development Editor: Debolina Acharyya
Technical Editor: Simran Ali
Copy Editor: Safis Editing
Project Coordinator: Sonam Pandey
Proofreader: Safis Editing
Indexer: Hemangini Bari
Production Designer: Arunkumar Govinda Bhat
Marketing Coordinator: Nivedita Pandey
First published: March 2023
Production reference: 1200223
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham
B3 2PB, UK.
ISBN 978-1-80461-255-2
www.packtpub.com
I dedicate this book to my parents, Geertje and Diego, who have always been my guiding light and the foundation of my success. Their unwavering love, support, and belief in me have been the driving force behind my passion for graphic design.
– Siemen Lens
I have had the pleasure of working with Siemen Lens on various visualization projects, from furniture visualization to visualizing biotech installations, where moving elements were also particularly important. So, for both still images and moving images, Siemen has already gained a lot of experience, despite his young age. The skills he displays testify to a high professional level.
What is particularly striking is that Siemen repeatedly manages to have enough information with a small brief to realize a professional rendering. Siemen thinks visually and can effortlessly translate this into a strong way of working out graphics within a parametric environment.
Siemen is always looking for ways that a visualization can be improved, preferably by harnessing the processing power of a platform, and making maximum use of parametric functions and Geometry Nodes. As a result, he achieves the desired visualization faster.
With this book, he shows the thinking frameworks you need to get to a result quickly. Always seen from a practical angle, Siemen takes you into the world of Blender.
Wouter Adriaensen,
Owner of Mercurius 3, a full-service design agency
Siemen Lens is a CG artist who excels at photorealism. He currently studies multimedia in Antwerp. His specialty is creating abstract yet photorealistic renders using Geometry Nodes, physics, texturing, and various other techniques in Blender. He also uses other software such as After Effects, Illustrator, and VEGAS Pro. Siemen has worked as a product render designer in a furniture company. He has also worked at PartydoosMedia, a Dutch digital graphic design agency. His goal is to create visually convincing CG art that is pleasing to the eye. With this book, he aims to get you well versed with Geometry Nodes.
I would like to express my deepest gratitude to all those who have supported me throughout the writing process of this book. I would also like to extend my appreciation to Mihir Roy for recommending me to Packt Publishing.
Maurice Gysin is a student from Switzerland and finishes school this year. He has been using Blender for over a year and made a 3D animation as his graduation project. He is passionate about 3D modeling and creating art with Blender. He loves to explore the capabilities of Blender and create unique and innovative projects. He is eager to push the boundaries of 3D design and continues to learn and grow with the software. He is currently studying and learning new skills to improve his 3D modeling and animation abilities.
Van den Eynden Jeroen is a graphic media student in Antwerp, Belgium.
While he is an aspiring Blender artist, with the help of this book and the great programs covered in it, he started to improve his understanding of the software.
Welcome to Procedural 3D Modeling Using Geometry Nodes in Blender!
This book is designed to provide a comprehensive guide to understanding and utilizing Geometry Nodes in your 3D modeling workflows.
Geometry Nodes are a powerful tool in the world of Blender modeling, allowing for greater flexibility and control over your models. With the ability to create complex shapes, manipulate vertices and faces, and generate intricate patterns, Geometry Nodes can take your 3D modeling skills to the next level.
In this book, we will explore the various types of Geometry Nodes, their functions, and how they can be used to enhance your models. We will also cover advanced techniques such as scripting and animation, providing you with the skills and knowledge necessary to take your 3D modeling career to the next level.
Whether you are a professional 3D artist or just starting out, this book will provide you with the tools and techniques needed to master the art of Geometry Nodes. With the knowledge and skills gained from this book, you will be able to create stunning, highly detailed models with ease and efficiency.
Chapter 1, An Introduction to Geometry Nodes, teaches you about the different node inputs and outputs, how the node system works, and the flow of the node system in Blender.
Chapter 2, Understanding the Functionality of Basic Nodes, covers the basic nodes we will be working with in this book, which include Math nodes, Curve nodes, and Mesh nodes, and their functions, inputs, outputs, and parameters as the building blocks for the rest of the book.
Chapter 3, Must-Have Add-ons for Building Node Trees, explains the various free add-ons available inside Blender and how to download them, along with their functionality and technicality in depth to enhance your node tree-building journey.
Chapter 4, Making Use of Node Primitives, explores the functions of the primitive nodes in Blender, including the Curve primitives and the Mesh primitives.
Chapter 5, Distributing Instances onto a Mesh, teaches you how to apply the skills and techniques learned in previous chapters to distribute points on a plane, and helps you learn about handy nodes, such as the Random value node, to add randomization to your projects.
Chapter 6, Working with the Spreadsheet in Blender, teaches you how to use the Duplicate elements node to duplicate elements procedurally. You will also learn how to work with the Spreadsheet feature.
Chapter 7, Creating and Modifying Text in the Geometry Node Editor, teaches you how to create and modify text in the Geometry Nodes editor.
Chapter 8, Editing Curves with Nodes, explains how to modify curves using noise and thickness nodes and apply the skills in a lightning bolt exercise.
Chapter 9, Manipulating a Mesh Using Geometry Nodes, teaches you how to use Geometry Nodes to manipulate mesh by extruding, subdividing, smoothing, and applying Boolean effects.
Chapter 10, Creating a Procedural Plant Generator, explains how to create a plant generator using custom curves, distribution, and instancing leaves and how to make a pot using Geometry Nodes.
Chapter 11, Creating a Procedural Spiderweb Generator, explains how to create a procedural web generator by making use of the Convex Hull.
Chapter 12, Constructing a Procedural LED Panel, covers how to create a procedural LED panel by creating an array of red, green, and blue pixels and using Named Attributes to link the Material editor to the Geometry Nodes editor.
Chapter 13, Tips and Tricks for the Geometry Nodes Editor, explores various tips and tricks for the Geometry Nodes editor, including techniques for vertex proximity, weight painting, and remeshing to enhance your modeling workflow.
Chapter 14, Troubleshooting the Most Common Problems in Geometry Nodes Editor, covers troubleshooting techniques for Geometry Nodes, including methods for fixing shading, optimizing slow node trees, and addressing common issues.
To get the most out of this book, you will need to have Blender version 3.3 LTS installed. You should possess basic knowledge of basic material nodes, modeling, and viewport control within Blender. This will enable you to follow the instructions and create the desired results from the book. Without these prerequisites, the book may be difficult to understand and follow.
Software/hardware covered in the book
Operating system requirements
Blender 3.3
Windows, macOS, or Linux
To download and view the complete node trees of the relevant chapters, click on this link: https://packt.link/UvynW.
To make it easier for you, we have included all of the node trees we cover in this book as scenes in this blend file (link above).
You can switch these scenes by looking at the top right of your screen, where you see the name of the exercise. If you click this, you'll get the option to select your preferred chapter.
We also provide a PDF file that has color images of the screenshots and diagrams used in this book. You can download it here: https://packt.link/IDhC9
Important
Some of the images might not be clear in the printed book, so it is recommended that you download the graphic bundle.
There are a number of text conventions used throughout this book.
Bold: Indicates a new term, an important word, or words that you see onscreen. For instance, words in menus or dialog boxes appear in bold. Here is an example: “To do this, let’s go to the Layout workspace and press the Tabkey to enter Edit Mode.”
Tips or important notes
Appear like this.
Feedback from our readers is always welcome.
General feedback: If you have questions about any aspect of this book, email us at [email protected] and mention the book title in the subject of your message.
Errata: Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you have found a mistake in this book, we would be grateful if you would report this to us. Please visit www.packtpub.com/support/errata and fill in the form.
Piracy: If you come across any illegal copies of our works in any form on the internet, we would be grateful if you would provide us with the location address or website name. Please contact us at [email protected] with a link to the material.
If you are interested in becoming an author: If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, please visit authors.packtpub.com.
Once you’ve read Procedural 3D Modeling Using Geometry Nodes in Blender, we’d love to hear your thoughts! Please click here to go straight to the Amazon review page for this book and share your feedback.
Your review is important to us and the tech community and will help us make sure we’re delivering excellent quality content.
Thanks for purchasing this book!
Do you like to read on the go but are unable to carry your print books everywhere? Is your e-book purchase not compatible with the device of your choice?
Don’t worry! With every Packt book, you now get a DRM-free PDF version of that book at no cost.
Read anywhere, any place, on any device. Search, copy, and paste code from your favorite technical books directly into your application.
The perks don’t stop there; you can get exclusive access to discounts, newsletters, and great free content in your inbox daily.
Follow these simple steps to get the benefits:
Scan the QR code or visit the following link:https://packt.link/free-ebook/9781804612552
Submit your proof of purchase.That’s it! We’ll email your free PDF and other benefits to you directly.
Welcome to the first part of this book, where we will be introducing you to the world of node-based geometry manipulation in Blender. In this section, you will familiarize yourself with Geometry Nodes and understand the functionalities of basic nodes and must-have add-ons for building node trees.
This section comprises the following chapters:
Chapter 1, An Introduction to Geometry NodesChapter 2, Understanding the Functionalities of Basic NodesChapter 3, Must-Have Add-Ons for Building Node TreesIn this book, you’ll learn how to work with Geometry Nodes. You will find basic and intermediate-level information about Geometry Nodes here. This book will help you learn various topics, such as distributing points, modifying meshes, creating meshes, and covering the basic nodes.
If you are learning any kind of Blender workflow, Geometry Nodes will surely be a handy tool to know about. They open up new possibilities for procedural modeling and animation.
You’ll also get the chance to try your skills with fun exercises throughout this book; these include exercises such as making a procedural plant, a procedural landscape, and a Procedural LED panel.
In this chapter, we’ll talk about the practicality of Geometry Nodes, why they might be useful for you, and some scenarios in which this new tool will be helpful. We will also go over the different node inputs and outputs. Finally, at the end of this chapter, you will learn how to access the Geometry Nodesystem.
In this chapter, we will cover the following topics:
Understanding the Geometry Node systemIn what situations are Geometry Nodes applicable?Understanding the Geometry Node editorThe different node inputs and outputsAnd finally, how to access the Geometry Node editorIn this book, we will use Blender version 3.3, which can be downloaded from this link:https://download.blender.org/release/Blender3.3/
If you do not have certain nodes, then you might have an outdated version of Blender. While newer versions of Blender might work with this book, we cannot guarantee that everything will match the explanations we give. For the best experience, we recommend using Blender 3.3.
To download and view the complete node trees of the relevant chapters, click on this link: https://packt.link/UvynW.
To make it easier for you, we have included all of the node trees we cover in this book as scenes in this blend file (link above). You can switch these scenes by looking at the top right of your screen, where you see the name of the exercise. If you click this, you'll get the option to select your preferred chapter.
The Geometry Node editor is a new feature in Blender 3.0. Over the months, it has evolved into a very useful tool that every CG artist should know. Geometry Nodes is all about procedurally modeling your mesh. This can help with big scenes where you need lots of objects to have variation. For example, if you are making a forest, every tree needs to have a bit of variation; otherwise, the scene will look like a render. To easily add variation to trees, we use Geometry Nodes.
Previously, creators would use hair particles to scatter objects along a mesh. With Geometry Nodes, this is no longer needed. Geometry Nodes will help in scattering all objects just the way you want. There are lots of ways to scatter your objects. We will also go over the various ways to randomize these instances. The idea of Geometry Nodes is to procedurally generate a complex mesh out of a basic and simple input.
Unlike the Material Nodes editor, which does not use a Modifier, the Geometry Node editor is a Modifier that can be applied from the Modifiers tab. This Modifier can be combined with other Modifiers like any other would. The Geometry Nodes Modifier consists of a few parts:
Figure 1.1: The Geometry Nodes Modifier
Part 1 refers to how many times the node tree has been used. If the node tree is only being used by one object, this number will not be there.The button in part 2 allows you to select a node tree out of the different node trees in your project.
Part 3 allows you to link various attributes to this variable. For example, you can link weight paint values with this for a simple stone distribution solution.
The button in part 4 allows you to animate the value of part 5. This can also be done by pressing i on any value field.
Lastly, part 5 defines the current value that is being inputted into the node tree. You can change this value by clicking on it or by holding down your mouse cursor while sliding.
Behind this Modifier lies the Geometry Node system. It consists of various nodes to procedurally model your objects.
Many people think that Geometry Nodes are the new way to model in Blender, and for certain scenarios, this is true. But there are times when you’re better off using the normal modeling workflow.
Geometry Nodes are usually used to procedurally generate multiple objects at once and to scatter objects around on a mesh, for example, scattering grass onto a field, generating roads procedurally, or generating multiple buildings at once.
Geometry Nodes are generally not used to model complex organic structures with lots of features, for example, faces, human figures, clothes, etc.
While it is certainly possible to model these objects via Geometry Nodes, it’s very impractical to do so because the amount of detail in these objects is near impossible to program mathematically using Geometry Nodes. It’s much more practical to model the structures via the normal modeling workflow in Blender.
Now that we’ve got a better understanding of when Geometry Nodes are applicable, we’ll talk about everything you need to know about the Geometry Node editor.
The Geometry Node system makes use of the node tree design in Blender, like the material node editor. Much like the material node editor, the node system flows from left to right. Geometry Nodes can modify and create different types of geometry, such as the following:
MeshesCurvesPoint cloudsVolumesInstancesLet’s take an in-depth look at these terms.
A mesh is a structural build of a 3D model consisting of faces. 3D meshes make use of the three axis points, x, y, and z. A mesh is made up of vertices, which make up edges, which, in turn, make up faces.
A curve is a way to define paths in Blender; this can be used on multiple occasions. For example, if you want a camera to follow a specific path, this can be done with curves. These can also be modified, used, and created in the Geometry Node editor. This will be explained in Chapter 8, Editing Curves with Nodes.
A point cloud is a selection of scattered points around a mesh. These point clouds are only visible in the viewport and not in the render.
A volume is a semi-transparent effect that can also be experimented with in the Geometry Node editor. Volumes are usually used to create abstract effects in the Geometry Node editor but can also be used to create a foggy atmosphere in your scene.
An instance is best explained as a copy of the original mesh. This can be used to copy multiple objects around a mesh, much like we used to do with hair particles. This is mostly used to scatter rocks or grass onto a base mesh.
All of these datatypes will use the same connection type, a Geometry connection. This node connection is green. Let’s have a look at the input and output node connection of the Geometry Node system.
The first node that this book will introduce you to is the Group Input node.
Figure 1.2: Group Input node
The standard Geometry output of this node returns the base mesh of your object before any modifications have been made. This mesh basically returns the mesh you've inputted into the object's Edit mode.
This node is used to add variables to the Geometry Nodes Modifier so that you can have easy access to the most used variables. To create these variables, just slide a value into the unused node socket, and it will automatically occupy the node socket.
At the end of the node tree, you will use a Group Output node.
Figure 1.3: Group Output node
This will define the end of the Modifier. Just like the Group Input node, the Group Output node has an unused node socket to output extra data to the Modifier. This can be used to define UV maps, for example.
Now that we’ve looked into the group input and group output nodes, let’s go over the various node connection inputs and outputs.
Let’s start by explaining the various input and output shapes in the Geometry Node editor.
Let’s take a closer look at the input and output shapes in the Geometry Node editor.
This is what a round input/output node connection looks like:
Figure 1.4: The round input/output node connection
This is a round input/output node connection. This defines a single node value. For example, in geometry nodes, a single node connection can send through multiple values from other locations. With a round connection, this is not the case. This will likely result in the value being rounded to one value or returning an error value.
This is what a squared input/output node connection looks like:
Figure 1.5: The squared input/output node connection
It accepts multivalue fields. This means that every vertex on our mesh will be calculated separately according to the node tree. This feature in Geometry Nodes is very fun to play around with because each point gets its own flow of calculation, which opens up a world of interesting possibilities. An example of this feature is adding noise displacement to your mesh; each vertex will get its own displacement because each vertex is being calculated separately thanks to the square input/output node connection.
Here’s an in-depth look at the different colors in the Geometry Node editor.
This node connection offers Boolean values.
Figure 1.6: The Boolean input/output node connection
This node connection will define either an on or an off value; in other words, this is a value with either a 1 or a 0. As explained previously, this can either be a single value (circle shape) or multiple values (square shape).
This is a vector node connection.
Figure 1.7: The vector input/output node connection
This carries three values combined into one. These values can be separated with a Separate XYZ node. It can also be combined with a Combine XYZ node. The vector node is used to define positions, rotations, scales, and offsets. It can also be used to define UV maps in the material node editor.
This is a geometry node connection.
Figure 1.8: The geometry input/output node connection
This defines geometry and instances. When you slide an object from the outliner into the Geometry Node editor, you will see this connection to add this instance to your Geometry Nodes project. This is also the connection you will see when you generate a point cloud with the Distribute Points on Faces node. This node will also show up on both sides when you use any geometry-modifying node, such as Transform Instance node, Scale Instance node, and any primitive mesh node. All of these nodes will be explained in Chapter 2, Understanding the Functionalities of Basic Nodes.
This is the integer node connection.
Figure 1.9: The integer input/output node connection
This defines or accepts any value that is an integer; some examples of integer values are 0, 1, 2, 3, and 4. These values are basically values without a decimal point. These are usually used to define indexes of certain things, for example, duplicate objects. This node connection can be found on nodes such as the ID node, the Duplicate Elements node, and the Index node.
This is the value node connection, also known as the factor node connection.
Figure 1.10: The value input/output node connection
This defines a plain value. The difference between this and an integer node connection is that the value node connection can contain decimal points. Some examples of nodes containing this node connection are the Noise Texture node and any math node. This value can also make use of multivalue fields, just like the square symbol we previously discussed.
This is a color value.
Figure 1.11: The color input/output node connection
This node connection contains three values, an R channel (red), a G channel (green), and a B channel (blue), also known as the RGB channels. These can be separated into their respective RGB values using a Separate RGB node. They can also be combined using a Combine RGB node. Just like the examples explained in the Exploring different shapes section, this node connection can also make use of multivalue fields.
This node connection defines a string of text.
Figure 1.12: The string input/output node connection
This value will mainly be seen on nodes that are made to create or modify text, such as the String node, the String to Curves node, and the String Length node. This will be explained in depth later on in the book.
This node connection defines a material.
Figure 1.13: The material input/output node connection
It can be used to set the material of selected geometry in the node editor. This node basically refers to a material you’ve already made and one that is included in the project file. Some nodes that make use of this node connection are the Material node, the Set Material node, and the Replace Material node.
Let’s look into some special node connections.
Multi-Connection inputs allow you to connect multiple output connections into one input socket. This is generally used to join multiple datatypes of the same type into one output.
Figure 1.14: Geometry multi-connection input
The node connection seen here is usually used to combine elements; for example, the input shown in the preceding figure is used to join geometry together.
Figure 1.15: String multi-connection input
The preceding socket is used to join strings together. It works in the same way as the geometry multi-connection input.
Now, you’ll learn how to access the handy Geometry Nodes tool in Blender.
Make sure you at least have Blender 3.2, but in this book and chapter, we will be using Blender 3.3. Let’s begin:
Firstly, let’s start by opening Blender.Then, you can head on to the Geometry Nodes tab in the top section of your screen. Now your journey begins.Figure 1.16: Blender startup screen
When you click on the Geometry Nodes tab at the top of your screen, you’ll see the following:
Figure 1.17: Geometry Node editor tab with info overlayed
This might look overwhelming at first sight, but don’t worry, this book will guide you through all the parts of this node editor.
There are four parts you’ll need to know about on this screen:
SpreadsheetThis is a separate window that allows you to see various bits of information about elements of your geometry, such as, for example, the properties of instances.
ViewportThis is your main view in Blender. It allows you to see the project in 3D space.
OutlinerThis is a list of all the objects in your current scene. This makes it easy to create instances by sliding your object from the outliner right into the Geometry Node editor.
Geometry Node editorThe Geometry Nodes editor is your main editing workspace for working with Geometry Node trees.
To start working on Geometry Nodes, it’s important to learn how to add a node tree to your projects. There are two ways to do this:
One way to do this is to add a Geometry Nodes Modifier from the Modifiers tab in the Properties tab:Figure 1.18: Geometry Nodes Modifier
After you’ve added the Modifier to the Modifier stack, you’ll need to press the New button. You’ve now successfully created a new node group.
The other way to do this (and the quicker way since we’re already in the Geometry Nodes workspace) is to just click the New button in the Geometry Node editor. This automatically adds a new Geometry Nodes Modifier along with a beginning and end node. The following figure shows the New button you’ll find at the top of the Geometry Nodes workspace to add a new node tree, along with all the functions of the button.Figure 1.19: Node group selection box
This is the end of the chapter. In this chapter, you’ve learned about the various node connections you will come across in the node editor, along with how to access the node editor.
Congratulations! You now know the basics of the Geometry Node editor.
In this chapter, we’ve covered the various node connections. This includes the Vector, Boolean, Color, Integer, Value, String, Material, and Geometry Inputs, along with the different shapes of node connections. We have explained how to access the Geometry Node editor in various ways, how the node system works, how it flows, and everything there is to know about this new system in Blender. Having read this chapter, you will now understand how this Geometry Node system works and what kinds of node connections are available in the Geometry Node editor.
In the next chapter, we’ll go over the basic nodes you’ll be needing the most in your basic projects. This is important because we will be using these nodes in the coming chapters.
In the last chapter, you learned how to use the Geometry Node system; in this chapter, we will be explaining the building blocks, or nodes of the Geometry Node system.
To get started, we’ll introduce you to the basic nodes that you will be using throughout this book. The basic nodes are the nodes that you will use in most of your projects to perform basic commands, such as combining meshes, converting meshes, instancing points on your mesh, and more. We will also explain what every input, output, and value means with visual examples.
In this chapter, we will cover the following topics:
Exploring Mesh nodesUnderstanding how to manipulate PointsInstance nodesConverter nodesThe basic nodes are the nodes that you will use the most in your Geometry Nodes projects, not only in this book but also when you will start creating Geometry Nodes projects on your own. These nodes perform the basic operations that you will need regularly, such as the Subdivision Surface node, the Join Geometry node, the Extrude Mesh node, and many more nodes that you will need most of the time.
Let’s start by explaining the nodes you’ll need the most, the Mesh nodes. These are used to modify the mesh you are working with. In this chapter, we will go over the most basic nodes you are likely to use with any Geometry Nodes project.
We are all familiar with the Subdivision Surface modifier.
Figure 2.1: Subdivision Surface node
