Houdini 101: Your First Steps in Procedural FX | Shahzad Ahmad | Skillshare
Search

Playback Speed


1.0x


  • 0.5x
  • 0.75x
  • 1x (Normal)
  • 1.25x
  • 1.5x
  • 1.75x
  • 2x

Houdini 101: Your First Steps in Procedural FX

teacher avatar Shahzad Ahmad, Houdini FX Artist

Watch this class and thousands more

Get unlimited access to every class
Taught by industry leaders & working professionals
Topics include illustration, design, photography, and more

Watch this class and thousands more

Get unlimited access to every class
Taught by industry leaders & working professionals
Topics include illustration, design, photography, and more

Lessons in This Class

    • 1.

      Course Trailer

      2:41

    • 2.

      02 Download Project Files

      0:20

    • 3.

      03 Get Started With UI

      16:04

    • 4.

      04 Overview Of Houdini Contexts

      11:37

    • 5.

      05 Import Geometry

      8:07

    • 6.

      06 Assign Textures

      17:58

    • 7.

      07 Materials And Rendering

      20:38

    • 8.

      08 Geometry Grouping

      22:36

    • 9.

      09 Geometry Attributes

      21:38

    • 10.

      10 Attribute Based Extrusion

      15:44

    • 11.

      11 Attributes Transfer

      13:52

    • 12.

      12 Copying Geometry

      16:49

    • 13.

      13 Copying Multiple Geometry

      24:24

    • 14.

      14 Packed Primitives

      11:51

    • 15.

      15 Copies Orientation

      19:51

    • 16.

      16 Scatter And Align

      22:55

    • 17.

      17 Intro to VEX And VOPS

      21:06

    • 18.

      18 When To Use VEX Over VOP

      26:14

    • 19.

      19 Parameters And Channels

      18:52

    • 20.

      20 Remap Values In VOPs

      17:44

    • 21.

      21 Remap And Ramps

      24:08

    • 22.

      22 Ramps In VEX

      10:25

    • 23.

      23 Volumes And Voxels

      19:33

    • 24.

      24 Houdini Volumes Vs VDB Volumes

      22:57

    • 25.

      25 SDF Volume Vs Fog Volume

      22:58

    • 26.

      26 Clouds Creation Workflow

      24:34

    • 27.

      27 Smoke Simulation

      23:52

    • 28.

      28 Pyro Solver

      20:40

    • 29.

      29 Fire Simulation

      22:28

    • 30.

      30 Pyro Solver Forces

      25:06

    • 31.

      31 Writing Simulation Cache

      18:58

    • 32.

      32 Rendering Smoke

      20:40

    • 33.

      33 Pyro Burst Source

      24:07

    • 34.

      34 Explosion Simulation

      20:10

    • 35.

      35 Rendering Explosion

      18:41

    • 36.

      36 Rendering In ACES

      14:45

    • 37.

      37 Intro To POP Solver

      23:02

    • 38.

      38 Particles Forces

      23:43

    • 39.

      39 POP Axis Force

      20:38

    • 40.

      40 POP Curve Force

      14:11

    • 41.

      41 POP Curve Incompressible Flow

      8:20

    • 42.

      42 POP Custom Velocity Field

      12:25

    • 43.

      43 Custom Curve Force

      23:03

    • 44.

      44 Particles Advection

      15:06

    • 45.

      45 Rendering Particles

      22:44

    • 46.

      46 POP Grains Introduction

      21:30

    • 47.

      47 Dry Sand Wet Sand

      22:07

    • 48.

      48 Activating Grains

      15:05

    • 49.

      49 Collision Based Activation

      15:21

    • 50.

      50 Rendering Grains

      5:51

    • 51.

      51 Grains Soft Body

      18:58

    • 52.

      52 RBD Dynamics Introduction

      23:44

    • 53.

      53 RBD Bullet Sop Solver

      23:25

    • 54.

      54 Animated Vs Deforming

      20:46

    • 55.

      55 Fracturing Geometry

      17:47

    • 56.

      56 RBD Constraints

      22:18

    • 57.

      57 RBD Activation

      17:37

    • 58.

      58 Vellum Basics

      18:15

    • 59.

      59 Vellum Soft Body

      19:45

    • 60.

      60 Vellum Constraints

      24:39

    • 61.

      61 Vellum Hair

      16:05

    • 62.

      62 Vellum Grains

      22:25

    • 63.

      63 Flip Fluids Simulation

      12:45

    • 64.

      64 Particle Fluid Tank

      16:36

    • 65.

      65 Flip SOP Solver

      13:23

    • 66.

      66 Writing Cache And Meshing

      15:49

  • --
  • Beginner level
  • Intermediate level
  • Advanced level
  • All levels

Community Generated

The level is determined by a majority opinion of students who have reviewed this class. The teacher's recommendation is shown until at least 5 student responses are collected.

13

Students

--

Projects

About This Class

We will start this course of from very basics how to navigate in the scene around and then we will take a brief tour of Houdini all of different contexts what they are and why they are here and in the process we will build entire scene from importing geometry assigning materials lighting and rendering our scene.

Once we have established our foundation then we will take a deep dive into the Houdini SOP context and in here we will take a look at different geometry grouping techniques geometry attributes transferring the attributes driving extrusion from attributes.

And then we will take a look at copying and instancing how to orient instance geometry instance attributes copying multiple geometry.

And then we will learn about VEX and VOPs and how to work with VOPs and then we will take a look at writing vex code and we will learn about different data types and how to create parameters and channels.

And then we will learn about working with volumes in Houdini how to create procedural skyscape and hero clouds working with smoke solver and pyro solver for creating smoke, fire, and explosion simulations rendering fire and explosions working with ACES and rendering with ACES Color space.

And then we will dive into particles how to create particle simulation working with particle forces creating our own particle forces. And then we will take a look at POP Grains for creating sand and snow simulation.

And then we will learn about Houdini RBD Bullet solver for creating rigid body simulation, creating destruction simulation, fracturing the geometry.

And then we learn about vellum solver for creating soft body simulation. And we will finish this course off with flip fluids how to create both large and small scale fluid simulations. We will learn about flip viscosity to create viscous fluids. We will learn how to import geometry in Solaris for rendering and we will learn about Karma XPU for rendering.

Some key topics we’ll cover include:

Introduction & Basics

  • Navigating the scene

  • Overview of Houdini contexts

Building a Scene

  • Importing geometry

  • Assigning materials

  • Lighting and rendering

Houdini SOP Context

  • Geometry grouping techniques

  • Geometry attributes & transferring

  • Driving extrusion from attributes

Copying & Instancing

  • Orienting instance geometry

  • Instance attributes

  • Copying multiple geometries

VEX & VOPs

  • Working with VOPs

  • Writing VEX code

  • Understanding data types, parameters, and channels

Volumes & Simulations

  • Creating procedural skyscape & hero clouds

  • Smoke & pyro solver for fire/explosion simulations

  • Rendering with ACES color space

Particles & POP Grains

  • Particle simulation & forces

  • Creating sand and snow simulations

Rigid Body Dynamics (RBD) & Vellum Solver

  • Bullet solver for rigid body/destruction simulations

  • Fracturing geometry

  • Soft body simulations with Vellum

Flip Fluids & Rendering

  • Large and small-scale fluid simulations

  • Flip viscosity for viscous fluids

  • Importing geometry in Solaris for rendering

  • Rendering with Karma XPU

Meet Your Teacher

Teacher Profile Image

Shahzad Ahmad

Houdini FX Artist

Teacher

Hello, my name is Shahzad Ahmad. I am a Houdini FX Artist. I am passionate about creating the Visual Effects (explosions, smokes, fire, clouds, dust, particles, magic, etc.), as well as all kinds of destruction and fluids. I am a self-taught Artist. And i love watching science documentaries and Sci-Fi movies!

See full profile

Level: Beginner

Class Ratings

Expectations Met?
    Exceeded!
  • 0%
  • Yes
  • 0%
  • Somewhat
  • 0%
  • Not really
  • 0%

Why Join Skillshare?

Take award-winning Skillshare Original Classes

Each class has short lessons, hands-on projects

Your membership supports Skillshare teachers

Learn From Anywhere

Take classes on the go with the Skillshare app. Stream or download to watch on the plane, the subway, or wherever you learn best.

Transcripts

1. Course Trailer: Hello, and welcome to you all guys. My name is Shahab Amer, and I will be your instructor throughout this course. We will start this course off from very basics, how to navigate in the scene around, and then we'll take a brief tour of Hulini all of different contexts, what they are, and why they are here, and in the process, we will build entire scene from importing geometry, assigning materials, lighting and rendering our scene. Once we have established our foundation, then we'll take a deep dive into the Houdini soap context, and in here, we will take a look at different geometry, grouping techniques, geometry, attributes, transferring the attributes, driving extrusion from attributes. And then we will take a look at copying and instancing how to orient instances, geometry, instance attributes, copying multiple geometry. And then we will learn about x and obs, how to work with obs, and then we'll take a look at writing Vx code. We will learn about different data types, how to create perimeters and channels. And then we will learn about working with volumes in Houdini, how to create procedural skyscrape and hero clouds working with smoke solver and pyro solver for creating smoke, fire, and explosion simulation rendering fire and explosion working with ACS and rendering with ACS color space. And then we will dive into particles, how to create particle simulation, working with particle forces, creating our own particle forces. And then we'll take a look at pop grains for creating sand and snow simulation. And then we'll learn about Houdini RBD bullet solver for creating rigid body simulation, creating destruction simulation, fracturing the geometry. And then we will learn about Valum solver for creating soft body simulation. And we'll finish this course off with flip fluids, how to create both large and small scale fluid simulations. So join me and let's dive right in, and I will see you in the next lesson. 2. 02 Download Project Files: Okay, guys, here are the project files for the course. Make sure to download them. I have created an zip file. Make sure to extract that zip file, and in here, you should find all of the project file for the course, and don't forget to read the course and write the reviews, and I will see you in the next lesson. 3. 03 Get Started With UI: Let's get started with Houdini. You can download the Houdini software from the side effects website. And if you come over here, you can go into the Get tab and let's click on this Download button and the link will open. So here we have these two installer. You can download the launcher. The launcher is a new recommended way of downloading the Houdini versions. That is an online installer. So basically, you will be going to download a 67 megabyte of launcher. And when you install this launcher, in here, you can pick a Houdini variant and you can download and install through the launcher. So the active Internet connection is required for this launcher. Or you can pick up an old installer that is what we call the offline installer. So basically, you are going to download this 2.9 gigabyte Houdini software. You can download that and you can install this if you do not have Internet connection. First, you do need to download this, and then you can install this on any machine if you do not have active Internet connection on that machine, and the Houdini Apprentice version is completely free. So after installing this, you do need to install the free Houdini Apprentice license. So for installing the Houdini apprentice license, you do need the active Internet connection for the license. Okay. So make sure to download and install the latest version of Houdini. I have already installed in my machine. So here I have opened up the Houdini, so that is the Houdini user interface looks like when you first open it up. Okay. So up here, we have this basic menu, and onto the file menu, we can create a new SEN file or we can open an ACEN file, and here we can save the current SN file, et cetera. And down here, we have this shelf, and into the shelf, we have all of these presets, and this shelf is also divided into two different shelves. So in here, we have opened up the creative where we have these basic primitive box fare and all of these basic primitives. Or we can come over here onto the modify model, and we have all of these different presets. Okay. And in here, we can create the light and cameras. So the first option is the camera. We can create the point light. And we also have some collision. These are the dynamics for creating the static objects. So basically, all of these are the presets. Okay. So first, maybe let's create something in our viewport so that we have something to look for. So I'm going to pick up an a box. So let's click on it, and here as you can see, I have an interactive placer. So I can click anywhere in the viewport and to create the box. So I'm going to just click in here, and that will create an a box geometry in my scene. Okay? And you can navigate in the scene around by pressing and holding the old key. Okay, I am currently pressing and holding the old key. Now I can use the left mouse button to rotate and I can press and hold the middle mouse button to fan and by pressing and holding the right mouse button, I can zoom in and out in my three viewpod. Okay? And if you let go of the old key, that will switch you back to the currently active tool. So right now, and here we have the toolbar. Okay? So here we can see currently which tool is active. So right now, the show handle, so that is the manipulator tool. Currently, that tool is active. So which means by using this manipulator, I can move my box by using these handles, or I can use these radial handles to rotate my box, okay? Or I can specifically pick the move tool. So if you come over here and click on this, and now Errors can see all of the handles are gone. So now I'm only able to just move, so Errors can see by using these three handles. And same way, if you want to rotate and write down the move tool, we have the rotate tool. If you click on it, now we have these handles. So now I can use these handles to rotate my box in the scene. And down here we have the scale tool. Let's click on it, and we can use these handles to scale down our three D object. Okay? And down here we have the view tool. So the short key of that is the escape key so you can click on this camera viewtol and now we are in the view tool. Hers can see and now I do not need to press and hold the old key because right now my currently active tool is the view tool, so which means I can only just press and hold the left mouse button to rotate and by middle mouse button to move. And all of these short key keys, the mouse keys I can navigate in my scene around. And if you have the active tool, let's say, I'm going to activate my move tool. Okay, let's say I'm going to adjust the position of the box. Now if I want to navigate in the scene around, I can press and hold the old key and that will switch me to the view tool as long as I am holding the old key. If you let go of the old key, that will switch you back to the currently active tool, which was the move tool. Okay? So now let me activate my view tool, and in here, if you want to switch between different views, the cord views, you can press the Wiki on your keyboard. Okay, by pressing the Wiki, I can activate my cord view, and here as you can see. We have the perspective view, and that is my top view, and that is my front and right view. And I can move around with these different views by using the same shortcut keys, the middle mouse button to pen and right mouse button to zoom in and out. Okay. And in here, I can rotate because that is the perspective, I can rotate, but in these views, I cannot because these are the top and bottom views, so only I can pan and zoom in and out. And if you want to maximize certain view, let's say if I want to maximize this front view, just hover over to that view and press the Wiki on your keyboard, and that will maximize the currently hovered over viewport. Okay, press the Wiki to activate the Cord view again and hover over to the perspective view and press the Wiki to maximize that view. And you can also activate this coord view if you come over here where it says perspective. Let's click on it. And in here, we have this option set view. Can change. I can go through all of these views. For example, if I want to go to the front view port, I can just click on it, and that will switch me to the front view. I can click on this again and let's go into the set view and I can activate my UV viewboard. Let's click on it, and that is my UV viewboard. And the short keys are numpad one, two, three. So if I press the numpad one, that is my perspective view and the number two, three, and four, and the five is the UV viewpod. Okay? Let's press one key to activate our perspective view. And if you come over here onto these pans, you can make these pans bigger or smaller. Okay? I can make my viewpod bigger. And in here, we have this parameter window that is called the parameter window where we have the parameter for the currently active object. So in here, I can adjust the translation. I can adjust the translation by typing the number. That is the X, Y, and Z respectively. You can type the values in here. Let's select this X value, and let's type one and press Enter. Okay. Now I have moved my box one unit in X. Or if you hover over to the parameter that you want to adjust, you can press and hold the middle mouse button, and that way you can enable this incremental window, and in here, I can select the increment. Let's say if I want to add or subtract 0.1 increment, just hover over to the increment and move your mouse left and right to add or subtract the increment. That is a very cool way of adjusting the parameters. I can hover over to the rotate. Let's hover over to the rotate. X present hold the middle mouse bottom, and then this time, I'm going to select an A figure increment. Let's how to that, increment and move your mouse left and right. Okay. And that way you can very quickly adjust your parameters. And I can make these pains maximize bigger or smaller. For example, if I want to hide the pain, I can click on this up arrow button and down here where we have this adjustment. Heroscc we have these two arrows. If you click on this up arrow button and that will hide the pain. And if you want to bring this back, just come over here. Click on this down arrow button again to bring up these parameters. So let me hide this parameter because we can access this parameter by pressing the PK on our keyboard. So if I press the Piki and here as you can see that is my parameter window, I can make this parameter window bigger or smaller. And if I don't need the parameter window, I can press the PK to always hide my parameter window. And same way we are not going to use the shelf. We are going to create everything on our own. So I'm going to hide the shelf. So let's click on this up Araw button. If you come over here, Arrows can see. Let's click on it. That will effectively hide the shelf. And if you need the shelf, just click on this down row button. Okay. Click on it, and that will enable our shelf. So I'm not going to use the shelf, so let's click on it, and that will hide the shelf for us. And down here, we have the playbr. We can make this playbr minimized as well. Just click on this down arrow button, and that will hide the playbr. Okay. And if we need the playbr, just click on this up arrow and that will bring up our playbr. Okay? For now, I'm going to hide my playbar. And now let's save the user interface settings, because I like this minimal user interface. That is a much clean looking ding user interface. Let's save this configuration. We can save this by coming over here where it says build. Let's click on it, and here as can see we have quite a lot of these presets. So if I, let's say, click on this image option and Heres can see, my user interface has been completely changed. I can come over here and I can click this onto the animate and Heres can see. My user interface has been completely changed, and these settings are related if you are going to be animating, okay? And the default one was the build. Let's click on it. Okay. So because we have changed the build, that is why it looks like this. If you want to restore this onto the original setting, this build one, just click on it, and let's click onto this one, this reset main menu top. Sorry. We can click on this reload crunt. Okay. Let's click on it, and that will reload this user interface to the default to the saved one, okay? So I'm going to change this to the way that I like. So first, let's hide the shelf, and let's hide the perimeter window, and let's also hide the playbr, okay? And here as you can see my background has been changed to dark as well, and you can change your viewport background if you come over here and click on this i button, that will enable the display option, okay? So these are the Houdini display options. To change this, let's come over here onto the background. And here we have the color scheme. And right now I'm using the dark gray. You can change this to light. The light is the default, and you can change this to dark or gray or dark gray. So maybe let's change this to dark gray. Okay, I think that color scheme is good. Okay. So now let's come over here onto the build, and in here, let's save current desktops because if you press on the save current, that will override the build one, so I don't want that. So I'm going to click on this save current desktops, and that way, we can rename and create an copy of this current user interface. I'm going to rename this to my maybe underscore UI. Let's save this, it's saying that your user interface has been saved. And now let's also make this user interface as our default. So to make our new user interface default, let's come over here onto the Added tab and onto the preferences and onto the general user interface. And here we have the general user interface preferences. Onto the startup, right now, it says, Build. Let's change this to our own that we have created the Mui. Let's select this and hit Accept. Okay? So now, every time we run Houdini, that will be our default startup, Houdini user interface, okay? 4. 04 Overview Of Houdini Contexts: Now let's talk about how Houdini is structured. So when we create A three D scene, we work with three D models. We work with geometry, we work with points, primitives, and we also work with materials and shaders, and we also need to light them, and we also need to render the scene, and we need to create some cameras and all of these things that make A three D scene. So Houdini divide all of these tasks into what call the different context. So in here, if you come over here where it says objects. So the object is basically as an A scene level. So onto the object level, we call this one also an acne level. And if you click on this here as you can see, we have these other networks. So we have the jobs, and we also have the image network material and objects. So all of these are Houdini context. Okay? So to work with geometry, we have an A SOP context. So if I add an A SOP network in here, and here as you can see, I have created an geometry node that is named to Geo one. So that is effectively an SOP network. So inside, we have some SOP nodes. We can dive inside this geometry node if you press Enter Okay. So now we are in the SOP context, and here is you can see, it is written in here the geometry. So if we right click, so we have all of these nodes, these are what called the sub nodes. These are the surface operators, okay? And if we take a look at the path here, here is can see, we are inside of the geometry one. So first, we were at the object level, so the object level is our top level, the sin level, and we have created an a Geo one. Okay. And here is can see we have this icon. So that is this icon represents the sobs. Okay. I can click on this object level to go back. Okay. And now we are back at the scene level. Here is can see it is written in here objects. So at the object at the scene level, we have all of these. We have this geometry node. And in here, if we want to create a material, if we have a node called material network. So if I add this, so we have created an MAT net, so that is the material network. I can dive inside. And here as you can see, we are in the wax builder so if I right click, here we have all of these ax nodes. So ax is an Houdini shading language. And in here, we have some of these wax nodes. And we also have the shaders. I can create an a principal shader in here. So if I tie principal shader, let's add this. So principal shader is the Uber shader for the Houdini that is used by mantra as well as the new Houdini render engine karma that is the Uber shader for that. And let's go back at the scene level. And in here, we also have a node called Shop net and the shop Network, which means it's the shading operators. So if I add this, and here as you can see, we have the Shop net, and if we dive inside, and here as you can see the context has been renamed to shaders. So in here, if I right click, we have these different menu, and in here, we have all of these built in shader. We have some procedural shader and onto the surface, we have the surface shaders. And in hair, we should have the principal shader. So if I type in, so I think principal shader is not in the shader network, but we have all of these different shader. We have the material shader builder. I can create this sap and dive inside, and in hair, we should have an a principal shader. And here as you can see, we have the principal shader. Okay. So these two nodes are for creating the materials and for creating the lighting and camera, we can create the lights and camera right at the object level because that is also the scene level. So if I click and in here, I can type the camera node to create an camera or I can also create some lights if I type light and here we have access to all of these different lights. Okay? And we also have an dedicated context for rendering and lighting, and that is called the lopNt and Lop Net, let's create an op network. Let's add this. That is lopNt stand for the lighting operators. If we dive inside and in here, here as you can see the context has been changed to Solaris. So in here, Solaris is a new user interface for lighting and rendering our scene that in the Solaris when we are working with Solaris, we are working with USD. We will talk more about the USD and Solaris later in this course. But you should know that Lob net is there, that is the Houdini context for creating for lightening the scene. Okay. Let's go back. And in here for creating the dynamic simulation, we have context called top Network. Let's add this. So Hears can see, we have different icons, top Net. I can press Enter or tropleClick on this node to dive inside, and Hears can see now we are in the dynamics context. In here, I can create some rigid body simulation. Here we have the rigid body solver. All of the dynamic simulation related nodes are here in the dynamic context. So these are what called the tops. These are the dynamic operators. Let's go back. And in here, we also have context called chop net. Chop network is for the channel operators. If we dive inside, here as you can see it is renamed to motion effects. And in here, we can create some procedural animation. Okay. We will talk more about this later in the course. And we also have composting context in here as well, and that is called the cops. So we have two different contexts. We have the cop network, that is the new, and we also have the cop network old. So that is the composting network that we had previously in the previous versions of Houdini. So if I create an coop net Old and dive inside, and here as you can see that is called the composting. In here, we have all of these composting operator. And we also have a new context that is called the Cpernicus. If I create an ACP network in here and dive inside, and here you can see that is called the Copernicus, and that is the new context for creating the procedural materials. Okay? So let's go back and in here, we have all of these different contexts for organizing our three D scenes, okay? And you do not necessarily need to create all of these contexts at the scene level. So right now at the object level, you do not necessarily need to create in here. You can also dive inside each of these context by clicking on this object option. I can go into the shop context, and heres can see. We are in the Shader context. I can go into the material context. Okay? So I have access to all of these different contexts. Let's go back onto the object level. I can create context inside of the context. For example, if I go inside of the subcontext that is the geometry node. So let's dive inside. We are in the geometry context, I can create inhere Immaterial network. So if I create material network and hers can see, now I have created another context inside of this geometry context. Now I can dive inside, and in here, I can create the materials. For example, I can create an principle shader in here. Okay. And let's go back. And we have the material net inside of the geometry, and we also have the material network at this seal level as well, okay. So think of it as an folder. So you can create these different folder anywhere you like, okay? So you are not constrained to the object level or at the seen level. So let's say if you are working with in here, let's say, I want to create an a simple geometry, I'm going to create an a simple grid. So let's add grid geometry in here. Okay. And if you want to create an materrial for the grid, specifically in here, I can create an mat net, okay, in front at the side of the grid, and in here, I can create an a specific material for my grid. Okay? And I can assign the shader as well as adjust these values specifically for the grid, and I can keep things organized that way. Or I can go into the context. For example, let's go into the material context. I can create all of the materials in this context and start assigning them. Okay? So these are the different contexts for organizing your three D scenes, and we will talk all of them in details in this course, okay? So first, let's focus on the geometry context because that is the context where we will create geometry as well as our three D models, okay? 5. 05 Import Geometry: Now let's see how we can import three D model into Houdini. The three D model that you might have model in other three D software, for example, in Blender or Mayo, or you might have downloaded the three D model from the Internet. So to import the model, first, let's create an A Geometry node in here. So if I add type the geometry, let's add this. So by creating the Geometry node, we are effectively creating an A SOP network, okay? So I can type inside this node, and heres can see that is we are in the geometry context, and in here, right now, we do not have any nodes. Right now, our network is empty. Okay. And in here, we can start creating nodes for creating the geometry. And to input the three D model, we have an node called file node. So if we type the file, inside of the Jomry context. And here as you can see, we have the file node. Let's add this. So that is the file sap because that is the surface operator, we are in the Jomar context. So that should call the file sap. So into the file sup, let's bring up the parameter of the file sub by pressing the PK on our keyboard. Okay, so these are our parameter, or I can click on this Down arrow button and that way, I can divide my this network editor, and up here we have the parameter window or just the parameter. Whichever way you like, I prefer to just minimize this window and just whenever I need the parameter, I can select the node and press the PK. And that way, I have always access to the parameter, okay? And onto the geometry file, here you can pick up the location where you want to load your geometry, okay? And for the three D model, am I have downloaded the three D model from Ply Heaven. So let's come over here onto the Poly Heaven site. In here, we have all of these different resources. We have the materials and HDRI, we also have some free models. Let's browse some models. These are the models that are completely free to use. In here, let's search for the chess. That is the model that I am using. Let's click on it. And in here, you can specify your resolution for the texture. So right now I'm using the four k, and in here, you can specify the file, and right now it is set to blend, which means the Blender project file. I'm going to download the FBX model as AFPX, let's click on this FPx and download this, and that will download our texture as well as our FBX model. So make sure to download that. I already downloaded that. So let's go into our Houdini. And inhere onto the gem file, let's click on it, and inhere, I have extracted into this folder, C folder. So let's open up this chess folder. And here we have the chess set FBX model. Let's click on it and hit Accept. Okay. So our model has been loaded into hootini, but right now the scale is too large. Okay. And that happen when you have when you download the model, when you load the model into Houdini from other sources because this probably will be model in centimeter. So all of these application work within the centimeter units, but the Houdini works with in meter, okay? So if I press and hold the middle mouse button in here, I can enable the inspection window of this file node. So if you hover over to that node and press and hold the middle mouse button, now keep pressing and holding the middle mouse button, and that will enable this inspection window. And here we have some information. At the top, we have the information for the points. How many points does this model have? How many primitives and how many bird sis does it have? And in here, we have the size. So hers can see the size is currently at the 55 meter. So it is quite large model because it was built in centimeters. So other application consider this as a 55 centimeter, but because Houdini units are in meter, so it is in 55 meter, which is very large model, okay. So let's scale this model down into manageable size, and to scale this down, we can add a transform node in here. So let's type the transform, and we can create this transform node. So let's click and add this. And that way, we can create this transform node and let's pick up this wire and connect this in here. Now, the transform node has been connected. But right now, we cannot see we cannot see its effect and to actually view the effect, we need to hover over to that node and press on this eye button to view the effect of this currently created node. Okay? So now this node has been active. Now let's bring up the parameter of the transformed nodes by first let's highlight that node and press the PK, and that will bring up the parameter. And in here, we can adjust the translation. That is the X, Y, and Z. I can rotate my object. I can scale this individually into my X, Y, or Z axis, or I also have an uniform scale option so in here, I can adjust this uniform scale. Let's load down the scale value. And here as can see I am scaling down my overall model, okay? So that's how you can scale down your model as well as load your three d model into Houdini, okay? And let me hide the parameter of this transform load by pressing the PK and in here, here as you can see, I have these UVs important. This model contains UVs. So it is highlighted in the checker pattern. And if you don't want to see this checker pattern, you can click on this here. Here, it says the show UVs. So let's click on it. So right now, it's actually didn't work, but we need to click this again. Okay? And now Hears can see this option has been disabled. So for some reason, it was enabled, but it's showing that it was disabled. So that happens, but it's not a problem. And Hears can see now I am not visualizing my UV pattern, but it does have UEs. I'm just not visualizing them. And if you want to visualize this as an checker pattern, these UEs, click on this show UV visualizer, and that will add an H checker pattern to show you that the model contains UVs. 6. 06 Assign Textures: Let's continue with this chess scene. Now let's see how we can apply some basic materials and let's render this. First, I'm going to assign the material in the viewport so here as can see right now I am visualizing the UV checker pattern, and if you do not want to see this U checker pattern and if you have your own diffuse material and you want to see your model with that diffuse material applied, you can do so by adding an UV quick shade node. So if I add an UV quick shade, let's add this and let's connect this and how to the view pod and let's view the result by setting the display flag onto that node. And hers can see. Now we have the UV checker pattern applied. Now that checker pattern looks different. And let me enable the parameter of this node and this node, it's not actually applying the material. That is just for the UV visualization purpose only so that onto the texture map, here you can see, we are applying the UV grid map that came with a default of Houdini. So we can select this map in here on our own and that will visualize us in the viewport. So it's not going to actually applying the material. Okay? So in here, let's pick up our own diffuse map and let me enable this pickup and let's go into the texture folder. And here as you can see, we have a lot of these texture that came with that model. So at top, we have the chess set board diffuse. Okay. And let me take a look at the directory where we have all of these map. So here I have downloaded my three D model. Let's drive inside this folder. And here as you can see, we have the chess set board diffuse map, and we also have the normal map and the roughness map. And we also have another diffuse map that is for the chess set pieces black. So these are the that is the diffuse map for our black pieces. And we also have the normals and roughness. And we have another diffuse that is for the white pieces. So which means that we need to apply these diffuse map onto all of these pieces separately because these are all separate materials. So let's see how we can do that. First, I'm going to pick up my chess set board diffuse and hit Accept, and here is you can see, we have applied the diffuse map onto our board accurately, but the pieces are not getting assigned this map accurately because that map is not supposed to be for these pieces because we have separate map for these pieces. Let's separate these pieces from this board. First, let me remove this node from here. And if you want to remove the wire, you can just pick up this wire and click and that will remove the wire. Or you can press and hold the Yk on your keyboard, and that will switch you to the scissor mode, and here is you can see, my icon has been changed to scissor. Which means you can just click and draw and that will remove the wire. So I'm going to remove this wire, and in here, first, let's create some groups for all of these our different materials. So to create the group, I'm going to activate my selection tool. Right now, I am in the view tool. So let's activate the selection tool. Okay? So my selection tool has been activated. So now I can click anywhere onto this. I have access to all of these individual polygons. And if you want to select the points, just come over here at the top. Here can see we have the option to select the primitive or you can change this to edges. Now I will only be able to select the edges. And if you want to select the points, just click on this, and that way I can highlight and select all of the points. And you can also change this mode by if you come over here and present hole and here as you can see, we have all of these different modes. I can change these two point, edges or primitives. So for now, let's keep these two primitives. And in here, if you double click on any of these geometry, and that will select all of the connected pieces of geometry because right now the board is an A one connected piece of geometry, so all of my board geometry has been selected. Same way, I can click any of these pieces. Let me zoom in in here onto this piece. I can click and double click to select all of the whole geometry that is connected, which means that this piece is connected piece of geometry, one single connected piece of geometry, and same way I can double click on this night, double click and heres can see. I can select all of my connected piece of geometry, and also we have some selection constraint. In the selection tool. So if you come over here where it says select, let's click on it, and on this drop down menu, we have the option to enable the selection constraint. So in here, we can enable the three D connected geometry. So when that selection constraint is enabled, I can only select the connected pieces of geometry. And hers can see right now it is very hard to see because of these visualization. Let me see if I can hide the visualization. I think that now the visualization has been gone, and hers can see I can hover over. And now with the selection constraint enable, hers can see that is the selection constraint. So that is the three D connected geometry constraint. Now I can only select the connected geometry. If I want to select the individual polygons, I can't. If you want to select the individual polygons, you need to first disable the selection constraint by clicking on this option. Okay, let's uncheck this. Now we have disabled the selection constraint. Now I can select the individual polygons. Let's keep enable the three d connected geometry constraint. And now I can select all of these individual pieces by one click. First, maybe let's select this pod geometry, and if we rotate our camera heres can see we have some rubber pads. Maybe let's select all of them. Press and hold the shift key and click that will add this newly selection to our current selection. And now I can press and hold the shift key again, and let's add another pad. And in here, let's select this one and this last pad as well. So now all of the board geometry has been selected. Now in the viewport, hit tab key on your keyboard to bring up our node menu. And in here, let's type the group node in the viewport, press Enter. Now here, as you can see, in the node editor, we have the new node called group. Let me bring up the parameter of this node. And in here onto the base group, we have all of these primitive numbers that are being assigned. And onto the group name, here we are naming the group. Right now, it's named to group one. So maybe let's rename this to our board because that is our board group. Now we have successfully created our one board group. Now, separate all of these black pieces from white pieces, and for that, I'm going to first hide the visibility of these primitive so that I can select all of my pieces in the viewport. I can select this. So if I enable the selection tool and maybe let's enable the three D connected geometry, selection constraint, I can just draw. And that way, I can select my pieces pretty easily, and same way I can just draw. But sometime you might need to hide the visibility for the better selection or anything. Let's see how we can hide these primitives in the viewpod. So we can do this by creating an A visibility node. Let's add an A visibility node in here and maybe when the node is highlighted into the viewport, if you hit tab and bring up the menu and type the visibility node in here and press Enter, by creating the node in the viewport, that will create an node and assign the group into this node, and heres can see our primitives has been hidden. I can bring up the parameter of the visibility node by pressing the piki and hers can see. Right now, it's actually not using the group. It's actually using the current selection. I can tell because onto the group tab, we have some numbers and I currently cannot see the name of the group that I have created. The name was the board group. So I can create this by clicking on this group. I can just remove this. Okay, so all of the primitives has been hidden. So in here, I can pick my group, so that is the board group. So now we are using our board group. And now, all of these primitives are hidden. So I can now easily just pick up my selection tool and let's draw the selection in here. And into the view pod, let's bring up our node menu, and in here, let's type group. And that will create the group onto this current selection. And in here, I'm going to rename this group to maybe an A black. So these are my black pieces group. And now let's activate the selection tool again. And in here, I'm going to select all of these pieces. And if you want to repeat the current operation, you can just come over here onto these dots, just click on it, and Heres can see, we have the shortcut key for the repeat current operation, and that is the Q key. Just click on it, and that will repeat the current operation, and that was the group grade. And here is can see, we have another group, and that is called the group three. So let's rename this to white. These are our white pieces. Now let me activate my view tool. And now let's bring up our board, which means we do not need this visibility node. Just select that node and just relate this. And now we have all of these pieces back and we have created these three groups. Now, let's assign this UV shade node. So let me connect this and let's view the result of this UV shade node. And in here onto the group tab, we can assign which group we want to assign this UV shade map onto the group. I'm going to type the group name. I'm going to pick my board group because that is the group I want to assign this diffuse material, and hers can see only our board geometry has been assigned this diffuse map. And remember, that is just for the visualization. It's not the actual material. So let's create another UV shade node, so I can just select the node, and if you press and hold the old key and drag, and that will duplicate the selected node. And that way you can quickly create copy and paste nodes. So let me connect this after that. And in here, I'm going to select another group, and for this one, this time, let me remove this group. In here, I'm going to pick this black pieces group and onto the map, let's pick up our map, and I'm going to pick up this chess set piece black diffuse and hit Accept. And now I have this black materials assigned. Right now it is very hard to see, but it's actually there. And now let's do the same thing for these white pieces. For that, I'm going to press and hold the old key and drag and let's connect this. And for this one, let's remove this group field, and in here, let's pick up our white pieces and onto the material onto this map. Let's pick up our white diffuse and hit Accept. Let me hide the perimeter and let's zoom in and to actually make this smooth shaded to hide this wireframe visualization. I can come over here. In here, you can pick up the shading method. Let's change this to smooth shaded. Now I'm not visualizing the wireframe and here, I can clearly see that my map has been applied. Now, let's bring all of these into our specific context, the lob context that is specifically designed for rendering, because currently right now we are in the geometry context, we are working with sobs. These are actually not the actual materials. We are going to assign the materials in their specific context. For that, I'm going to create an A lob net in here. Let's create an a lob network and you do not necessarily need to create the lob Nt in here. You can actually go into the stage context by clicking on this OBJ level, and that will bring you back onto the scene level. And if you click on it, and here we have the stage context, okay? You can click on it. Now, the Houdini switches its interface, and now we are in the sol arrays. So in this context, we will building our UST universal scene graph and all of the rendering should happen in this solaris context. You can come in here onto the stage context, or if you prefer, you can create your own stage inside of this geometry, remember, because that is just the folder. Inhere onto the lop net if we dive inside and we are back again into the solas. But if you take a closer look at the path, heros can see, we are in the solas, but we have created this solaris network inside of our OBJ and geometry and we have this lop net. So whichever way you prefer, it's all up to you, but the context is the same. So if you right click here can see, all of these nodes are the same because we are in the Solaris context. So in here, I can import my geometry from this sap context because right now we are in the geometry context. And if we dive inside the Solaris and right now our scene is empty because currently nothing has been important. So we need to import our geometry in here for renting. And for that, we have a node called sop Import, so let's add an sp Import node in here. And that will import our geometry from sobs into Solaris for rendering. So onto the sb Import, I can pick up here onto the sub path if we select on this. So in here, I can pick up my node that I want to import. And for reference, let me go back onto my geometry level. At the very end, it is a good idea to create an null for referencing. So if I add an null, so the null node is actually do nothing. It's just a placeholder. If I bring up the parameter, here's can see, we do not have any parameters on it. It's just a placeholder. So let me connect the inhere at the very last and maybe let's rename this to our out for rendering. Let's rename this to out render. And onto the lop net. Let's dive inside, and onto the sub Import, let's bring up the parameter and onto the sob path. Let's select this out rendal and hit Accept. So now we have the geometry successfully imported into Solaris. So now we can start creating the materials inside of the solas. Let's create some materials in the solas in the next lesson. 7. 07 Materials And Rendering: Now let's create some materials for this model for creating the materials. You know that we have the specific context for creating the materials, which means I can go into this material context in here, and in here, I can start creating some materials. Let's create some material by adding a principle shader that is our Ubu shader. So I can create this material and let me copy and paste this material three time because we know that we need the three materials, so I can press and hold the old key and drag to duplicate this material node. And in here, I'm going to type the material names. So that is for our board material, and that is for our black pieces. And the last one, I'm going to create is for the white pieces. And now we need to just import all of these materials into solas because Solaris is our rendering context. Let's go into our OBJ onto our geometry. And here we have created this lop net. Let's dive inside. And to actually import the materials, we have an node called material Library. So let's add this. Material library, I can connect this and let me view the result of the material library, and let's bring up the parameter in here. And in here, we can define the material network from where we want to import the materials. So onto the fill here as you can see, we have this collapsible menu, click on it, and that will expose some of these parameters onto the material network. And in here, you can pick up the material network where you have created your material network. So right now we are storing this into this global Mt net. Okay, I can select and hit Accept so I have selected the material network, but right now, we do not have any materials. We need to click on this auto fill material option, and there you go. If we collapse this menu, and Hears can see we have three materials. We have the board material and the black and the white materials. All of the materials has been successfully imported into solas. Have this option because we can create material network in here. So if I create a material network, let's create this and let's tie inside. We can start creating some material in here, so I can add some principle shader in here. I can duplicate this multiple times so that we have multiple materials in here. And now, if I want to import the materials from here, I just need to go into the material library. Let me clear out all of these material by clicking on this clear option onto the material network. Let's choose another material network. This time, we are choosing the location inside of our geometry and onto the lob net, we have another Mt net head except, and I can click on this autofill material, and that will fill out all of our material slot. Or you can create the materials inside of this material library. So which means we do not need to actually create this MD net. So let me remove this and maybe let's go into the material context. I can just remove this. So let's go into the OBJ geometry, and that is our lob net. And if you dive inside of this material library, and here s can see now we are in the wax builder, which means we can start creating materials inside here. So if I create an principle shader in here, so here you can see the menu is not the same in this x builder because that is specifically designed for USD. We have menu a little bit different, but it's actually the same. If we want to create some material for the karma, we have this Kerma material builder. Okay, so we need to create this karma material builder, and that will create an A material. And if we dive inside, and in here, we have some basic material that is the material X standard surface. And in here, we should have the principal material. So the principal material is actually not here to create the principal material. We need to go back and inhere onto the shader. We need to create this wax material builder. So let's add this. And if we dive inside, and hers can see we have access to all of these Houdini karma materials, and inside, we should see the principal shader. So we have all of these nodes that are actually available if you go into the material context and hers can see we have the node menu same. So let me go back onto the OBJ geometry and onto the lop net. If you are going to create the materials inside of our solaris and that is actually the recommended way. You need to create material library in here. So I'm going to create material library, and you just dive inside in here and we are in the wax builder. And in here, we have this kerma material builder because Houdini ship with two different types of rend engine, we have the Kerma CPU and Kerma XPU, and that is why we have these different divisions because Kerma XP uses the material X. Here, I'm going to just create an kerma material builder, and now we have created an Evan material. I'm going to rename this our board. Okay? So that is our board material. I can just duplicate this material, and in here, I'm going to create another material for my black pieces, and I can duplicate this node again. And this time, I'm going to create my material for my white pieces. Now I can just dive inside these materials, and in here, we have this material X standard surface. So that is an standard surface material that is used in the Kerma XPU. It's also works with Kerma CPU. So in here, I can just define all of these parameters, the base specular color, and all of these things. And we will talk more about all of these things later in more detail later in the course. Now I'm just giving you the general overview of how Houdini is structured. Okay? So that's how you can create the materials. I can go back and onto the material library, I can just click on this auto film material, and we do not need to just define the material network because by default, it will use what's inside of this network. I can just click on this auto film material. And that will create all of these materials. Okay? And here as can see our materials has been imported. And for now, I'm not going to just use the materials, library and import create all of these materials, these standard surface materials and import the texture files that will be way long. And so for now, I'm going to just create a very basic quick material inside of the solaris. That we actually don't need the material library because we have a shortcut way of assigning a very basic quick material, and that is called the quick material. So if I type Hears CC, we have the quick surface material. So I can create this, and that will create all of the material network and the materials, all of these things will be inside of this node. I just simply need to connect this. Let me view this. Let's bring up the parameter and heres can see. We have all of these option exposed in here. It is a very fast way of just assigning simple quick materials without creating the material library and all of these things. And onto the base, let's enable the color map because right now we are just using the simple color. So onto the color map right now it is grade out. So just click on the start, and in here, let's enable the set or create option, and that will enable this option. And in here, I'm going to pick up this board map. So we need to go into the directory where we have the material. So let's drive inside and let's go into this folder. First, I'm going to enable import my chess set board diffuse it accept. And now let's create another material. I'm going to just rename this to board. Because that is our bone material, and let's duplicate this. And Harris can see when you duplicate, make sure that the wires are connected, and Hearers can see. Let's connect this. Now the wires is properly connected. And in here, I'm going to pick up the diffuse material for my black pieces. So let me find chess set pieces black, head except and I'm going to rename this accordingly black. Let me duplicate this node again, just connect the wires and let me pick up this white diffuse here except, and let's also rename them. Let's rename this to white. So we have successfully created three materials, and now let's assign them. And to actually assign them, we must have access to all of the groups that we have created. We will see how we can import all of these groups efficiently. But for now, I'm going to just duplicate this sub Import node. And for reason I'm duplicating this sub input node. So if we enable the parameter of the sub input, Hers can see, we have the option to import the group. So let me enable this. If nothing is selected, which means all of the geometry has been imported. So onto the group tab, I can pick up my group. So first, I'm going to pick up my board group and heres can see. The only board geometry has been imported, because we are only importing the board group. So that is why I'm going to triplicate this non, present hold, the old key. And for this one, I'm going to just remove this board group, and for this one, I'm going to import my black pieces. And I can view this by setting the display flag onto the sbipot and here you can see, these are my black pieces. And let me duplicate this supimport one more time. And for this one, let me remove this, and I'm going to import my white pieces. So maybe let's rename all of these geometries, the soap import nodes accordingly because right now it's saying sub Import 123. Onto the first one that is our board. I'm going to rename this our board underscore Geo. And for the second one, these are our black pieces. I'm going to call this one Black Geo, and the last one our white Geo. Now let's merge all of these geometries together. So I can create an merge node in here and let's connect this and let's connect all of these three geometries together, and I can view this. Let me activate my view tool. And here I have successfully rebuild my whole scene inside of the solas. You can merge your geometry like this by creating the merge node or you can just chain them together, which means I can just connect them after that and I can connect this in here, and that is perfectly fine as well. But I just like to create an A merged node because that way I have the perfect idea that I have all of the structure, it is perfectly fine. If you like to import your geometries like that, you can do so. But it's just a personal preference that I like to import my geometries in this fashion. In here, very top, I have all of my geometries, and I can just connect all of them together in the merge node. And that way, let me remove this wire. Let's connect this and connect this in here. And that way, I have a perfect idea that these are my geometry, and down here, we have all of these downstream nodes. So let me activate my view tool, and now let's assign all of these materials onto these different potent geometries. And for that, we have a node called material linker. So let's add the material linker node in here at the end, and let's connect this and view this. And let me bring up the perimeter of the material linker. Let me make this pan a bit bigger. And here as can see in here, we have list of all the materials, and we have the bold material and the white material. And at the center, we have the rules, and right now it's empty. In here, we have the geometry trees. We have this black geometry, board geometry, and white geometry. And to actually assign them, it's actually pretty straightforward. You just need to pick. I'm going to pick my board material, pick and drag onto the geometry, and hers can see. As I am hovering over to these geometries, these geometry has been highlighted into the viewport as well. Going to assign this onto my board Geo, just click on it, and Hers can see my rules tab has been filled, which means that my board material is saying that the board material has been assigned into our board Geo, and Hers can see we have this material assigned sign. So which means that that material is assigned onto board Geo. If I select the white material and Errors can see nothing has been there in the rule tab which means that this material has not been assigned to anything. So I'm going to just pick and drag onto these white pieces, that is the white Geo and Hers can see I have successfully assigned. Now let me select the last black material and let's track this onto our Black Geo. And now we have all of these three materials assigned successfully. Let me press the PK to hide the parameter and let me make our viewpod pan a bit bigger. Let's activate our view tool, and in here, I can zoom in and here, I can clearly see that this diffuse material has been properly assigned. And I can same way zoom in in here, and here as you can see, I have this white marble material onto these white pieces. Now to actually render this, we need to create an render node. Okay, so I'm going to use the karma. So in here, I'm going to create an Kermade in here at the end by creating the Kermade that will lay down these two nodes for us. First one is for the render settings. So we need to connect this. That is the input stage. Okay? So let's view this. Let's bring up its parameter. So here we have the main Kerma render engine settings where we can define the output picture where we want to store the picture, and we have these limits on all of the renders related settings. And at the last, we have this just basic USD thing that is the USD render Op for rendering all of your scenes and to actually render this, you need to just click on this option to render your output picture here we have the render settings. And now, first, let's create the light because right now currently, we do not have any lights in our scene. We are just working with the default light. And for creating the light, if you type light in here, we have the option to create all of these lights. Okay? We have the simple light. We have this dome light. That is the SDRI light, so let's create dome light in here and let's connect this in between, just add in here, and that will create this dome light. Let me bring up the parameter of this light. And right now, we are using this simple white color, and that is why we have all of these pieces looking washed out because we are lighting the scene with this white color. I can define my own HDRI file on this option. Select to pick up your own DRI that you might have downloaded, or Houdini also shift with the default DRI. If you come over here onto the Houdini pick DRI, let me select this. And here we have these three DRIs. These are the default HDRI that came with HDNE we have this Lenox Scarlet garage, maybe let's create this Scarlet garage HDRI and hit Accept. Here can see we have this HDRI light imported in here. Now, if you want to see how your scene looks like at the render, I just need to come over here which says perspective, click on it, and here we have these different render engines. We have the Kerma CPU. That will use the CPU to render your image and we also have the Kerma XPU Kerma XPU will use as your CPU and GPU to accelerate the rendering. So we are going to use the Kerma XPU for faster rendering. So let me select this render engine. And here as you can see the render engine has been started and it will load mycin into the GPU if you are going to render this with GPU, the first frame will take time because all of the shaders has to be compiled and loaded into the GPU. And once the GPU has been started, it will start rendering very fast. Let's wait. Right now, it says compile five, compile one, and here is can see Embry CPU is at 100% mean that we were using the CPU and here as you can see the optics has been started, which means now we are using both GPU as well as the CPU. And here we have the render, and we have all of these diffuse maps assigned. That was our very basic scene. I can go back onto these materials. So I can go into my board material, let me bring up the parameter. And here, I can adjust the base value color. I can adjust the specular, we have the option to adjust the roughness. I can zero out the roughness, that will create more shiny looking board. So all of the basic material related settings in here, that was the brief overview of how you can import all of the three D models and apply materials and shaders. That was the general overview of how Houdini structured and Houdini works. 8. 08 Geometry Grouping: Now that we have the basic understanding of how Houdini works in general, now let's dive deep inside of Houdini. And so, first, let's talk about groups, how we can create groups, how we can manage groups. And as you can know that groups are very useful for managing the geometry. First, let's create an emtry node in here. I'm going to create an a Geometry node because we know that we need the soap network if we are going to work with geometry. So let's create an a jemtry node and let's dive inside. Right now it's empty and in here, I'm going to create an A Rubber too geometry. If you type Rubber toy and that is the default geometry that cames with Houdini. You can create this. Let's add the Rubber too geometry in here. Here we have a very lovely looking rubbery. We can create the groups by activating our selection tool. So let me activate my selection tool. I can select and drag. Now I am selecting the primitives. So these polygons are actually called the primitive inside of Houdini, and I can change these two edges by clicking on this edge. Now I am able to select all of the edges, and I can change the to point mode by activating the point selection. Or by selecting them and I can select the points. And if you want to change the selection because right now heres can see, I am dragging the Marquee selection. I can change this if we come over here, heres can see. We have the currently box select enable. I can change this to lasso select, so let's click on it. Now I can draw the lasso and that way I can start selecting my geometry or I can just change this to brush selection, and that way we have this brush. And right now it is very hard to see, but it's actually there is a circle at this point or location. I can change the circle by changing this radius. So just hover over to that perimeter present hole the middle mouse button, I can just rag click and trag and here as can see. Now I have this bigger brush. And I can also change this to laser select. Laser select is basically just selecting for these single points. It's what we call this one point selector, maybe. So let me activate my box selection, and here we have the option. So it says select visible geometry. So if this option is enable, that way, I can only select the geometry that is actually visible to this camera angle. So if I drag this selection box and rotate my camera, and heroes can see all of the points that are outside of our camera, they are not being selected. So if I disable this option, let me uncheck this select visibility, and now if I draw my Marquee selection, now I should have selected all of the geometry and hers can see all of my geometry has been selected, I can drag and all of my geometry has been selected. If I enable this camera, selection contraind and drag in, and now hers can see the parts of the geometry that was not visible are not being selected. We have selected all of the points or the primitive, I can bring up the node menu by pressing the tab key on my keyboard, and in here, I can just simply type the group and press Enter, and that will create the group node and assign the selection that currently been active in the viewboard into this group. Let me activate my view tool. And if I enable the parameter of the group tool, hers can see, the group type has been automatically set to points because we have selected the points, and here into the base group, we have all of the list of number of points, these array of points that we had in the selection. So now all of the points they are in the group one. I can rename this group into the group name. I can type this. Any name that I want, maybe let's type this M underscore group. Now I can check if you press and hold the middle mouse button and here as you can see. We have this down here, one point group, and the group name is the MGroup. Let's see the different ways of how we can create the groups. First, I'm going to just remove this group node, and in here, I can type the group node and let's add this and connect this into this geometry, view the node. Let's bring up the parameter of the group. And at the very top, we can defide the group name as you can know, right now, it's set to group one, that is the name. And to the group type here we can define which of these types we are going to storing. If it's a primitive group, which means these faces, we can change the two points group and here you can see. Now we are storing all of the points inside of this group, or we can make this group an A edges group. So now we have all of the edges, or we can make this an a faults group. In other three software, points and tics are the same, so they are called same. But in Houdini, points and for Cs are not the same. So Word Cs are different than points. Please do keep in mind. We can change the group type in here. Let me keep this to the primitive group, okay, so that we have the primitives. Into the base group, we can define which primitive we want in the base group. So right now it's enabled and when this value is empty, which means all of the primitives are inside of this group. I can manually specify them if I enable this option by clicking on this arrow and heroes can see, that will switch me into the viewport, this selection, which means I can draw the selection and I can press Enter to complete my selection. Hers can see the base group option has been filled all of these arrays of numbers. So these are actually the primitive numbers. So I can just select all of them and delete them. So now all of the primitives are inside of this group, and we can actually visualize our primitive number if you come over here. So these are our viewport visualizer. So at first, we have this one that is for the display point. If you enable this, that will enable this point display. I can uncheck this to disable the point visualization. And in here, we have this display primitive number, visualizer. So if you click on it, that will show you the current primitive number. And if I zoom in and here as can see, we have an A primitive and its number is 5983. So if I want that primitive in my group, I can just simply type the name onto the base group. So if I want to create add this primitive into my group, I'm going to just type the number 5983. And heres can see only that primitives are now inside of this group. And I can keep adding the primitives, so I can just press hit space, and now I can pick another primitive, let's say, 6361. So I'm going to type 6361 in here, and Heres can see now we have these two primitive inside of that group. So that's the very basic way of how this group node work and how you can group the geometry. Let me uncheck this primitive display visualization by clicking on this display primitive number that will hide the visualization. And in here, I'm going to just uncheck this space group. Okay, now that space group has been unchecked, now we have the group one. But now this group is empty. So if I middle mouse button, and here as can see we have an A one primitive group, and it is called the group one, and right now we do not have any primitives inhere so it says zero. So I can enable this another option that is called the keep in the bounding region. I can enable this. And first, we have this bonding type. Right now, the bonding type is set to bounding box, which means that at the center, here's can see we have this bonding box. All of the primitives that are inside of this box will going to be in that group. Can adjust the size. If I middle mouse button, I can adjust the size X. I can adjust the Y size, and onto the center, I can adjust the position of my box. So wherever this bounding box is all of the points will going to be grouped inside of that box. I can change this bounding type geometry. I can change these two bonding sphere. And here, as you can see, we have this spherical piece of geometry, bounding geometry. Okay. So wherever this sphere is, we will have these primitive in the groups. And onto the bonding type, we also have the option for the bounding objects. So it means that if you click on this bounding object, and this node will throw an error because we are saying that we are going to assign our own bonding geometry and we are going to assign this bonding geometry into this second input. And if you ho over to the second input, here's can see, we have this bounding object. So right now it is empty. That is why it is throwing an error. So which means I can create any geometry that I like. Let's create an a sphere in here. So let's create this sphere. Okay, here we have the sphere, and I can just connect this in here and I can view. And here as you can see the error is still there. So let enable the parameter of the group node. And if you hers can see, it says that bounding objects only supports the points and faultss group. So which means we cannot create primitive group if we are going to use this second input, this bounding geometry. So which means we must need to set this primitive into the points or fultics. So let me change this to points and heres can see the error is gone. And now all of the points that are inside of M sphere geometry are now being group. And I can create an a transform node in between to adjust the location of my spares. Let's add a transform and connect this. And onto the transform, let's bring up the parameter. Let's adjust the translation, translation and Y translation, and hers can see wherever my sphere is, all of the points are being in the group. But now, let's say the group node is only support the points, but I want the primitives. I don't want the points. So I can actually promote this group into the edges or primitive. We can promote this by creating an group promote node. So let's add in a group promote and let's connect this in here and onto the group promote. First, we need to define the group name, which group that we want to promote. So onto this one, I'm going to select the group one because that is the name of our group, group one, and right now we are converting this from auto to points. Auto means that it will know its current group type, and we are going to convert this into points, but we want to convert this into primitives. So let's select this now heres can see all of our groups has been converted into primitive. I can also convert them into edges. So now we have the edges group. So you can promote or convert any group types into any types. So if you have the primitive group and you want to convert them into points, you can do so by adding the group promote node. Let me change this back to primitive, and now I can just play around with this sphere and heres can see. I can interactively create the groups onto this region. So let me remove this group remote node, and let's remove all of these from the second input, and let's uncheck this keep in bounding region. And we have the other option that is called the keep by normals. So if I enable this and here we can define the daction of the normals. So first, let me disable the keep by normal, and we can view the normals of our geometry if we enable this option. Here can see that is called the display normals. If I enable this, and heres can see we have these blue lines. So these are the geometry normals, okay? So all of the geometries has normals. So the normals have these direction that is touring the primitive facing directions. And heroes can see all of these faces have their own direction, which means we can group these primitives in facing in the specific directions. Let me uncheck this display. Normal option to hide the visualizer and let's enable the keep by normals, and let's enable this. And onto the direction, we can define the direction. And right now, we have this option X, that is the X direction, that is the Y direction, and that is the z direction. Here we have the spreading angle. Let's adjust this spreading angle, and here can see all of the points that are now completely at the 60 degrees spread facing onto the Z axis. The last axis is the Z axis. All of these are now in this group. I can change this into primitive group, and here can see we have all of these primitive groups. I can actually reverse the direction by coming over onto the direction and let's change this from one to minus one. And here as can see. Now all of these primitives that are facing onto the opposite sides of the Z axis are now in that group. Okay, so the range is between in zero and one. Let's change this to zero onto the Z axis, and maybe let's enable the X axis. I'm going to change this to one. So all of the faces that are now facing onto this X axis are now in our group. And same way I can change the interrection in minus by adding the minus one in here. And same way, let's zero it out and let's change this to one onto the Y. And here is can see all of the faces that are pointing upward are now in this group, and we can adjust this spreading angle. So that's the key p normal. Let me uncheck this. And we also have the option to include by edges. Let's enable this. And in here, we can define the minimum edge angle. So if I enable this, and Hears can see we can define the edge angle. All of the edges that are in that angle will be in the group, or I can enable this by maximum edge length. And right now, Hears can say I cannot enable this option because right now we are in the primitive group, and we need to in the edges group, let's enable this, and now hers can see we can enable this option. So let's enable the minimum edge length, and let's disable this edge angle option. And in here, I can define the edge length. So if we take a look, hers can see we have this one point and here we have the another point. So I can measure the length if I know the length and I want all of these edges that have the same length in the group. I can just define that. I'm going to just randomly pick a length and let me zoom out, and let's maybe select a very low this increment and let's keep increasing that and hers can see. All of these edges that have the 0.043 length will be in that group, and all of these smaller edges we are discarding all of these smaller edges. You can group this by this edge length. Here we have the minimum edge length. I can enable this by a maximum edge length. And at the very last, we have this keep by random chance. I can enable this. And by enabling this, I can randomly create the groups. So onto the percentages, the 100 mean that all of the geometry in the group and the value of 50% of all of the edges being placed in that group randomly. And we can adjust this random seed by adjusting this global seed. So every time you adjust this global seed that will randomize this selection, I can change this to primitives and I can keep playing around with that and hers can see, I am grouping the 50% of these random primitives. And we also have a node called group Pi range, which is very useful. So let's create an group Pi range node in here. Let me add this. And for this, I'm going to create an true geometry, polygonal tube, let's connect this in here. Let me view this. Let's view the result of this group Pi range. And onto the group I range, here I can define the start and end position. So the start and end mean if I enable the primitive number because right now we are working with primitive groups, so that is why I'm enabling the primitive number. And here as can see, we have the zero, one, two, three, all of these primitive number. Let's say I want to skip this zero, so I can say start with one. Enable start with one, and here as you can see, we are skipping this first primitive. I can say start with two, and now we are skipping these first two primitives. And in here, I can also say that I can start this zero and end my selection at the primitive number eight. So I can go into the end and type the eight. The first eight primitives must be selected. So let me see end mean because it's actually says relative to start and, okay? So I can change this to start and N. Okay? So let's change this. Now I can select the first eight primitive and here as can see by selecting the eight, we are selecting first eight primitives. The range dive was the trilative and that is why it was actually not working because it was selecting the relative length. And let me change this to zero and one, which means all of the geometries are in the group onto the range filter, I can select every one of one. Right now, it said select every one of one. I can change this to one of two. One of two mean we are skipping every second primitive, and I can change this to third, three. So now we should skip every third. So there we have these two primitives gap in here. And if I create grid node in here, maybe let's add a grid node and connect this into the range and hers can see. Let me hide the primitive number display, and I can now select every one of two and Hers can see. I am selecting the checker pattern. I can keep changing this to 1/5 or six. You can define your own range to create a pattern of groups. Maybe after the group, I can create an extrusion in here. I'm going to add a poly extrude node. Let's add this and connect this at the end. Onto the poly extrude, here we have the option for the group. So let's select this group one, and right now the extrusion is not happening because we need to adjust the distance. Let's add some positive distance value and heroes can see we have these extrusions. So now I can go into the group i range. I can play around with these groups and Hers can see. All of this poly extrude will work procedurally because that is an procedural setup. I can create an a random group, so maybe let's create a group node in here and connect this, and I'm going to disable the base group and keep by random chance, play around with this random value and connect this because the group name has been changed. Right now, it says group two, so we need to update this polyetrude from group one to group two, and here as can see we have the extrusion, and I can play around with these percentages. Can play around with the seed value. These are the different ways that you can create the groups inside of Houdini. 9. 09 Geometry Attributes: Now, let me introduce you to the concept of attributes. You'll find yourself dealing with more and more attributes whenever you are working with Houdini because that's where the power lies. That raises the question, what is attribute? Attribute is a name value that can be stored on points, primitives, or vertex. Let's see in action in Houdini. So first, let me create an A Geometry node. Okay, that is an empty sap container. So let's dive inside. And in here, I'm going to create my rubber toy geometry. So let's add this, and here we have the rubber to geometry. And if we hover over to that node and press and hold the middle mouse button, and here as you can see, we have some attributes on our geometry. So at the top, we can see the number of points, the primitives, and down here, we have two points attribute. The first one is the N, so N is the normals. And the second one is the P, which means the position. And also we have an a primitive attribute that stores the materials path where we have these materials, and we also have an A vertex attribute that is UV. So first, let's talk about the attribute N, which is the normal. Normals are the geometry normals that defines the direction of these faces, these primitives. And we can visualize the normal. If you come over here, we have this visualizer that says display normal. So if I enable that, and heroes can see we have some of these lines. So these are the normals. These normals are actually storing the orientation in which all of the faces are facing. If we were to, let's say, reverse the normals and herds can see we have this normal, and if I were to reverse this, so maybe it is easier if I just remove the shader. So let's bring up the parameter of our geometry. Here we have this add shader. Let me uncheck this. And here we have our shader is gone, but now we have this UV visualization, and we can also hide this UV visualization by clicking this button, show UV, just click on it. So UVs are there, but we are just not visualizing them in the viewport. And here us can see if I enable that. Here we have these point normals. So if I were to reverse this, let's say, if I want to add a reverse node in here, let's create an reverse node. What this reverse node will does, it will reverse the normals of our geometry. So if I connect this and view the result and here as can see, now our geometry is facing inward. So if I enable my point display these normals, and right now it is still showing me the correct orientation. That is because I'm currently viewing the point normal and not the primitive normal and to actually view the primitive normal, we have this option that says, display primitive normals. So if I enable this, and now here as you can see, our normals are actually inward. So if I were to just remove this, I can bypass this node if you hover over to that node, and here as can see we have this yellow arrow. So it means the bypass. So if I enable this, heres can see, now I am just bypassing the effect of this node. And heres can see we have these normal facing outward in the correct direction. And if I were to enable this, now my geometry is facing inward. And maybe I can visualize this battery if I add an a clip node in here. So let's add an A clip node, and let's connect this after that and view the result of the clip node. And what the clip node does, let me hide this visualization normals. The clip node will just clip your geometry along an axis, and if we take a look at the parameter, as you can see, right now we have the direction. The X is set to one, which means we are clipping our geometry along X plane. And if we take a look at this nomen, hers can see, that is our X axis. I can adjust the plane here by adjusting this parameter. It's just a basic clipping operation. So that's what clip node does. And heroes can see our geometry is facing inward. And if I were to bypass this reverse node, and now heroes can see we have the correct orientation are these faces. Okay? These are the geometry normals that define the orientation of our geometry, and that is called the N. If I middle mouse button, heroes can see, here we have the N. So let me remove this clip node, and let's remove this reverse node, and if I middle mouse button, and hers can see now we only have the point and AUV attribute, vertex attribute. And right now, we do not have a primitive this material path attribute. That is because we are not adding shader. So if I enable the add shader and we have the materials assigned. So now if I middle mouse button and heres can see, I have an one primitive attribute shop material path store the location of where this material is. So let's uncheck this. That's what the attribute is. And the UV, so UVs come as an A attribute, and it is an A vertex attribute. So UV is always stored on the vertex level, although you can store on points as well. But generally, they are at the vertex level. So if I enable my UV, visualization, and also I can view this by going into my UV viewport. So if I come over here and let's go into the set view, and let's enable the UV viewport, let me zoom in. And here as you can see, we have these UVs of our models. So these UVs are come as an A attribute. So if I were to remove this attribute, I can add an A attribute, delete node. So let's add this and connect this in here, and we need to view this attribute delete. And here, we can define which attribute that we want to remove. So onto the vertex level, I want to delete the UV. So in here, I can type UV or I can just pick from here and here is can see we have an AUV. So here's can see now the UVs are gone. So this UVvie port is empty. And now if I middle mouse button, Hears can see we do not have an A vertex UV attribute. I can confirm if I go into my perspective view, so let's go into our perspective view and hers can see my UV visualization is on, but I do not see any UV visualization because we do not have UVs. Let's bypass this node, and Hears can see we have our UVs back. That is the UVs that comes as an A attribute. So let me remove this and onto the attribute onto this roboto geometry, maybe let's create an attribute delete node. So we need that. Let's add this and connect this. And for this time, I'm going to just click on this option delete non selected. So which means if no attribute is defined, which means that all of the attributes will going to be deleted. So let's enable the delete non selected, and if I middle mouse button, and Hears can see I only have one point attribute, and that is the P. P is the position of these points. If I enable my point display, let's enable this and Hears can see we have these points. I can view this P attribute, this position attribute into the geometry spreadsheet. So if you come over here at the top, heres can see we have some different pans let's go into the geometry spreadsheet. And here we can view all of the attributes. And top here, we have this attribute P, and here you can see it has three components, the P in X, P Y, PZ. P is an a vector attribute because it has three components. It has X, Y, and Z, and we can inspect all of the different kinds of attribute in our geometry spreadsheet. Right now we are visualizing the point attribute and we can change this to vertices. So if I click this and here is can see onto the vertices, we have this point num attribute, and onto the primitive, currently, we do not have any attributes, and we have the detail and we currently do not have any attributes on detail as well. So let's go into the points, and here we have this P, which store all of the points, here we have these point numbers. If I click on it, that will show me the order in the correct order. So we have point number zero, one, two, three, and all of these points. And we have the corresponding values. P is essential because that is storing the position, maybe it's easier to visualize if I just remove all of the geometry. So I can say add A extract all points. Let me add the extract all points and connect this, and here is can see. Now, we only have points and we do not have any primitives, but I can still see that we have the shape of our rubber toy, and that is because all of the points are placed in three D space to make it look like our roboto geometry. So all of these points have a certain position value of the three D space. If I enable my point number and hers can see, we have all of these points, and we have these numbers assigned to them. And if I zoom in and hers can see, we have 0.11 970 so that has a certain location in three D attribute. It has an X value and Y and Z value in the three D space. All of these points have their own unique position. That's what storing in the geometry spreadsheet this P attribute is it's storing the location for all of these points. And if I were to zero out these values, so right now we have all of them their correct position. So I can make this position zero by creating an attribute wrangle. I'm going to just quickly zero out the position and we will talk more about detail what I'm doing or how we can create this. But right now, just let me create an A example in here, so I'm going to call this one at P, which means the position and I'm going to just setting it to zero. So right now, you do not need to worry about what I just did, but what I just did just zero out the position. So let's go into the geometry spreadsheet and Hears can see. Now we have these point numbers, and all of these points have an A value of zero, which means that now if I enable my point display, hers can see. Now all of the points are at the origin. So it's saying that it's displaying that as if there is one point, but all of the points are crush down at the origin. I can enable my point number display. Let's enable this and hers can see. We have some numbers on top of each other, which means all of the points are at the origin because all of the points has position of zero. So I can middle mouse button in here, and heroes can see. We have all of these points. Okay, so the points are not gone, but their position is zero. So let me remove this attribute triangle and go back and heroes can see fi middle mouse button, I still have same points, but now they have their position back, and now I can make that it's an arable to a geometry. Okay? So that's what P is. We can create our own attribute after the extract all points, maybe let's remove this and inhere so that we have our geometry back the fi middle mouse button. Okay so we have points and primitives and word sees all of them back in here. But right now, we only have one attribute P position, which is essential for storing the location to make up this model. So in here, I'm going to create my own attribute and you can create your attribute by creating an attribute create node. So let's add this and connect this in here and onto the attribute create. In here, we can define the name of our attribute that you want to create. And right now the name is set to attribute one so if I middle mouse button and Hears can see, now we have attribute one attribute, and we also have TP. And here we can also see these data types. So it has these three float option and the attribute one that we just created, it says FLT, which means the float. In here, we need to define the name. I'm going to call this one M underscore attrib. Let's rename this and now if I middle mouse button and here is can see it has been renamed to Matrib that is the name that we just created down here, we can define the class where we want to store the attribute. Right now we are storing this as an a point attribute. Can change this to primitive. So if I now middle mouse button and hers can see our position has been shifted. Now it is an A one primitive attribute. My attribe is an A primitive attribute, and now I can check if I go into the geometry spreadsheet. Hers can see. Now I'm visualizing the point attribute. And there I cannot see my attrib attribute because that is on the primitive, so let's click on this primitive. And here we have my attribute. I can change the class to point attribute if I want, so now I can go back and here I can see. Now I have an point attribute, or I can change this to an A detail attribute. So we need to go into the detail and here is can see. The detail only have one value. So detail is an A attribute that contains the geometry as a whole. So all of the points and primitives are stored as an A. Detail is actually just the geometry as a whole, so it's only have one value in here. So if I were to change this to primitives and go back and here is can see we have all of these primitive numbers, and all of the primitives number will get this attribute, my attrib zero. And in here, we can define the type. Right now we are storing the attribute as an A float type. We can change this to integer or an A vector, and Hears can see by changing this to vector. Now we have three value. We have the X, Y, and Z, and we can check if I middle mouse button, and Hears can see we have one primitive attribute and it's three float and here we have this one see, which means the vector. Let's talk about what all of these data types are. So first, we have the float. So let me enable the notepad in here. So first, we have an float. Float is store the floating point numbers. For example, we could have an a value of 1.0. Okay? So that is an a floating point value. Or I can say we have an value of, let's say, 1.35. Now that is another floating point example. I can change this to any number, let's say, 78 point something. So all of these are examples of floats. Okay? So that is a data type of float. And we also have data type called integer. So what is an integer is integer contains the whole number. For example, one is an A integer, the number of five or six or 100 so the whole number. So integer cannot contain, let's say, number of 1.35, okay? That is wrong data type because it's not an a whole number. So integer only contain the whole number. For example, 700, you can type, you can type anything as long as it does not have any fractional part, okay? Because then that will change the data type to float. So these are the integer. And we also have another data type called vector. Vector contains three value, we could have an floating point value for the X. We also have value for Y, and we also have Z. So vector contain three values. Vctor has three components, the X, Y, and Z components. So the example of vector can be the position. So if you are going to store the position, position has three value. We have the position for the X, Y, and for the Z in three D space. And for the color, if you are working with color. So color have an AR, and G, and B components, so we have red, green, and blue values. So that could be a example of vector attribute. And we also have an A attribute type called string. So string contain the character or words. For example, if I want to store the halo word, so that is an string data type, I can say anything, let's say, Houteni all of these character and words, all of these are these are what call these strings. And we also have some other data types, matrix, and all of them, but these are the basics, so that we're going to talk about. Let me minimize this note pad and onto the class, here we can define the class where we want to store. And here we can define the type. Okay, so we have this one float, and we can define in here, we have this one the default value and we have the value. So here, I can define which value I want to store. So if I were say that my atribs float, I want to store a value of 1.35, and here is can see my attributes value has been changed to 1.35. I can change this to anything that I want, 125 and here as you can see. Here we have the value. And I can change this to integer, and here as you can see the fraction part is gone, which means I can only store the whole number. Can say one, two, or if I were to say 12.5 and here is can see it has been round to 13 because it cannot store 12.5. I can change this to 12.4, and it will only just store the value of one, two, because it is an A integer attribute data type. I can change this to vector, and here is can see. Now we have three components. We have an X, Y, and Z, we can define them in here. That is the X value and here is can see. I can store the Y value to something else, let's say 45 and here is can see, the Y value has been changed. I can change the Z value. Let's change this to 78 and here is can see. We have these three values. Also I can change this to string and in here, I can type anything in here, I'm going to type in here haloord and Heres can see we have this halo word written in this primitive atrib and we can inspect middle mouse button. And hers can see we have one primitive attribute, my attribute, and its data type is STR, which means it's an A string. Same way if I change this to vector, and if I middle mouse button, hers can see now we have three float, it's a vector attribute. I can change this to integer and now if I middle mouse button, here I have the data type int, which means that it's an integer attribute. I can change this to float. Let's middle mouse button. And here we can see the attribute type. It is FLT, which means it's float. 10. 10 Attribute Based Extrusion: Now that we have understanding of the attributes, what are the different types of floating and integer data types of these attributes are. Now let's put these attributes into action into use, okay? So how we can leverage these attributes. For that, let's say, if I want to drive the extrusion of the geometry. So maybe in here, I just create grid in here. Let's create a very simple example. Here we have the grid, and we have these different primitives. Let's say if I want to extrude the primitive, so I can create the extrusion. If I enable the selection tool, I can select any primitive. And when the primitive is selected, I can bring up my node menu and I can type Poly extrude and hit Enter. And here we have this manipulator and I can click and drag to drive the extrusion and if I go into my node editor, Network Qe, and Heres CC, I have created an poly extrude node. Let me activate my view tool. Let's enable the parameter of our poly extrude and Heres can see onto the group to it. We have selected the primitive number, the primitive number 40. We are extruding the primitive number 40 by this value. I can change this inset value. That's how the basic extrusion work. I can remove this group menu in here. Okay, what that will do, it will just extrude whole geometry up and hers can see. If I adjust these settings, let me play around with the inset and heroes can see. All of our primitive, if nothing is selected, all these grid primitives has been extruded upward. So what if I were to create an A attribute and drive the extrusion, okay? Because right now, we were just extrusing everything upward. So let's see how we can do that. First, I'm going to create an A attribute. So in here, I'm going to create an attribute, create node and let me connect this in here because I want to drive the extrusion of the primitive, so we need to create an a primitive attribute. Okay? So onto the class, let's change this to primitive, and I'm going to rename this one my atribe. Let's rename this Matribe in here, let's say I want to extrude all of these primitive into one unit into the Y. So that is an A we will exchange this to one right now because I think because we are going to drive this polyetrude value, let me add this with this one. So I want to drive this parameter with this M attribute. So because it has an A N value and it's an A floating value. It's an A floating value because we have some fractional part 0.118. So which means we need an A float attribute. So in here, I'm going to I'm keeping the value to one. I can change this to 0.5 and I can go into the geometry spreadsheet onto the primitive hers can see we have a value of 0.5. And in here, let's connect this and view this. And right now, hers can see we are using this to drive the extrusion. But what I like to do, I like to drive this parameter with this Matrib. Okay? So what I can do, I can go into the polyetrude node. And let's go into the local control. And onto the local control, we have these option for the local attributes, which means we can use the attributes to drive these parameters. So at the first hers can C, we have this one, this distance, and heres can C we have the distance attribute. So let's enable this and in here, we need to define the name, and by default, it's set to Z scale, which means that it's expecting the Z scale attribute on our primitive. But in here, we have created our attribute name Matrib. So let's go into the polyextrute, and in here, I'm going to just rename this to the attribute that I like to use, and I like to use the Mattribe attribute. So let's add. Let's type the name in here. And now heroes can see we have some extrusion. And now this value will become as an a multiplier. Okay? So this value will going to be multiplied by this our 0.5. So what I like to do, I like to change these two all the way up to one, which means that we are just going to use this value because now the multiplier is one, which means everything is equal to this. So which means I can just come over here and I can adjust this value. And now heroes can see I'm using this attribute to drive my extrusion. And right now, it has an uniform value. So nothing interesting is going on in here because we are just using the uniform value for all of these extrusion. If we go into the geometry spreadsheet and here as can see all of these primitives get the same value, 1.09. Now, let's randomize this attribute. I want to create some random extrusion. To actually randomize this attribute on per primitive basis, we have an node called attribute randomize, so let's add an attribute. Randomized node in here. And in here, we need to define the attribute name. Right now, it's randomizing the CD. So what CD is CD is an A color attribute. It stands for color diffuse. It's also the sensitive, the upper KC and lower KD. If I were to just connect this and hers can see that will give us an a random color. And that is because we are randomizing the color. And if I middle mouse button, and here is can see, we have an point attribute CD. So CD will produce the color in our geometry. If I create an color attribute in hair and let me remove this node by shaking off and let's add this node in hair. And by adding the color herir, I can define the color. I can pick any color that I like. Let's say blue color. And hers can see if I middle mouse button, here we have an ACD. So CD is color, color. This attribute is the attribute that Houdini understand to set up the geometry color. And right now it is an a point attribute. When we were creating this attribute, randomize, it will creating the CD and also randomizing its value. That's why we get random this rainbow looking color. I want to randomize M atribT attribute that we have just created. Let me copy this attribute. And let's go into the attribute randomize and onto the attribute name, let's paste our attribute that we want to randomize my atrib. And now, if I go into my Jem try spreadsheet, and here as can see my attribute has not been randomized, and that is because the attribute class is set to point, but we have the primitive attribute. So let's change this to primitive, and here as can see we have these random values. I can change the distribution to change the randomness, and here we have quite a lot of option. So we have this one uniform continuous, and we have this also option for exponential. And here as can see we have all of these random Matt attribute on per primitive basis. Here we have the primitive number. So the primitive number 50 will get an extrusion value of 0.9, and primitive 49 will get the value of 2.6. So let's see how this random extrusion looks. Let's go back into our scene view and heres can see it looks the same. And that is because we need to go into the polyetrude and let's go into this. Let me find here, extrusion mode, divide into. Right now, it says connected components because all of the geometry is connected, so this extrusion is just not working correctly. So let's change this to divide into individual elements because we want to extrude individually all of these primitives. So on to divide into, let's change these two individual elements. And now hers can see we get some random extrusion value. So which means now I can go into this attribute randomize and in here, I can play around with this limit. Here we have the main limit and max limit. I can play around that minimum extrusion value, how much the minimum value it should generate. I can define the max value or I can maybe exchange this to something else. Maybe exchange this to custom RAM. And now we can use this ramp to randomize this attribute to create this random extrusion. Here we have the minimum value and that is the maximum value. So that is an A per primitive randomized extrusion that is only possible with the use of attribute. We can copy and paste all of our setup in here. So let's remove this attribute create, I can just select all three nodes and just click and drag and let's connect them in here and hers can see. Let me escape that and select this node and organize them and zoom in and Hears can see now we have the random extrusion going on on the geometry, maybe the scale is too big, so we can go into the polyetrude and Hears can see that is a multiplier. So which means I can just lower this down to multiply my overall extrusion and Hears can see we have this random extrusion because all of the setup is procedural. So first, we are creating the attribute, maybe let's change the value to one. And in here, we are using the attribute randomize to randomize this extrusion attribute, and into the polyetrude we are using this attribute to drive the extrusion. Let me break this down even further if you do not currently understand how this working. So onto the attribute, randomize let me remove this attribute, randomized node, and first onto the M attribute, here we are creating the attribute for all of our primitives, the same value. All right. So if we go into the scene view and if I enable the primitive number, and heres can see we have this primitive number right now, they are starting like this. Let me arrange this. So we have the primitive number zero, one, two, three, four, and they are going like, Okay, 91011. All of these we have these primitive numbers. So let's say if I want to create an a random attribute on my own onto the primitive number 41. So what I can do, I can type onto the group name in here the primitive number. I'm going to type primitive 41, which is that primitive. And I'm going to setting the value of 1.1. If I go into my geometry spreadsheet and onto the primitive and let me find the primitive number 41. So let me find where. Okay, so 42, it says 42. Sorry, I have type 42 in here. So 42, we have the value of 1.1, and all of these primitive will get an A value of zero. So I can keep creating this my attribute. Let me duplicate this attribute create node, and let's connect this down the line. And for this one, so I accidentally type 42. Now, let's type the 41. So let's type 41 in here and I'm going to assign the value of 0.5 this time. So now if we go into the geometry spreadsheet and let me find the primitive 41 and 42, there we have. The 41 primitive will get value of 0.5, 42 get 1.1. And I can keep creating this my attribute and let me connect this. And for this one, I'm going to store the value for the primitive zero. So in here, I'm going to type the primitive number, and I'm going to type some random value, let's say, 0.35 maybe and here you can see the primitive number will get that value. And let's keep creating them. And for this one, maybe I'm going to assign the value to primitive number 11. So onto the primitive 11, this one maybe get a value of 0.8. And let me fine. And here is can see we have value of 0.48 for the primitive 11. Now let's go back. And now let's use the poly extrue. Let's see how the poly extrude is working. Let me hide the primitive number and let's view. And here is can see all of the primitives that has the values will get the same extrusion. Which means I can go back, and here I have control. Let's say if I want to adjust the extrusion for the primitive 11, I can just come over here and play around with this value, and here as can see. I can individually control my extrusion. I can go back to the primitive number zero, let's play around with the extrusion value. Let's go back onto the maybe primitive number 41, and let's adjust this. So basically that's the manual way of creating and assigning the attribute and what the attribute randomized node is doing, it's automating all of these tasks for us. It's just taking the attribute, the M attrib and assigning them an a random value. And here as you can see here we have the number of primitives and we have the corresponding values. And polyextrude will use these values to drive the extrusion. So let me view this once more. That's how these attributes work. 11. 11 Attributes Transfer: Now let's talk about transferring the attributes from one geometry to another. So here I have opened up my previous scene. What I'm going to do, I'm going to create another example in here. So first, I'm going to create a simple grid geometry. So let me view this and let me enable the parameter of this grid. And here we can set the size to make our grid bigger or smaller. Me change this back to the default, and here we have the rows and columns to adjust our subdivisions of our grid. So maybe let's increase this to 100 by 100. So basically, I just want to create a lot more divisions to add a lot more resolution in our grid. In here, let's create another geometry. So maybe let's create a sphere in here, polygonal sphere. Let's at this. And here we have this lovely sphere. And now let's create the attribute. So for this one, I'm going to create an a color attribute. Let's add a color node in here and let's connect this and onto the color. I'm going to creating the CD attribute onto my point level because you know that the color node will just create an CD attribute if I middle mouse button. Here as can see now we have this CD. And in here, we can define the color. I'm going to create a red color for our sphere, and I'm going to create another color attribute onto this grid. Let me connect this. And for this one, I'm going to make this color black, which means R G and P, all of these values will get NI zero, which produce the black color. And we can check if we go into the geometry spreadsheet and we need to enable the point attributes because right now we are viewing the primitive attributes. So let's go into the point attribute, and here as you can see we have the position, PX, PY, PZ, and now we have the CD, CDR, the red color, CD, G, green color, and blue color. So all of these values are set to zero, which means the black color, and sure enough, we have the black color. Let's go into this sphere, which has red value set to one and zero all of these components. Can go into the Geometry spreadsheet and check and here you can see, CDR, get an A value of one for all of our points. These are our point number and G and B are zero. Now, basically, I want to transfer this red color onto this grid, which has a black color. So I can do this by creating an A attribute transfer nude. So if you type attribute transfer, let's add this and it has two inputs. The first one, the geometry to transfer attributes too. So I want to transfer the attributes to my grid. And we have the attributes from. So I want to transfer this from this sphere. So that is our from geometry. I can view the result of the attribute transfer and hers can see our red color has been transferred to grid. Our grid was black, and after transferring, now the grid is red. I can change the color onto my this sphere. I can change this to blue. Now if I view the result, and we should see the blue color. And onto the attribute transfer, we have some parameters. In here, we can define which attribute that you want to transfer right now, we are transferring the primitive as well as the points attributes. If no attribute is selected in hair, which means all of the attributes will get transferred, all of the primitive end points. But because we are only just care about the point attribute, we have the point attribute. So we can just uncheck this primitive option, and onto the points, we can specifically define inhere if you have multiple attributes and you only want to transfer certain attribute, let's say, in this case, I want to only transfer the CD, so I can just pick in here, and now we are exclusively telling this attribute transfer to just transfer the CD and not all of the attributes. So make sure to keep that in mind whenever you are transferring the attributes, and we can go into the condition tab if we go in here, and we also have this option for the distance threshold. So right now the distance threshold is set to ten, which means the 10 meters, which is a very high value. So if I were to lower these values down, and here as can see, we are effectively clamping the radius in which this attribute propagates in here. Let's lower this down to an a value of maybe the size of sphere. And here is you can see, we have an radio of radius of 0.5. So what I can do, I can just type in here the distance threshold to 0.5. So now, only where our sphere is located, this attribute get transferred and not all of our grade. So I can template my original geometry and you can template your geometry if you hover over to that node and click on this option, and that will template your geometry. The templated geometry can be viewed as an A wireframe and heres can see we have an A wireframe representation of our original templated geometry, and heroes can see where our sphere is, we only get transferred attribute in here. So which means I can create an A transform node in here. So if I add transform and connect this onto the transform, if I play around with the position, let's say, I want to adjust the position, and right now our templated geometry is not moving because we are templating this original color and not this transform. Let me template this and template this transform node so that we have visual feedback where our sphere is. Now, if I can adjust the position and hers can see where are our sphere is located, these attributes get transferred. That is very powerful technique for creating all sorts of different effects. So which means what I can do, I can create an a random extrusion value in here. For example, let me create remove this color attribute from here, or maybe just duplicate all of the setup, select all of these node, present hold the old key to drag, and let's remove this wire. We don't need this. And onto this one, let's remove the color attribute. But let's say we want to create an a random attribute onto these primitives. So in here, I'm going to create an A attribute, randomize. So let's add this. And by the way, if you create add an A attribute, randomize and you do not have attribute, let's say on top, we do not have an ACD attribute. Hers can see we only have P, and if we create an attribute randomize, it will create the attribute as well as randomize these values. Here is can see now we have the CD attribute. Which mean that this node is creating the attribute if the attribute does not exist. So which means I can just type the attribute that I want to create. So I'm going to create the attribute M attrib. So let's name this M attribe and if we middle mouse button, and here is can see, we have the Mattrib and we want these two onto the primitive level. So let's change the class from point to primitive and now if I middle mouse button, and now we have the primitive attribute M attrib. And it should have random value. We can go into the geometry spreadsheet and onto the primitive and Hears can see right now it has three values. So right now it is an if vector. We can define this in here onto the dimension. The right now dimension is set to three, which means we are creating the three values, vector attribute, zero, one and two. If I were to change the dimension to one, and Hears can see now we only have one attribute M attribu which means now it should have an a float attribute. So if I have a middle mouse button and hers can see, sure enough, we have the Mi attribute and it's an float attribute. And it also have random value, which is nice. Now, let's transfer this attribute onto this geometry where we were driving the extrusion right here. So I'm going to just maybe create another rubber toy geometry in here. Let's add an rubber toy and let's remove all of the attribute that currently this default geometry has by creating an attribute lead node, and in here, I'm going to click lead non selected to remove all of the attributes. And in here, I'm going to create an a attribute transfer node. Let's add an attribute transfer, and also we have this attribute transfer node in here. We just need to connect this onto the attributes, now we want to transfer the primitive attribute M attribute. So first, let me connect this because that is the geometry where I want to transfer the attribute. And right now it's throwing an A warning. So here we have the warning sign, and that is because it can find the CD attribute, and that's fine because we do not have CD attribute. So let's go in here and uncheck the CD. Enable the primitive attribute because we only care about the primitive and maybe let's explicitly tell that we want to transfer the M atrib. And now, if I template this geometry, so wherever we have the sphere, let me adjust the position of the sphere. We should start to get some random values for the extrusion. So if we go into the my attrib and let's go into the geometry spreadsheet, primitive and here is can see. Most of them have an value of zero, and we can click on this to sort. And right now, and Heres can see, we are starting to get some values. We have some random values and we are transferring them. Let's go into the scene View. And now let's create another poly exxtrude node in here to drive the extrusion. Let's add this and connect this, let me untemplate this attribute. Transfer and template over this spare geometry and onto the polyextrude, we need to change this to one because we know that is multiplier and divide individual elements. We want to extrude all of these individually. Let's go into the local control and enable this distance attribute. And in here, let's type the attribute. And we are going to type our attribute that is called the M attrib and here can see we have the extrusion happening. Let me lower down this scale value and we have some of these distance problems so we can go into the attribute transfer and onto the condition. Let's lower down this distance threshold to keep it close wherever our sphere is. Let me keep lowering this distance threshold value down. Let's keep lowering this down, and there you go. And here you can see where we have this sphere, we have the extrusion, which means I can go into the transform and I can just keep moving this sphere. Let me adjust this, and here can see we have the extrusion. Another thing that we can do, we can select the node. So when the node is selected in the node editor, the transform node, hover over to the viewport and press Enter. And what that will do, it will activate the manipulator tool. So now we have these handles to move our sphere for the selected node. So now I can use these viewport handles to place my sphere, and hers can see where myspare is, we have the extrusion because we are transferring the attributes. So transferring the attributes is a very powerful way of controlling your effect, and it is quite useful. 12. 12 Copying Geometry: Now let's talk about copying the geometry. So in here, let's create an geometry node, the empty sap container, and let's dive inside. And in here, I'm going to create a simple sphere in here and onto the sphere, let me enable the option. And here we have the option to change the primitive type, and right now we are creating the polygonal sphere, and it has all of these points and primitives. And we also have an a sphere type that is called the primitive. So what the primitive type sphere is it only has just one point. If I middle mouse button here can see it has one point, and it only has one primitive. It's actually an A one point, and dini knows how to draw this point as an A sphere. So which means it's an a very lightweight geometry. Because we are going to duplicating our geometry, copying this, so our scene will get heavy if we were to change this to polygon or polygon mesh. If I middle mouse button, heres can see because we have a lot more points and primitives, it's an A heavy geometry. So that is why I'm changing this to primitives because it's a very light way to work the easiest way to copy your jum tree, we have a node called copy and transform. So if I type copy and here is C C, the first node, we have the copy and transform. So let's add this and let's connect this and let's view the result of copy. And here is can see right now we are creating the two copies, but I can only see one sphere, and that is because another sphere is on top of this first sphere. So what I can do, I can change the translation in here so I can let me play around with the translation in X, and here as can see we have another sphere. And in here, I can define the number of copies, and I can keep creating these copies, and this value will get added onto this newly created copy. So we keep incrementing this X value and creating the copies. So here I can define some copies. And also I can do what I can do. I can create another copy node. So let me duplicate this node and connect this. And for this one, I'm going to just translate this into my Z axis, and if I take a look at this nomen. Here is can see the Z axis, let's zero out the translation X, that is the Y, and that is the Z. So let's play around with these settings and heres can see. We have an A grid of copies. I can lower down the number of copies in here. And also and create another copy and transform node, just duplicate this again and let's connect this whole geometry into another copy node. And for this time, let's zero out the Z, and let's play around with the value of Y. Let's enable this. Let's add some Y value in here, and here as can see we have multiple copies, and now I can individually control the number of copies. So these are the Y copies, and these are our Z copies, and the top one, we have the X copies. That is very simple way of creating the copies. And we also have an node called copy to points. So if I enable this type this and here can see, we have an node called copy to points. So let's add this. And this one has two inputs. The first one is the geometry to copy. Okay, so first, let me duplicate this sphere. So press and hold the old key and track that will duplicate this sphere. And I want to geometry I want to copy this sphere, and we need to define the points. So for that, let's say I want to create another sphere. So let's add this time, let's add on a polygonal sphere. Let's let's go into this sphere, and I'm going to increase the radius. So if you hover over to this radius parameter and increase the value, and by that we can increase all of these values with this radius, let's adjust the radius value to make this radius a bit bigger. And if I enable my points and here as you can see, this sphere has lots of points, all of these points. So what I would like to do, I would like to copy this sphere geometry onto these points. So we have these points. These points have their location. I want to copy this fare onto these points. So what I would like to do, I can connect this in here. So what this will do, it will just use whatever the points coming on this input, it will use these points to copy geometry. So if I view the copy points node, and here as you can see, we have the fare geometry copied onto these points. So which means if I were to adjust the rows and columns. So by adjusting the rows and column, I am creating more or less points. So because points are changing, we should have the changing number of copies. So if I view the copy points node, and here as can see, I can play around with the rows and columns to create more or less copies, and I can also swap my geometry. Right now I'm using this sphere. I can, let's say, add an A box geometry in here and let's say I want to copy my box geometry, and let's connect this. And now let's view the result of copy to points, and now let me hide my point display. So let's uncheck this option. So now we are copying this box geometry onto these spare points. And same way, I can play around with our rows and column to create more or less of my box geometry. And also, I can put different kind of geometry. Let's say this time, I want to put an grid in here, if I enable my points, and heroes can see we have all of these points right. If I enable my point number, so we have these points, and they are in the regular grid array pattern. If I were to connect this and with the result of copy points, and we have the box copied onto these points, I can plug my sphere geometry in here, and we have all of our regular arrangement, which can be controlled from these grid points. I can play around with these points. I can adjust the rows and columns, and in here, once we have copied we have this geometry, I can keep creating another copy node, for example, let's say, and create another copy and transform node. And this time, I'm going to connect this after that, and we are creating two copies, and let me move this one up and I can define the number of copies. And here we have different ways of copying our geometry. And if you also have an A line, let's say, if I were to create a helix in here, so if you type helix, that will create an primitive spline basic curve. So onto the helix, we have some parameter. Here we can adjust the heights. We can adjust the number of these turns. We can adjust the start radius and radius scale the overall radius. So all of the basic primitives for working with these spirals, if I enable my point number and heres can see, we have these points right. So if I enable my point number, so this line has all of these points. So which means I can use this as an A O point input. So if I were to copy this sphere, here we have this sphere. And if I connect this in here and heroes can see, we are copying our square geometry, let me scale down my sphere. Right now, my square size is too big, so let's go into the uniform scale and lower this down. And heroes can see we are copying this sphere geometry onto this onto this helix. And if I were to add the box in here, here we have the box, and if I connect this and view the result and let me lower down the uniform scale for my box because the box scale is too high. And heroes can see we are copying our geometry onto these points because we have these points, but we do not currently have the information for the orientation, which means that we are only using the position of the points. So this copy to points node is only using the position, so we have these points so we are only looking for the position where we have the points. So the copy the points node look for okay, so the point number zero is here. I want to place box in here. And point number eight is here. Okay, so I want to copy the copy number eight, which means the box number eight onto this location. But it does not have the information for the orientation. That is why these copies do not aligning onto the curve. They are at their correct position. The placement is correct, but their orientation is not. If I were to change this box rotation, if I go into the box, let me enable the parameter and here we have the rotation and if I were to rotate this on Y axis, I'm going to just adding a slight rotation and now if I view the result and heroes can see we are using the same rotation. So we do not have the orientation information, which mean if I change this, all of my copies will get the same rotation because this copy to point node is only looking for the position for the points onto the second inputs. So to actually copy this geometry onto these lines with correct orientation, we have another node called copy to curves. So if you type copy to curves and Heteroscenc, we have this node, copy to curves. So that is designed for copying the geometry onto these lines. So for example, this helix is a type of line. So that will take care of the orientation. So which means let me connect this grid in here and let me remove both of these sphere. And for this one, it has the same two inputs. It requires the geometry to copy. So for this one, I'm going to copy the box and connect this. That is the geometry I want to copy, and it requires this line. So that is the line. Let's connect this onto the second input, and let's view the result of copy two curves. And right now this scale is too big, so let's go into the box, lower down the uniform scale value. Let's keep lowering this down. And let's zoom in, and there you go. Now, hers can see all of our box are aligning onto whatever we have this helix. So all of the orientation are accurate. So they are adhering to our original line accurately. It is still using the points. So if I enable my point number, these points, it's still using these points. But now it is also looking for the orientation of how this line is actually oriented. Okay? So that is why we have the separate node copied to curves. And if I were to play around with the number of point, let me see. Okay, so here we have the number of points. So if I adjust the divisions, by adjusting the divisions, we can effectively control the number of points. So which means we should get more or less of our box copies, and Hears can see. Let's go into the helix. And if I were to play around with this setting, hers can see I can create more copies or less copies. Here we have this copy to curve for copying our jemry to curve and we have some option in here that we will talk about in a minute because it's looking for our curve normal and we have some additional rotation option. So if I enable the additional rotation, so which means I can enable the roll if I apply the roll, in here, I can enable this to rotate my box along our curves. I can enable the twist in here, and Hears can see they are twisting as they are progressing our curve, it may be easier to see if I were to increase the number of points, and Hearers can see we have an twisting effect. Let's go in here. Let's play around with this twist and maybe zero this out, we also have a partial twist option. So if I enable this I can enable the partial twist. So let's zero this out. And let's see we also have the option for scales. So let's enable this. And we have this uniform scale to control our overall scale. And we also have the option to stretch. So maybe change this to one, stretch around turns. Let's enable this. So right now, it's not working. Maybe we need to create an ALS number of copies. So what it will do, it will stretch our geometry wherever we have these turns. So if I enable this Okay, so right now it's not working, but we'll see why it's not working, but right now it's not important. So let's hide this and we have some attributes. These are the attributes that we want to copy. These are the option that we will talk about more details in later. But right now, you can just add this rotation here we have the option to copy our geometry onto the curves. In the next lesson, let's talk about how we can copy multiple geometries. Right now we are copying the box. In here, let's say, if I want to copy my box as well as sphere together, if I were to create another sphere primitive, let's say if I were to copy my box as well as sphere, how we can copy these multiple geometries into the copit points, we will talk about that in the next lesson. 13. 13 Copying Multiple Geometry: Up until now, we are using the one single piece of geometry to duplicate. So we were either using the box or we were using the sphere in here in this example to duplicate and replicate our geometry. But now let's see how we can incorporate another pieces of geometry, multiple pieces of geometry. For example, in here, I want to copy the sphere in here as well or maybe some other type of geometry that I like to copy. So let's see how we can do that. First, I'm going to create an A very simple example by adding an A grid in here. So let's maybe zoom in onto this grid. So here we have this grid, and first, I'm going to create an A box. Let me make this into this side. And in here, let's create an ape primitive sphere. And this time, let's copy only these two geometries to keep things simple. So we have the box and sphere. So what we can do, we can add an merge node in here and let's connect all of them, both of these geometry into the merge, and hers can see. Currently I cannot see the box because the box scale is smaller, so we need to increase the scale. And hers can see we have both of these geometry on top of each other. We have sphere, and we also have box. Can add an copy to points node in here and let's connect this. That is our geometry, and I want to copy this onto these points. So onto the grid points, let's connect this, and let's view the result. And here as can see. Let me scale down this overall, or maybe I can just decrease the rows and columns to create less copies. Let me lower this down. And heres can see what this copy two point node is doing. It's actually considering that all of these geometries. So whenever we have it does not matter how many geometries you have. When we merge them, now it's a single piece of geometry. The copy two points does not know that, in fact, we have these two geometries. It only knows that it is a single piece of geometry. So which means I can no matter, I can keep adding the geometry. Let's say I want to add an A rubber toy in here and connect this into the merge, and maybe let's increase the scale and heroes can see now we have three geometries, but when we add an A merge, now it's a single piece of geometry. Copy to points does not know that we have, in fact, three geometries. If we enable the copy to points and heroes can see all of four geometry has been copied because it thinks that it's an a single piece of geometry, and to actually copy these multiple geometries, we need to tell copy to points node how we want these geometries to be copied onto discrete points. The way we can do that, we can create an A attribute. So in here, I want to create an attribute. So let's add an attribute, create node, so into the attribute, create. So we want to create a string attribute that will store their unique name. So we can call anything of our attributes. I'm going to call this one maybe an MiGeo. So I'm going to call this one M underscore geo. For geometry, and I'm going to change this to an a string attribute. So let's change this to string. And for this one, I'm going to name this because we are storing the box in here. I'm going to name this box. If we go into the geometry spreadsheet, and that is a point attribute, and here is can C we have an A MiGeo and we have the value of box because it's SNS string, we can check. Hers can see SNS string. We are storing the box value. So I can duplicate this node again, this attribute create node, and this time connect this inhere. And for this one, I'm going to call this one spare because we have this fare geometry, and I'm going to duplicate this again, connect this inhere, and this one, I'm going to call this one our rubber. So now if we go into the merge node and middle mouse button, so now we have an A string, maybe let's go in here and uncheck this Shader attribute, and here can see, we have an A point attribute MiGeo and it has an A string. And onto these three mean that we have these three unique values. Okay? So that's what these three mean. So if we go into the merge and sure enough, we should have three unique because we have box, we have sphere, and we also have rubber. So we have these unique values. So now that we have this attribute M Geo, now all we need to do is we need to tell our copy to point to use this attribute to copy onto our these grid points. So onto the copy to points, and here we have this piece attribute. So let's enable this. And right now it is expecting an A attribute called name, but we have the attribute that is called MiGeo so in here and Hears can see, currently, we cannot see this MiGeo. I can manually type my attribute, myGeo and heres can see it's not working and nothing is happening. And that is because we have the MiGio attribute onto this geometry side, but we do not have the same attribute onto these points. If I middle mouse button, herars can see currently, we do not have SM attribute. So the copy to points node does not know onto the which point, it should copy the geometry. So we need to create the same attribute onto these points as well. Maybe let's create a more simpler example. And for that, I'm going to create an A add node. So what the add node will does, it will create a single point. So onto the number of points right now it's set to zero, I can create an A plus pad in plus. Now we should have an A one point and if we zoom in and enable my point display, and here you can see at the origin, we have an A one point, and we can check if we middle mouse button. Us can see we have a one point. And here we can set the position of our point, and heres can see how this position is moving. So in here, I'm going to create three points. To easier to work with, we can actually create three points in here and play around with their position, and Hears can see. We have these three points and we have the positions defined here. So the 0.1 have and a 00, and the second point, we have this X value change. To actually make this easier, I'm not going to create multiple points using this method, but I'm going to just duplicate this node. And for this one, I'm going to just change the value and for this one, let's duplicate this one more time, and let's add another increment value. And in here, I can add an merge node, and I'm going to select all of these nodes and merge them together. And now we have these three points. Five middle mouse button heres can see, we have three points. I can create the same attribute. This one attribute creates. So what I would like to do, I can just duplicate this node. And in here, I'm going to connect this one. At the first one, I'm going to copy the box geometry, and for the second one, I'm going to duplicate this another one and connect this in here, the same attributes, connect this onto this side. So the first point will get an A MiGeoattribute, the value of box, and the other one will get an A sphere, and the last one will get this rubber toy. And we can check if we middle mouse button. Hers can see we have this IGO string attribute, and it has three unique values, and we can inspect by going onto the Geometry spreadsheet on to the point attribute, and heres can see points number zero get box, one gets fare and two gets rubber. So now we are ready to plug this into our copy to points node. So now I can connect this in here, and when this option is enable this my geo attribute, and if I view the result and sure enough, let me hide my point display. And here as you can see now we have these three geometries copied onto these points, their corresponding points. So let me adjust the position so that is our rubber toy. Let me play around with this position or adjust this position. And what I'm actually doing, I'm just playing around with their point positions where we are creating these three points. So we are using these three points to copy this geometry. So now Copy to points node knows that which point it should copy with geometry, right? So that is the whole purpose of creating the MGeogeometry on both stream because we have an identifier in here, so that is the box, and we have an attribute that that we are assigning the label, are an A box, and that is our sphere, that is an Arberty, we are assigning the labels. And onto the points, we are also assigning the label that whenever this copy to points node will copy, it will look for this MiGeo attribute. So if this point has an A value of box, it will copy the box. If this point has an A value of sphere, it will copy this sphere. I can change this. For example, if I go into this one, the second one where it says spare, if I were to change the value, let's say I want to copy box in here, I just need to change the value. If I change this two box and here as can see, now the second point will also copy the box. I can make this onto our last point to the box as well. I can change this two box, and now all of the points will copy the box geometry, and now the copy two points node is discarding all of these geometries. Because it cannot find the corresponding this attribute value. If we go into the geometry spreadsheet onto these points because all of these points has a box. So that is why copy to points node will only copy box. I think that makes sense. So now let's see how we can automate this process because right now, we are manually assigning the Mi geo attribute onto these three points. But in case of grid, where we have a lot more points, we can actually create this my attribute. I can just connect this inhere, and I can go into my group tab in here. I can define my point number. If I enable my point number display, let's say I want to copy onto the point number 13, to the 13, I want to copy the box and I can just duplicate my attribute node and connect this after that. And onto the point number 18, let's say, onto the point number 18, I want to copy my rubber geometry, and I'm going to copy one more time, connect this. And for this one, point number 16, maybe onto the point number 16, I want to copy the sphere. And now, if I connect this, we should get these values. And let me see why it's not. Working. So we have the Mi geo attribute. Let me check. So actually onto the group, it's actually not working because maybe I think we need to define onto the group type in here. So guess from group, it's actually not working. Let's explicitly tell thee to point, which means that we are not referring to the primitive number because if we have the primitive number and we also have the point number, and that is why this group tab is actually getting confused. So we may need to manually change this group type to points because we are actually telling Houdini that this 18 is actually a point number and not a primitive number. That's what we are doing. So I'm going to change these two points. Now if I middle mouse button and Hers can see, now we get these three unique values. So now we should see these three results and heres can see we have these three geometries copied. And all of the other that does not have the attributes, these points because we have a lot more points, but we can only see three geometries because other do not get the name attribute. Hers can see the my geo attribute is empty. So that is why no geometry has been copied onto these points. So what I can do I can duplicate this node at the very top in here, and for this one, I'm going to just remove the group field and in here, I'm going to just assigning the same value onto this sphere. So if we select this last node, so we will get the feedback of this geometry spreadsheet onto this last node. So all of the empty points will get an a spare value and all of the values that we have defined, the box and rubber, they will get their own. So now we should see the sphere box and all of them will get the sphere. These empty points will get the sphere. So that's what we were doing. We were just assigning an sphere plane value. That's an manual way of doing things. So that's how this actually working. So now let's see how we can actually automate this process to actually copy this MiGeo attribute onto these points, we have node called attribute from pieces. So if you type attribute from pieces node, here we have this, let me add this. So this one has two inputs. The first, it needs the point clouds. So these are the points that I want to transfer the attribute. Okay? So let's connect this. That should be our point cloud, and it requires the geometry library. And there we have the geometry library, o, because all of the geometries are in here. So I can connect this in here, and now if I were to view this, and now by default, it is looking for the attribute that is called name. So the attribute name should be set to name. So but we want to transfer the copy this MiGeo attribute. So we need to rename this inhere onto the attribute from pieces. Let's say, I'm going to say transfer the MiGeo attribute because that's the attribute where we have the identifier, the so now if I middle mouse button and Hears can see, we have M Geo and it is successfully transferred onto these grade points, which means now I can use this node as an A input, and now if I view the result and Hears can see, now we are copying multiple geometry onto these grid points, which means I can keep adding more points. And it will take care of all of these naming and all of these things. This attribute from pieces node will procedurally copy all of these attributes hair onto this geometry, right? So which means so if I were to add another geometry in here, let's say if I were to introduce an platonic in hair, so let's add a platonic solid, that is a primitive pyramid shape onto the platonic, we can change the solid type. We have this cube. We have the octahedron, different types of primitives. So what I would just need to do, let me maybe let's keep this as an example. Let's select all of these node and create an box around it by clicking this option that will create this box. Now I can easily move this. So now let's place this in here and to actually incorporate this into this geometry library, as you know, we need to create the attribute first. So I'm going to copy this my attribute, connect this in here, and I'm going to call anything. We don't need to I'm going to top just random numbers. Just connect this in here. Now it will automatically get copied onto these points because of this attribute from pieces, and we should start to see the platonic, and here we have it. We are in here creating these name attributes manually, but we can actually create these attributes automatically as well. If you do not want to every time create these attributes by your hand, you can actually automate this process as well. So let's see how we can do that. And for that, I'm going to just duplicate this whole setup by selecting all of these nodes, present hold the old key and drag. For this one, I'm going to just remove these attribute create nodes because I don't want to manually create these attributes. In here, to actually automatically create this, we have a node called connectivity. So if I add an connectivity node in here, so let me find here we have the connectivity. If I connect this, what this node will do, it will look for the connectivity of the points. Here as can see, we have the connectivity type for the points or we can define the primitives. And it will assign them an unique value. So right now we are creating an attribute class. I I middle mouse button, and Heres can see, we have the attribute name class. So the box geometry is an A one connected piece of geometry, and I can confirm if I enable my selection tool and double click and heres can see, that is a one connected piece of geometry. I can go into the sphere. And that is one piece of geometry. And if I go into my rubber toy and double click. And here we have some multiple pieces of connected geometry. So that will create some problem, but we will see. So here as you can see, we have multiple pieces of connected geometries, which mean that they will get their own unique values. But the platonic one, let me select this node. So the node must be selected. Otherwise, the view board will template your currently selected node because right now the roboto is selected. That is why we have this wireframe of this geometry. So you must need to select this onto the node editor as well. And here you can see we have this one connected piece of geometry. First, I'm going to just remove this and we will take a look at how we can fix this one problem. But now to make this simple, we have these three connected pieces of geometry. By using the connectivity node, it will look for the connectivity and assign them a unique value. Right now we are creating an integer attribute. We can create a string. I I mouse button, hers can see now we have class and we have three values. I can go into the geometry spreadsheet and it's actually creating an a primitive attribute, let's go in here. Hers can see we have this one P zero and one, two. We can actually keep this to integer as well. That will work also. And here as you can see, we have this value from zero, one, two. So all of them will get an unique value based on their connectivity. So now, I just need to connect this in here. There we have the geometry library, and that should be this newly copy to points node. I just need to tell onto the attribute from pieces node that now my geo attribute is no longer exist, but now look for the class attribute instead. Let's go into the attribute from pieces, and in here, I'm going to type the class attribute, and if I enable the copy to points, and it's not working because I think we need to create an a point attribute. So right now it is an A primitive, so we need to change these two point oh and let me see. Actually, it was not working because we forgot to tell in here because the copy to points node is still using my geo attribute. So we need to tell this class and hers can see we are copying all of these geometries. So which means I can keep adding more geometry. And if I were to add this one because it has multiple pieces, we should get multiple pieces copied. So let's check. Let's connect this and connect this and hers can see we have all of these pieces copied randomly. We can change their distribution by going on to the attribute from pieces and in hair. Right now, the mode is set to cycle. We can change this to patch. Maybe let's explore this further in the next lesson because I think the time is over for this class. So let's take a look at this in the next lesson. 14. 14 Packed Primitives: Now let's talk about pack primitive, and let's further explore copying the geometry inside of Fudini. And right now, hers can see we are facing the problem where we have this geometry that is made out of multiple connected pieces of geometry. And I want to copy this geometry in here as an a whole and not as its connected individual pieces. So the way we can solve this, we can either create an A manual attribute in here. So I'm going to create an A maybe attribute, create node in here. And I'm going to manually create our class attribute. So let me see onto the connectivity what we are creating. We are creating and looking for the point, and it should have an a point attribute class integer. So what I can do, I can go into this class one in here. And by the way, it does not matter if you create an a point or primitive attribute. So right now we are using the class integer as an a point attribute. I can change this to primitive, and if I middle mouse button and Hearers can see, now we are creating the class as an A integer attribute, and the other one, the class, this point attribute is actually coming from this one in here. So if I were to shake this node off and if I middle mouse button and Hears can see, we no longer have the class on the point level, but we only have the class onto the primitive level, and it is an A integer. So when we are going to use this attribute from pieces node, it will look for the either point or primitive and it will store the attribute for us. And here is can see, we have the class as an integer, and the copy two point node will work. And here is can see it's working just fine. It's understand both point as well as the primitive attribute, this attribute from is node, and also it understand both integer as well as the string. So if you create an a string, it's also fine. If I middle mouse button, hers can see. Now we are creating an class, and now it's an string, and it is working fine. So it's up to you if you want to use this string or integer. I'm just keeping this as default, all of these settings to default. So these are the default setting that came with the connectivity. The default setting is that we have an A primitive attribute class, and it's an A integer. I'm going to create my own attribute onto this one, and I'm going to create an primitive. And for this one, it's an at type. Let's change this to integer, and I'm going to assign my own value 45 maybe. And heres can see we are creating this one, this attribute, but now connectivity will override this because it look for the connectivity and assign its own value. So that is why this method is actually not working. So what we can do, we can actually pack our geometry. So the one way we can solve this is to pack our geometry. If I were to tap pack node in here, let's add this and let's connect this in here and the result. So now what the pack node will does, it will pack our geometry into one point. If I middle mouse button, here as can see now I only have one point and one primitive. And it is an A packed primitive geometry. And down here, we can see we have the packed geometries. Right now, we only have one pack geometry. So now it's an A one single point, which means now I cannot access its individual primitive. If I were to select enable my selection tool and heres can see, I can select this as an A hole. And right now, I currently have turned off the selection constraint, and heres can see these constraints are off. And I do not have access to the individual primitives. And if I want to access the individual primitives, I need to unpack this. So let's add an unpack node, and we also have an node on pack for unpacking the pack geometry. And now heroes can see I have access back to all of my points and primitives. Now I can enable my selection tool, and now I can select all of these primitives. And if I want to select the points, I can. That's what we are doing. We are packing our geometry into one single point. So it's a point, single point, and Houdini knows how to draw this as our original geometry. And it is a much efficient way of working when you are working copying your geometry. And hers can see, we can see that into my RAM, I'm only storing 3.16 kilobytes. And if I were to take a look my original geometry and middle mouse button, and heroes can see, I am now storing 2 megabytes. So it will add up. So when I were to, let's say, just copy this in here onto the copy the points, and I'm only just connecting this into the connectivity, maybe let's not put this into the connectivity, but connect this directly. I'm just let me see why it's not refreshing. That is the geometry. I think we need to put this into in here. So now we have all of these rubber to geometries copying. And if I were to middle mouse button and here as you can see, now we are copying 48 megabytes into my RAM. And it will add up if I were to increase the number of points. As number of copies will get increased, my Houdini session will get slow and slow. And if I middle mouse button, and here as can see now we are on 270 megabytes, it will adding up. So if I were to pack this geometry, if I connect this, so now we are packing this into one single piece of point. Okay, we have one point, and now we have 3 kilobytes of memory. And now if I were to view this onto the copy do points and view this and hers can see now we are down to only 381 kilobytes, and it is much more efficient to work with. So it is always recommended to pack your geometry whenever you are working with these whenever you are instancing your geometry. You can always have access to your original geometry. But after that, you can add the unpack node. If any reason you need to access your primitives, you can unpack after them, and here as you can see, we will have our original geometry back. That's what the PAC primitives are and you can learn more about them if I add the pack node in here and let's click on this mark in this button that will open up the help page of this node. And here we have the pack geometry, and you can scroll down in here, and it is explained all of these things in much more detail. And I actually encourage you to take a look at this help documentation to learn more about them. And it's very well explained in here. So that's what the packed primitives are, and that's what we are going to do. We are going to pack our geometry first into single point. So now I'm going to just connect this in here. So let me rearrange this node graph. And let's connect this in here. And now because we only have one point, now the connectivity sub should not create any problems because now we only have one piece of geometry. So onto the connectivity, we should get everything correct. Let me remove this. And now I'm going to connect this. That is our geometry library, and we have all of these settings correct. We just need to plug this in here and view this. And now, hers can see I have all of these geometries copied correctly. Now I can play around with these settings. And now I can just keep adding more geometries. Let's say I want to add squab in here. So let's add an squab and it to should have multiple pieces of connected geometry. So I just need to add an APAC node in here and let's connect this and connect this into the merge, and it should be in our system. And here as you can see, we have our scab, and maybe let's go into the add this shader as well. And we also have our pighead geometry. So let me add this. And it to have a multiple pieces of geometry. So let's add an APAC node in here. And connect the back node and let me move this aside and make this network in here. Let me rearrange these nodes because it's getting messy, move them up, move them into the side, move this onto this side, and connect this into the merge. And now we should have our big head in our stream as well. So that's how you can copy multiple geometries. I can increase the number of points in here. And right now onto the attribute from pieces, heros can see we have different types of modes. The mode is right now set to patch, which means it will creating the patch pattern. I can define the patch size in here, and heros can see we have this patch the way it will distributing the attribute, or I can change this to cycle and it will cycle all of the geometry, which means if I were to reduce the number of points, we should cycle through. So this mode is pretty simple. We have this one option patch to create the patch, and we also have the option to noise. And onto the noise, we can define the element size to create different noise pattern, and it will be more visible if we have more points. And here we can define the element size. So that's the noise base distribution. And we also have some other option. We have the random. That is the random distribution. That's the attribute from PCs node. 15. 15 Copies Orientation: Now let's take a look at the orientation of our instances. When we are going to copy our geometry, so let's see how we will deal with the orientation of these clones. In here, I'm going to create an A geometry node, and let's dive inside. And in here, first, I'm going to create a simple maybe platonic solid. Let's add this and let's go into the platonic solid. Here we have the solid type. In here, let's like the Utah tree pot. So here we have this lovely pot geometry. And first, I would like to align make my geometry to sit onto the floor. And right now here as you can see my geometry is not sitting onto the floor. And for that, I can either change here onto this position value and let me adjust this parameter, and I can go into some of the side view. So let's go into the perspective and let me change this to right view. And in here, I can play around with this position until I have my model sit onto the floor. Now I can go into the perspective view. Or we have a node called match size. So let's add an A match size node, and let me bring this position value to the default. Let's change this to zero. And onto the match size, we have some of the alignment options. So let's connect this and let's bring up the parameter of the match size, and here we have this justification. And in here, we have the justification for the X, Y, and Z, and right now they are set to center. And because I want to make this geometry sit onto the floor, I need to play around with the justification of the Y because Y is our up axis. So onto the justification, Y if Y change this to minimum, it will take a look at this bounding box geometry. Here as you can see, we have this bounding box. That is the bounding box for this current geometry. It will use the minimum size of the bounding box, which is its very last disposition and align this onto the origin 00. That way, we have our geometry sitting onto the floor accurately and procedurally, which means I can put any geometry in here. For example, if I were to create an A, we have this character geometry. Let me go back. I accidentally dive inside of this node, and let's view this right now, it's actually sitting onto the floor. B, let's explore another geometry. Let's add an rubber toy and let me view this. So I think that one is not sitting onto the floor. So in here, I can just add an A match size node and let me connect this onto the justification Y and here as can see right now, it has been moved to center. Can change this to minimum and Hearers can see now it will sit perfectly onto the floor. Or I can just go back in here and I can just play around with its positions, and now hers can see itsnd onto the floor. I'm going to just duplicate this match size, press, hold the old key and drag, now let's connect this in here. And now we should have our guy sitting onto the floor. That is a very useful node for aligning your geometry. And onto the mesh size, we also have the alignment onto the justification X as well as Z, which means I can just play around with its position. I can move this inhere somewhere in the three D space, and now I can go into the mash size, and it will bring our model back to the origin because of this justification X, o, center center and minimum. So all of these positions will be replaced with this our origin. So let me remove all of them. That was the match size to make this model sit onto the floor. And now let's create a sphere geometry in here. I'm going to create a polygonal sphere, and maybe let's increase the radius of our sphere. And I'm also going to lower down the number of points to create less copies. Now I can use the copy points node to copy to geometry onto these fair points. So here we have the geometry to copy, and we have the points to copy. Let's view this. And Heres can see, we have some alignment, okay? So we are getting some alignment. Let me and Heres can see right now, our viewport is working slow. And that is because currently we are not working with pack geometry. And to actually pack your instances, we also have the option onto the copy points node, I enable my parameter of the coopt points node, and here as you can see, we have this option to enable pack and instances. So let's enable this. And by enabling this, we are effectively packing our geometry. Now we are packing, it will be much easier to work. And here as can see my viewport is now working freely, so we have a lot less load, which means I can go in here and let's continue increasing the size. And heres can see we have some alignments, right? The way that copy to points node is actually aligning our geometry, it's aligning them by using the normals. Okay? So if I press and hold the middle mouse button, and hers can see in here, we do not have an A attribute N which stores the normal. But still, we have the orientation, and that is because of these primitives. We do not have a normal attribute inhere as an a point or primitive attribute, but we actually do have some primitive normals because of this shading. I can view them, but if I come over here, we have this option display primitive normal. If I enable this and heres can see, we have these lines. These are the primitive normals. So these normals are intrinsically calculated by the Houdini to actually correctly shade sphere geometry. Copied points node is using these normals. These intrinsic normals to align them. If I were to remove these normals, I can do so by adding an extract all points. If I add an extract all point node in here and just extract the points. Now because we do not have geometry, Houdini will not calculate the primitive normals because we do not have any primitives. We just only have points, we do not have. And we also do not have point normals because we are not storing them as an AN attribute, which means that there is no normal information. We only have just the point positions. If I now view the result at the copied points, and now as you can see, we do not have any orientation. They are just following the same orientation as we have our geometry in the origin. And here you can see we are just taking this geometry and just placing our geometry wherever all of these points are, which means I can just add an transform node in here and I can by using the transform, I can rotate my geometry in whichever way I like. And our copied points node will just take the position, the rotation and orientation and place them onto these points. And I can check into the copied points, and now heros can see we have all of these same rotation. Let me play around with the rotation value. So they are not aligning. They're not aligning accurately with the topology of our, let's say, the sphere. So the way we can do this either by keeping this as an A geometry, because when we have the geometry, we have these primitive normals and COVID points node will use these normals to assign them. But sometimes we just need to we have an A points as an A input. In here, we have these points, and I do not have any normals. And the case would be if I were to add an A, let's say, scatter node. So what will the scatter node will does? It will just scatter some points onto the input geometry. Here we have the sphere. And if I connect this and result and here is can see, we have scattered some points. I can enable the parameter, and here we have the option to adjust how many points we want to see. And where we have the relax iteration. So relax iteration means that all of these points should not intersect or get close to each other. I can uncheck this option and here us can see because we do not have any relaxation, now we have these clumpy looking particles. So they are randomly distributed onto the surface. I can change the global seed that will just adjust the seed where all of these our points are. Scan node will just scatter a bunch of points onto your input geometry. I input I can put any geometry in here, let's say, if I were to add an bot geometry in here. And right now here is can see, we have the regular arrangement of these points because of the flow of our geometry. I can just add an scatter node in here. Scatter node will just look at the surface as a whole and just scatter a bunch of points in there. And here is can see have these points and I can adjust how many points I want. And into these scatter points, Hers can see, we do not have information. We have the normals N, if I enable and Hers can see on this skater node, we do getting normal, and that is because if the input geometry has normals, if I middle mouse button, Hears can see, we have the normal N as an A attribute. If we have the N as an A attribute on the input geometry, the scatter node will inherit them. So if you scatter, it will inherit the normals, and that is why we are getting the normals. So if I were to remove this attribute, if I add an attribute lead node and connect this and onto the attribute lead, let's click lead non selected to remove all of the attributes. Okay. So all of the attributes are gone and N is also gone, which means now the scatter node should not inherit. So if I enable my point display, and for some reason, it's still showing me that, let me remove this and let's create another scatter node in here. Maybe that was because I think it was cached and heroes can see, we do not have any normals. So I can play around with the settings. I can uncheck the relaxed iteration. I'm currently viewing these normals and heroes can see, we do not have normals. And I can also check if I press and hold the middle mouse, but on heroes can see, we do not have an AN attribute. And if I were to create an a normal I can create this and here as you can see, we do not have normals. After the attribute let node, I can add normal node in here and connect this in there, and it will create an a vertex attribute normal. I can go into the normal node and onto the add normals, I can change these two points. And now we should have an A N as an A point attribute. And now I can view my display normals and hers can see we have these point normals, which means now that the scatter node will inherit them. So onto the scatter, if I enable my point normals and here is can see we have these normals. So onto this extract all points, let's come into this original example. We do not have normals, which means copy to points node has no way of aligning the geometry because it looks for the normals. If normals exist on this side of the geometry, it will align the geometry onto these normals. Let me enable copy to points, and we do not have any orientation. And one way we can solve this by adding an a normal inhere, so I can add a normal node, connect this and change these two points so that we have an a normal as a point attribute. And now here I can enable my point normal by clicking on these display normals, and the point normals are not the same as primitive normals, so we have normals on the primitive level, so these are the primitive normals, and these are the point normals and here is can see. Wherever we have these points, we have the normals. That is because we are creating the normal as an A point attribute by using this normal node. So which means if I do the extract L points, we should have normals, and sure enough, we have the normals after we have extracted the points. And now we should get our orientation back. I I enable copy the points node and Hers can see. Now we have our orientation. If I were to bypass this node and hers can see, we have the orientation. The way that it is aligning our geometry onto these normals, if I enable this, we have these normals. So the way that the capito points node will align them by looking at the Z axis. If I go into the platonic solid or maybe into the match size and let me hide by these normals, and it will look for the Z axis of the geometry. And right now, here we have this very small mon. Let me make this Gnomon size bigger or maybe add an origin nomon If I click on this display option, let me bring up the display option for the viewport. Let's go into the guides, and here we have the option to enable the origin nomen. So if I enable this and right now I cannot see my origin nomen because the nomen size is too small, so I can scale my origin non bigger. Let me find here we have the origin nomen size. Let's increase this, and maybe let's continue increasing the size. And there you go. We have these nomens. We have these ZX, X xs, and the YXs. Or I can just make this gnomon bigger by coming on into the let's say, origin nomen and floating gnomon. Okay. That was the Gnomon right here. Let me uncheck this origin nomon and make this floating nomen size a bit bigger. So let's continue increasing this. Continue increasing this. Okay. So here we have the floating Noman size. Okay, right now, I'm just setting this to this value. Here we have the Z axis, X axis and Y axis. So what it will do, it will look for the Z axis. Right now, our front facing that is the direction I'm calling this the front face where we have this drain pipe that is the front face. And right now it is aligned to X axis, and here as can see. And if I were to rotate this and align this onto the Z axis, so let's do this by going onto the transform node and let me zero out all of these rotation Okay, let's rotate this around the Y axis. So that is the Y. Let's rotate this onto the -90 degrees. -90 degrees. And let me move this, rotate this now hers can see how this front pipe is aligned to the Z axis. And now it will use this Z axis to align our geometry onto these normals. Let me enable M point normals and heros can see we have these directions. So these directions basically represents the Z axis, which means now my geometry, this front face, let me hide this. Is front side should align to these guys, these normals. And I can check by going onto the copitPoints and view, and hers can see we have the front face facing on where we have these normals. And I can make this. I can change this. For example, I can make this where we have the handle as front size. So what I can do, I can just continue adjusting with my rotation and maybe rotate this to, I think, -260 degrees so now that axis should be aligned with the normals. Now if I go into the copito points, and here us can see now we have the handle aligned to our these normals, and the front pipe is now gone reverse. That's how the copito points node will actually align your geometry. It will look for these normals onto these scattered points onto this side. And if the normals exist, it will use these normals to align your geometry. So in the next lesson, let's take a look at the scatter and align node to further explore these instancing aligning 16. 16 Scatter And Align: Now let's take a look at the scatter and align node to align these clones. Here I have opened up this previous scene where we were working with these normals for the alignment, and Hees can see we can create the normals for the alignment, and now if I were to adjust my rotation of these guys, I can go into the transform node and I can just continue playing around with this by adjusting this one, I can adjust the rotation globally and heres can see by playing around with the rotation, I can rotate all of my clones. But what if I were to only rotate a certain clone, not all geometry, or how we can have more control over these orientations. So the one way we can do that by adding an a com node, which means that adjust these normals because we know that these normals are responsible for our alignment. Can do so by adding an A, let's say attribute, randomized node, if I add an attribute, randomize and let's connect this after that. And as you know, by default, it will randomize the CD. But for this time, I want to randomize these normals, this N. I can I only just need to replace the attribute name because we know that N is called the normal, so it is an A N. Remember that it is case sensitive. So N and the lower case N are not the same attributes. Okay? These are two different attributes. You must pay attention to the cases. N is the normal that stored the normals, and here is can see whenever I type the N, and we have these normals oriented in random directions, and I can play around. Here we have the dimension. It is set to three, which is an correct dimension because it has three values. It has X, Y, and Z components, so that is correct. Has some other option. I can change this to direction or orientation. So the dimension is I can play around with the cone angle, and here we have the bias direction. So the bias will bias the alignment onto these axes. Here, I can define the direction. I can bias them toward my Y axis. Let's zero out the X, and now they should lean toward the Y by playing around with this bias option, play around with the cone. And now if I were to enable my copy to points, and let's go into the attribute, randomize node and play around with these settings, and here as can see I can randomly orient these copies. I also have some option for the inside sphere. All of these different option to randomizing our copies. Zero it out, totally random orientation on each of these copies. How you can randomize your rotation and we also have a node called com if I type com in here, that is the node. Let's connect this. What com node will do, let me view view this node com when the node is selected, just select the node in the node editor and hover over to the viewport and press Enter, and that will enable our manipulator, which means I can use the brush, and right now I cannot see my brush. Let's increase the radius of our brush to a bigger value. And right now, I cannot adjust them maybe because of the points are small. So what I can do, I can just remove the extract all points. Okay, we don't need that. And onto the sphere, let's maybe increase the number of copies. And now let's press Enter and here as you can see, let me enable my point normal display and let me increase the radius. Sorry, we were actually accidentally, I'm changing the UV radius. So that is not the radius, the radius. We need to play around with this value. Okay? And Harris can see now my radius is getting bigger. I was playing around with the wrong parameter. And Harris can see I can use the com node to manually just align orient my normals. And by doing so, let me go into the copy to points node. And here you can see I can effectively what I'm doing, I'm just adjusting the orientation. So when the node is selected, we just need to highlight the node, just highlight the com node, press H to the viewport and press Enter. Now that we have the manipulator, I can interactively come over here and I can play around with these normals. And maybe let's decrease the number of points. And now we need to highlight the node to have its manipulator. I can manually play around with this. And that is one way of controlling your orientations. And we also have another node called scatter and align. If I add an a scatter type scatter and align, and here is can see, we have these two node, the scatter and scatter and align. The scatter node is just simple. It will just scatter some points onto your input geom tree. It will not create any additional attribute. If there is an normal, it will inherit them. As Heras can see, we have the normal and the normals exist, it will inherit them, but it will not create normals for us. I will just scatter the points and here I can define how many points I like. But onto the scatter line, we have some more advanced options. So let me remove all of these two nodes. We don't need the normals, or maybe let me create another example onto this side in here. Let's keep this as is. And in here, I'm going to create another sphere geometry. So let's create an polygonal sphere. Let's adjust the radius. And in here, I can only I can connect this scatter to the surface. And in here, we have quite a lot of options for dealing with the alignment. So at the first, we have the option for the coverage. So how much area of the surface it will coverage to scatter the points. I can enable the coverage to all the way up to one, which means use all of the available surface, or I can lower down the surface area. And right now the point count method is set to size, which means it look for the size. We have the minimum and maximum radius. So it will scatter points in between min and max radius. And if I play around with the Min and max radius value, heroes can see, I can create more or less points. And these points have some attributes that copy to points not understand. Five or two middle mouse button, and here as can see we are creating quite a lot attribute. We are creating the normals. We are creating this orient attribute. It is a four float quaternion, and we also have another attribute called P scale to set the scaling. This node will actually creating more attribute. And we can check all of these attribute. If I create a copy to points node, let me create copy to points, and in here, I'm going to create an platonic solid. Another time change this to Utah TPOt, connect this, and maybe let's enable the PAC instance and connect this. These are our points, and let's view the result. And Hearers can see. We have these orientation, and we also adjusting the scale. If I were go into the skater and align node and play around with these points, and Hearers can see, as I am creating less point, we have less of these copies, we have the scale, okay? Some of the pots are bigger and some of the pots are smaller. And let me hide the wireframe by coming over hair and change this to smooth shaded, so we don't have this ugly wireframe. And here's can see we are adjusting the scale as well, and that is because onto the caterinlge we have the attribute P scale. So the P scale is the attribute that copito points not understand to set the scale. So if I were to remove the P scale attribute, and I can do so by adding either an attribute lead node, I can add this and connect this in here. And in here, I'm going to specifically say that I want to remove the P scale attribute. And now, because we do not have P scale attribute, now we have the uniform scale, which means the original scale that is coming from this geometry. That is the P scale. P scale is the attribute that copied points node understand. Let me remove this attribute let node, and I can also turn off this P scale if I go into this cat and align and onto the attribute stab, Heros can see we have this radius attribute. I can uncheck this, and that will just remove the P scale attribute. And now, because we do not have P scale, we are using the same uniform scale that is coming from the original geometry. I can create my own random P scale. If I don't want this P scale that is coming from this catern line, I can do so by adding an A attribute, randomized node, and in here, I just need to type the attribute. I want to create an A random P scale attribute, and P scale is an float value. It has a one value, so let's change the dimension to one. And let's connect this. And here is can see as soon as I connected this node, we have some random scaling going on. And go into the randomization. I can change the distribution to maybe an A custom ramp. And now I can play around with the am to play around with the scaling. Here we have the minimum scale, and we have the maximum scale. Let's play around with them and set the scaling. That is the P scale attribute. Let me remove this. And onto the scattern align, we have this method for generating these points by using this size method, or I can change the point count method to by density. And in here, I can adjust how dense I want or these clones. I can just play around with this density value to create more or less my these copies. Or I can just change these to number of points. We also have the option for by point spacing. It will place the points in that space. So if I enable my scatter on line node and let's view this point, it will look for the spacing between, let's say we have this point and that is the point, I will look for the spacing. So if the spacing is 0.73, it will add another point and add another point. And if I were to decrease the spacing by decreasing the spacing, we are effectively generating more points. We also have the option to just explicitly tell how many points we want. Here, we can just type that I only want, let's say, I want the point of 42 42 number of points. I can just say that and if I were to enable and here can see, we have 42 number of points. These are the different methods that you can scatter some points. I can view results and we should have 42 number of these T pots geometry. And they will be aligned. We also have the option for the alignment in here. If I go into the scatter and align node, and if I come over here, the first tab, that is the orientation, and that is the orientation here we can adjust the play around with the rotation, and here we have the rotation around normals. As you know, we are creating the normals and we can also rotate them, rotate these copies around the normals. I can define the minimum angle. I can define the maximum angle by adjusting the angle 0-360 degrees I can create a random rotation 0-360 degrees. So it might be better if we, I think, just create an A. Another example, so let me duplicate all of the setup, and in here, I'm going to just create a box in here or better maybe let's create something an roboto geometry. And let's connect this and let's copy this. And onto the sphere, I'm going to just make my overall scale a bit bigger onto the cobito points node. Sorry, not the copito points. We are generating the attributes on scatter and align. And here as can see I can play around with this option. And right now, all of them are perfectly aligned to the normals, so which means that their orientation would be aligned onto these normal or I can introduce some random rotation. Now they are rotating around normals. I can change this value to zero, 360 degrees to randomly align them. And here we can play around with the cone angle to add the rotation onto this angle in here as well. And we also have the option to enable the round to multiple, which means that let me zero the max rotation in here. So let's use the minimum angle of pick the value 0-360 degrees, but you are only allowed to, let's say, I want to allow them to take 45 degrees angle. So now they will only be taking 45 degrees steps in the zero and 360 degrees range. Or I can change this to 90 degrees and enable this. And now, here as you can see, we have these 90 degrees steps. I think it might be easier if I were just create another example. Let me duplicate this in here, and this time I'm going to add an A, sorry scattered line, we have that. This time, I'm going to input this geometry, grid geometry. Let's connect this and remove the sphere. So we are scattering them along the grid. And in here, maybe make the grid size a bit bigger by going in here. And here you can clearly see that we have the 90 degrees angles. So they are not in between 90 degrees. If I were to go into the scattern align node and zero out this one, round to multiple, maybe turn these settings off. And now hers can see they are allowed to take any rotation value, any arbitrary angle value 0-360 degrees. By enabling the round, I can just limit the rotation. Let's say, if I change this to 90 and Hears can see we have this regular orientation of these 90 degrees. So that's what this option is. I can uncheck this. And by doing the scatter align, we have these alignment options. But here as can see we are actually scattering the points. For example, in here, we have this surface, and we have the regular arrangement of these points. And the scatter and align will just using the surface to scatter the points. I can go into the scatter and align, and I can define how many points I want. I can adjust the global seed. It will randomly place these points, and we also have some of these relaxation going on, and I can actually adjust the relaxation by going on to the point generation. And here you can see, we have the relax iteration if I were to zero this out. And now we have these complete random distribution of these scattered points. And here I can define how many points I like. And this will add the orientation and all of these attributes. But what if that I like the arrangement of these points, okay? My input geometry points. I have these regular arrangements, and if I were to create a sphere geometry, let's say we have this sphere, and I like these arrangement. I like these points, and I don't want to scatter the points because we know that if I were to connect this, it will use the surface and newly create point, it will scatter the points and add the attributes. What if I don't want that? I only want I want these points, but I want them to have control on the rotation onto these normal rotation. I just only want to add some attributes. So I can also do so if I were to copy this or maybe copy all of the setup. Let me duplicate this. And this time, I'm going to just remove this and connect this into this point. And in here, I'm going to say that scatter, do not scatter new points. Just use the points that are coming into your input geometry into this geometry and just add some attributes. I can do so onto the scattern align, we have this option that is called the mode. Right now it's set to scatter points on geometry, and we also have the option to add attributes to existing point cloud. If I choose this, which means that it will now this node will only create attribute and do not scatter the points. And for this option to work and heroes can see, even though we have the mode set to add attribute to existing point cloud, we are still creating this. We're still scattering the points. And to actually add the attribute, we need to connect this onto the second input. That input for the scattering and heroes can see if I have over, it is required for the scattering scattered surface, but I want to add the attribute, which means I need to connect the second input. So let's connect this and now it is throwing an over and warning, but that's fine. If I middle mouse button here as can see we have these attributes and the normals and position. The orient is an attribute that Copy du points node will look for orienting these copies, which means now I can go into the Copy DPoints node. And now I can play around with these rows and columns to create more or less copies. I'm just creating less copies. Let me go into the test geometry and maybe lower down the overall scale and also make my radius a bit bigger, let's make this scale a bit larger. So now we are using these points, these same points that we have. I can play around with this to create more or less points. Now I'm using these points. I'm just using this catern line to create these rotation attributes. I can go into the copied points, and here as you can see, we have the alignments and go into the eternal line, I can play around with these angles, and we have all of these rotation controls. I can also enable my P scale. I can enable the radius attribute, and now I can play around with these radius min and max radius values to set my P scaling of my copies. Or if I don't want to, I can just uncheck the radius and only apply the rotation and orientation. And after that, I can use the attribute randomized node to create my own random P scale value. So that's type A P scale. Now I can use any of these distribution method to create my own custom random P scale value. So that's how you can align your clones, align your copy to points geometry. 17. 17 Intro to VEX And VOPS: Now let's talk about x and ops. X is a Houdini native scripting language. It's x means the vector expression language. Let's see how we can write some codes inside of Houdini. So in here, let's create an A jump to node, and let's dive inside. And in here, x comes in two flavors. We have this pure vax code, and you can write the pure ax code by using this attribute wrangle node. So let's add an A attribute wrangle node. If I enable the parameter and here as can see onto the x expression, here we can start writing our own vax code. We also have node called attribute wop. Let me create an attribute Wop node in here, and that is this attribute wop node is used for the node based scripting. It's a visual scripting. And we can do so we need to dive inside. It is another context of Houdini, the b context. Okay. So right now, hers can see we are at the geometry level, which means we are in the sap context. And to access these nodes, we need to dive inside this. So I can press Enter to dive inside, and Hears can see we are in the ax Builder context. And in the ax Builder, here we can lay down nodes and start scripting our program. And if I enable by this node menu, Heres can see, we have this node menu different. And it's the same wax builder context that we have in the material context because the wax is an a shading language. Originally, it was built for building the shaders. So which means I can create a principal shader in he. If I create a principal shader and heres can see, we have an a shader. And that is because it was originally built for the shading. So let me remove this. We're not going to build shader in the attribute wb, but I just added the principal shader to let you know that we are in the same context. Okay? So let me remove this. And when we dive inside the attribute wb, we have these two nodes. We have this geometry wb global and we have this geometry b output. So the geometry global is we have some of these attributes imported for us, and I will explain all of you in a minute. First, let's maybe remove both of them. So now we have this empty wax builder. We can go back. Here we are in the attribute wop node, and we can dive inside. It's nothing here. And we have this way writing our own pure wax code by using the attribute wrangle. So first, let me create an sphere node in here. I'm going to create this polygonal sphere. That is a very basic type of geometry if I middle mouse button. And currently, we do not have any attributes. We have the P to store the position of these points to make this sphere. Okay, we always have P. But other than that, we do not have any attributes. We can create the attribute. We know that by using the attribute create node, if I add an attribute create node, I can connect this and we know that we can type the name of the attribute and class where we want to store and the type and all of these things. Now, let's see how we can create the attribute using the ax method. So first, I'm going to connect the attribute b node. So we have multiple inputs, and we will take a look at that why do we have all of these inputs. But first, I'm going to just plug this into the very first input of the attribute b, and we need to view the result of this attribute b and to actually start writing our code, our node based scripting, we need to dive inside this. Double click and here as you can see, we have this empty, this wax builder. And in here, first, I want to create the attribute. And the way that we can create the attribute by using the bind export node. So here I can type the bind export. Here is you can see, we have these two node, we have the bind and bind export node. Bin node is used to import the attribute and bind export is used to export the attribute because we want to create the attribute, so let's add a bind export node. Let me enable the parameter. And here we can define the name of our attribute that we want to create. I'm going to rename this our M attrib my attribute and here we can define what are the data type that we are going to store. Okay? So my attribute is a float or it's a vector string, and you can change the type by clicking here, and here as you can see we have quite a lot of types. So first, we have the float integer, and we have some other datatypes, and we have the vector, and we have the color, which is also an A vector. But right now we are just creating an a float attribute, and in here, we have the default values. So the default value right now is zero. So let's maybe keep the zero. And now we can go back. And in here, if I press and hold the middle mouse button and hers can see the attribute is not there. And that is because we need to dive inside and onto my attribute, and onto the parameter, here it says, export when input is connected. So it means that it says that it will only export the attribute when this node is connected. This input, it expecting the input. But right now, currently, we do not have an A input. If I want to use this value, I can say onto the export, I can change these two always, which means that no matter if this input is connected or not, you are just responsible for exporting the attribute. So now we should be able to see attribute. If I press and hold the middle mouse button, and Hers can see we have M attrib and it is an A float attribute. Its value is right now is zero. We can check. We can go into the geometry spreadsheet. And here we have the M attribe and its current value is zero. I can change this to any value, maybe let's change this to seven and Hers can see we have the attribe. I can change the type, I can change this to integer. Now we have these integer values, and here can see as I am changing this, my attribute is corresponding. I can change this two string. Let me find where is the string. So here we have the string, which means I can type anything, let's say, halo word. And heroes can see we have our halo word attribute as an string. Let me change this back to float and in here, let's go back. And right now, heroes can see we are creating an a point attribute. What if I want to create an a primitive or a vertex attribute? How we can do that? We can do this if we enable the parameter of this attribute b and Hears can see we have this runover. Right now we are running this attribute wb onto the points. Which means everything that we are going to do in here, whatever the codes that we are going to write, these nodes we are going to add, they will operate on points. So if I were to play around with my primitives, or I can create an primitive attribute, I just need to go into the runover and change these to primitives. And now I should have an A primitive attribute. So if I press and hold the middle mouse button, and here as can see now we have an primitive attribute, and it is my attribute that is the name of our attribute. And same way, I can change this to retail, and now I should see an A one detail attribute. So that's the runover method. I'm going to change these two points, the default. And now let's see how we can create the same attribute with this attribute wrangle method. So let me connect this and in here, let me view the result of the attribute wrangle and let's bring up the parameter. And in here, the way that we can create the attribute, we need to learn the syntax of the programming language of the ax. So the syntax of creating the attribute is that first, you need to define the data types. So what kind of data type that we are going to store. So we know that we have the data type float. So let me open the notepad in here. We know that currently we were working with these data types. We have float and the integer, and we have the string, and we have the vector. These are the four basic data types that we have worked so far. So let's see how we can create all of these datatypes attributes. So the way that we can do that, first, we need to define the data types. And for the float, we just need to type F. F means that that is an A float data type. And now in here, we need to tell that we want to create an A attribute, and for that, we need to create an A adsign. So the add sign will tell that we are going to create an A float attribute. The first F means the data type, the at mean the attribute, and now we need to set the name of the attribute that we want to create. And I want to create my attribe name, so I just need to type the name. So I'm going to type my underscore attrib. We have first part of the syntax. We have the data type float and at mean the attribute, and after that, the name of the attribute. Now we have the name of the attribute. And now we need to say the equal. Now we need to put some values in here. I want to say that this my attribute, and that is equal to, we need to set the value. For example, I want to stay number, save the value of 45. Now that I want the M attribute value to be the 45 and to end the argument, we need to add the semiclum. So the semicolon means that now this argument has been ended at this point. And now if I click anywhere in here and now I have created an Amy atrib. So I can check if I press and hold the middle mouse button, and heros can see, we have the Matrib and its data type is flowed because we had to find in here and its value should be 45. We can check. Let's let the attribute wrangle and go into the geometry spreadsheet and hers can see the M attrib and its value is 45. I can change this value to anything, so let's maybe change this to seven and click and Heres can see now we have the M attribute and its value is seven. That's how you can create your own attribute by using the pure vax code. And if you want to same way create an A, let's say, integer attribute, you just need to type I. Now, I mean that I'm going to create an integer attribute and now the add sign. After that, the name of the attribute. And I'm going to calling this one maybe my Int. So let's type. This time, I'm going to create another attribute that is named Mint. And same way, we need to create an equal, so we need to assign some values, put some values in this attribute, and I'm going to put anything value maybe 78 and to end the argument at the semiclumn just click in here. And now we should see two attributes. If I press and hold the middle mouse button, and Hers can see, we have Mattib, it's an a float and we have Mint, and it's an A integer. I can go and check, and Hears can see M attrib is a float. I can tell because we have 7.0 in here, we do not have the fractional part, it's a whole number. It's an integer. Same way, if I want to create a vector attribute, I just need to type V lowercase V. We mean we are defining the data type. So datatype is vector, so after that, add sine and I'm going to calling this one to be my vector. Now we need to assign some values. And because it is an a vector, we need to add this in these braces because it has three values, so it should be in these braces. So first, we need to type the X value, the X value, I'm going to define the one and to separate the next value, which means the Y value, you need to add the column. And now the next value for the Y component, for the Y, I'm going to changing this to 15 and add another column for the third, the Z value. I'm going to change this to maybe a value of 98, and we need to end these braces. So now that we have the vector value inside of these braces, and we finally just need to end the argument. And we can end this by adding the semiclumn. Now a 5% hold the middle mouse button, heres can see we have the M vector, and it is an A three float. I can check. I can go into the geometry spreadsheet, and heres can see we have the Matter float and the integer, and here we have the vector. And it has three components, the zero, which mean the X and its value is one. And because we are set at this to one, the Y value, this second component is 15. Yes, we have 15 and the last Z 98, and we have the 98. And same way, if you want to create the string, we need to type the data type, for the data type for the string, we need to type the S, which means the string, and now the add sign, which means we want to create an attribute. Now the name of the attribute. I'm going to type this one my string. And now we need to assign, put some values. And for creating this string, we need to type the trouble colon sin. You can type double colon or single colon. Both of them will work. For this time, maybe I'm going to add in a single colon and I'm going to put in here hello space world and to actually end the value, we need to end this with another column we need to add the sorry, single column because we started with single colon. Now to actually end the argument at an a semicolon. And here, as you can see, we have the myString and it's hellowor. I can check, press and hold the middle mouse button. Here we have the float. Now we have this Mistring attribute, it's a string, and we have the vector. And if you want to create the primitive attribute, you just need to change this from runo from points to primitive, and now hers can see all of the attribute has been gone from the point level, and I can also check if I press and hold the middle mouse button, and now all of my four attribute has been shifted to the primitive level. I can check, go into the primitive, and here we have the attribute, my attrib which is the float, my integer, string, vector, it has three components. Same way, I can change this to detail and now I should have these detail, this attribute as an a detail attribute. So let me go back into the scene view. And if you hit tab and type and wrangle in here, and here as can see we have quite a lot of these wrangle. We have the attribute wrangle. We have this detail point primitive. Basically, all of them are these detail point and primitive are the same wrangle. They just their preset has been changed in here. They Runo method. So if I were to change this one, let's say primitive wrangle. Let me tie primitive wrangle. Here we have the primitive wrangle. Let's add this. So what basically that is, it's runover method has been changed to primitive. It's the same attribute wrangle node, and here as you can see it says attribute angle. I select this, it says attribute angle. You can create an attribute wrangle. And if you decide to run this or primitive, just change this to primitive or easier ways you can just type the primitive wrangle, and it is already set to primitive. So these are basically the instances of the same attribute wrangle node. And we also have the same instances for the b. So right now I have created this attribute b node. I can create an primitive b and here we have the primitive b if I add this. So basically, it's an attribute wb but it's run over set to primitive. And I also have the detail wop Hers can see detail wb and all of the wb. Basically, just run over method has been changed. So let me remove this and onto the attribute wop so whenever you are actually whether you write your own code if you prefer to write the code, or you just lay down nodes and create your own script with this visual way. It's called the visual scripting. It's basically the same thing. So under the hood, when you are creating the attribute wop and laying down these nodes, the hoodini will automatically write the ax code for you and you can view this code if you come over here onto the attribute b and right click, I can go into this view vax b option, and here is can see if we have the view vax code option. I can click and here is can see we are under the hood basically writing down our own vax code. So it's creating this export float M attrib and we are assigning the value of seven. It's actually the same. So which means it's just that you are laying down these nodes to actually write your ax code, okay? So Houdini is writing the ax code for you. You are just laying down these nodes. But end, it's the same thing. If you use the attribute wrangle, the only difference is how you are building your code. If you prefer to write your own pure ax code, you can use the attribute wrangle to write your own code, or you can just use the visual way of creating your own vax code and lay down the node, and Houdini will write your code for you. It's the same. So in the next lesson, let's further explore both of these nodes, and we will see where you should use the attribute wrangle or where you should use the attribute. 18. 18 When To Use VEX Over VOP: Now let's take a look at both of these guys a bit closely, and when should you use which? When should you write your own ax code or when should you create an attribute wop node and lay down nodes? First, let's go inside of the attribute Wop node. Here I have newly created my attribute Wop node, and right now it is empty. And first, let's create an A example. And I'm going to create an noise noise base attribute, and we will use this noise attribute to drive our extrusion. So first, maybe let's go onto the sphere, and onto this sphere, I'm going to change the this mesh type to polygons, sorry, not the primitive polygons. And that will just triangulate our sphere, and I can change the divisions by adjusting the frequency. By adjusting the frequency, I can create more or less these triangles to add more resolution, and that will just create a more interesting shape for the extrusion. So now let's go inside the attribute wop node and let's tie inside. And inhere, let's type noise. And if you type noise inhere, and here as you can see, we have a lot of these types of noise. So you can create any type of noise. We have this cellular noise, flow noise, periodic, and all of these noises. So I'm going to just add an anti alias noise in here. So let's add this. And in here, we have this noise nod. And we have some parameters. We have the signature. Right now, it says three D input and one D noise. So what that means, it means that we need to input the position as an A three D input for sampling the noise. It required the position at which position this node should sample the noise, and it will output an A one value. And here you can see if I hover over to the this output, these are the outputs. And here we have this noise and it is an A float. So it has an A one value. That is why it's a one D noise. I can change this to three D input and three D noise. Let's click on it. And now heres can see we have the anti alias noise, but now it is an A factor. So it has three components, X, Y, and Z. So let's change this to three D input and one D noise. And for sampling the noise, it required the position. We are going to put the point position so if you go back onto the sphere and here's can see we have these points and these points have their position in the three D space, and these positions are stored in attribute name called P, that is for the position. Now let's import this P inside of our attribute op node. And to actually import all of these attributes. So a pair, if you have any type of attribute and you want to import, I can go inside the attribute op node, and I can add an a point node. By using the bind node, I can import the attribute. Let's add this onto the bind node, let me bring up the parameter, and in here, we just need to type the name of the attribute. So the name that I want to import is called the P capital P. So we need to just type the name of the attribute and the data type. P is an a vector, so let's change this to vector. And now I can just plug this in here onto the position, and now the noise know at which position it should sample the noise, and it will output an a noise value. And we can actually visualize this noise as an a color. I'm going to write this into an a color diffuse attribute C because as you know, that CD is an attribute that wouldn't stand to set the color of these points. So I'm going to create a bind export node in hair. Let's add this, and I'm going to rename the attribute to CDC and lower KD, sorry, lower KD. And it is an a vector. So I'm going to change this to vector. I'm going to just plug this in here, and here as you can see, our spare color has been changed to an A tarcer value, let me hide my point display. And here we can start to see some pattern. Let's go into the t alist noise and in here, let's play around with these settings. At first, we have the three D frequency by adjusting the frequency, we can create high or low frequency noise. And in here, we have the offset. We can play around with the offset. We have the noise offset around the X and the Y, and Z, and we have the amplitude. If we increase the amplitude, here as you can see, our color is getting brighter, which means that our amplitude is high. And I can play around with this CD frequency to play around with this noise pattern. And right now this noise is looking very coarse, and that is because we are applying the noise onto our points. This resolution directly affects how many points do we have if we go back. And if I were to create more of these points, I can add the more frequency. And here as you can see, as I am starting to increase the number of points, my noise is getting sharper and sharper because we have a lot more points to sample the noise and also apply our noise onto these points because we are applying this as ACD, and the more points we have, basically, the more resolution we will get. So let me hide this, and here as can see we have the noise pattern. And let me go back onto the sphere and and Hears can see right now we have the CD as an eight point attribute. If 5% hold the middle mouse button, Heres can see we have two point attribute CD, but I want to drive the extrusion based on this noise. And if I type the polyetrude node, as you know that we have this attribute, this Z scale attribute, and this polyextrue node expect them on the primitive level to extrude these primitives. So what we can do, we can go into the attribute b node, I can change this run over method to primitive, and now hers can see our noise has been applied onto the primitive level because we have the CD 5% hold the middle mouse button as an a primitive attribute. So now we are coloring our primitives and not the points. That is why we have this noise pattern different. Or we also have an node for promoting this attribute. So let's say if I were to change these two points, and if I middle mouse button, here we have the point as an ACD attribute. I can add an A after that attribute promote node. As we have the group promote node, we also have the node for the attribute promotion. Let's connect this and let me view the attribute promote node, and in here, we need to define the name of the attribute. Let's click on it, and here we have color CD so let's add this and the original class is the points, that is correct. The new class, I want to change this to primitive and here is can see now we have the attributes promoted onto primitive level. If I press and hold the middle mouse button, and here as can see, we have the primitive attribute on the primitive level. Sorry, CD attribute on primitive level. You can also use the attribute promote node as well. Let me remove this. And for this one, maybe I'm going to just change these two run over primitives. And now onto the attribute. Wop node, we have this CD color attribute, and let me good at this. And in hair, I can play around with the three D frequency to play around with my noise pattern amplitude. Now, let's use this as an A in the polyextrude node. So let's connect this and onto the polyetrude. I'm going to change this. Right now, it is expecting an AZ scale attribute. So what we can do, we can either create an AZ scale attribute by using an bind export node because we can use the bind export to export our attributes. So in here, I can just type the name. I can say, please create an AZ scale attribute and to the values. This time we are going to use this input to set the values. So previously we have used this parameter to set our value. But right now, I want to use this as an input, so let's connect this. And now we should have an AZ scale attribute, 5% hold on middle mouse button, and here is can see, we have the Z scale attribute, polyetrude and that is enable and we also need to play around with this parameter because you know this will become as an A multiplier. So which means we need to adjust this and we also need to divide our geometry into separate components. So let's change this into individual elements. And here we have the extrusion. Right now, the extrusion is a bit extreme, so let's lower down this Z scale value. And here you can see we have this noise based extrusion. I can dive inside the attribute wop nod and to the anti alias noise, I can play around with the amplitude that will also adjust the extrusion length because that's the amplitude. I can also play around with the frequency to create more high frequency or low frequency noise. And by creating the low frequency noise, we have these bigger patches, and by high frequency, we have the lot of these smaller patches. And we can also export this parameter as well. And right now, heres can see if I were to, let's say, play around with the noise parameter. Every time I need to dive inside this attribute b nod, I need to find the nod. Okay, that is the NTS noise, and I need to find the parameter to adjust. I can also expose these parameter as well. So if I were to go back, if I want to adjust the settings from here at this level, I can also export these parameter. So let's go into the attribute op node. And the way we can do this is if you come over here onto this, let's say I want to expose this three D frequency, and here we have the input. For the frequency, I can just press the middle mouse button onto this input, and in here, we have this option called promote parameter. So let's click on it. And heroes can see, we have this dot, this bigger cylinder. And that means that there we have an a parameter node connected into it. I can just click on it and double click to expose this. And now Hes can see by double clicking on this cylinder, here we have this parameter nod, assign, I can bring up the parameter. And what that will do, it will expose this parameter onto this level. So which means I can go back and here can see we have the frequency parameter exposed in here. I can dive inside, and in here, I can expose any of these parameter. Let's say I want to expose the amplitude. So just come over here onto the amplitude, press and hold the middle mouse button and click on promote parameter. That will promote this parameter onto this higher level. And now I can just play around with these settings in here at this level. And if we dive inside, and Hers can see I am using the P as an A import, and I am writing this as an ACD as well as an AZ scale. I can just go into the polyetrude and I can say, please not use the Z scale, but use the CD, so I can do so by typing the name. So let's type the CDC lower Kst and hers can see we have result all the same. Which means I can dive inside and I don't need the C scale attribute. So let's delete this and hers can see we still get the extrusion because we are no longer using the E scale attribute, but we are using the CD to set out these extrusion. And now let's dive inside the attribute wop node, and hers can see I am importing the P and outputting them into CD by using the bind node to import the attribute and bind export to write out my CD. And if you remember, if I go back and if I were to create an attribute op node, so let me lay down another attribute op node. And if I dive inside, and heres can see every time you create attribute op node, you will be greeted with these two nodes. Okay? We have this Geometry ob global and we have the geometry b output. What are these guys? So these guys are there for your inhere. We have the basically we have this bind node inside of them. And here as you can see, we have this digital ascent, so which means I can double click to time inside. So basically, what that is doing, it's just creating multiple bind node, which means that I can always have access to P, which means the position. And we also have this V, which means the velocity, force and all of these things. So these attributes, for example, the V and force does not necessarily need to have to have present into our input geometry. It's just that if they are present, I do not need to create an A bind node and type the attribute. I have an a shortcut for importing all of these attributes. So these are the preset shortcuts. For example, we have the P present in here. I have the CD and N for the normal, and we have the UV and time and all of these attribute. Onto the output, we have this. We can write this pack to B as an a position. I can write this as an veloct for CD and N. We have the attribute, I can write them in here. These are basically the bind export nodes. And here you can see the bind export, we have a lot less export, but we have a lot more import, and that is because not all of the attributes are writable, which means some of them are read only. For example, here we have the PTNum PM store the current point number. If I go into the geometry spreadsheet, let me go back because it's an empty. And here as can see PTM is this attribute. Here we have the point number. Point number zero, one, two, three, and here is can see. That is the point number. I can go into the scene view. And let me enable my point number display. If I click on it, here as you can see, we have these unique point numbers. I have the point number 845. So these numbers are basically stored in the PTN attribute, and here we have the PTNm. So that is the attribute that store all of these numbers point numbers. So it is not an writable. It's an read only attribute, and I also have the primum, which is these primitive numbers. And I also have num PT, which means the total number of points, number of primitives, and number of vertex. I also have the time which store the current time and the current frame number, not all of these attributes are writable, they are read only. And here we have these attributes that are writable, position, velocity, and all of them. These are basically commonly used attributes. So which means I can go back onto the attribute wop node, and heres can see. We have created the bind to import the P and bind export to set as an ACD, which means I can just remove this and I can bring back my geometry geometry b global. So in here, I'm going to say geometry b global parameter. So if you type and add this and heres can see, we have this node back. And same way, I can inhere create our geometry ob output. So let me add this Geometry ob output. I can use these default guys to import my position. Here we have the P already there, which means I just need to connect this. And onto the noise, I can just output this as an ACD. And now if I go back and with the result and Heres can see, we have our attribute wop working correctly and we have the extrusion. Let me remove this and onto the attribute op node, and I can animate the noise, and I can animate this by this time parameter. The time will store our current time. If I enable my play bar and Heres can see, we have this playback animation. I can hit play and Heres can see that that is the frame number, and it is at the frame number, let's say, 56, we have a certain time value. So that is actually stored in this variable, which means I can go into the anti alias noise, and I can, let's say, play around with the three D offset. And, you know, we have this offset parameter. So I can connect the offset parameter onto this time to animate my offset over time, which means if I were to play this onto the playbar hit Play button, and here as you can see we have our animated noise. Let me stop this by clicking this button. And right now our animation is not in real time. It is playing as fast as it can. I can change this to real time playback by clicking on this clock button. And here you can see, we have this real time option. Let's enable this, and now our animation should run at real time, which means at the 24 FPS. So that is real time animation. And I can also animate my offset with my current frame number. Right now I'm using the time. I can also put the frame number frame number that is the variable that actually store our current frame number. If I were to create an a point export node in here and maybe just plug this in here. And now we are creating this palm attribute. And I can just go back. I don't need to rename this, going to the jump re spreadsheet, and it should be a primitive. So let's go into the primitive and heres can see Palm, we have the value of 21 because we are at the 21 frame. If I were to change this, let's say 47 and here's can see our attribute has been also changed to 47. I can play, and Heres can see as my timeline is progressing, we have this palm progressing. So that is the attribute, basically that store the current frame number. Let me remove this, remove this one also, remove this. I can put the frame number in here as an animation onto the offset, and now I should get the extrusion. But right now the animation is very chaotic because our values has been changing drastically. So that is why we have this very chaotic animation. And if I were to create all of these setup by writing my own code, I can do so onto the attribute wrangle and to actually write this, you know, we need to take care of the syntax, all of these for importing the attribute and writing out the attribute, and we have this noise. And for that, let's go into the attribute tangle. First, we need to let's say create noise in here. So creating the noise, we have some functions. So we can take a look at all of the x function if we go into the help and contents. And if I enable this, that will bring up my this Houdini help page. I can go down here onto this reference menu, and in here, I can see a section for the x. Let's click on it. And that is an AVX language. Reference, let me make this pin a bit bigger and down here. Have another reference tab, and in here, we can see ax functions. Let's click on it. And here we have the list of all of the available function that we can use. So for example, because we are working with noise, I can just click on here and filter this pie noise. And here as you can see, we have all of these filter, and here we also have a filter for the noise. Let's click on it. And here we have all of these different types of noise that you can create. For example, if I go into the A noise, let's click on it. So that will generate an alligator noise, and we have the syntax. There are several way of calling this function. So first, we have the datatype. We have this flow data type, and we just need to define this anti alias noise and type all of them. Let me enclose this and in here, if I type A noise, and here is CC the F, the function appears now in the braces. I need to define all of the parameter which represent these talas noise parameter, the frequency and position, and write all of this whole setup in the ax code. And that will create a much more complicated way of writing the same function. But it's actually easier to understand. So whenever we are creating a very complex scene, whenever I'm working, let's say, writing a complex script, I have nodes and nodes. This node editor will get quite messy pretty easily. To actually avoid this, I can go into the attribute angle, and I need to type all of these things as an A Vax code, and it will be much more easier to understand because it will be like reading as an a book. Here, I can just read, I'm creating noise in here and doing all of these things. It will be easier if you are working with much more complicated scene creating complicated script. So it's better to write your own ax code. But if I am creating a simple scene, creating a simple noises, I always use the attribute warp node because it's just much easier to just lay down the anti alas noise and play around with these parameter and be done with that. And in this course, I will try to avoid using this attribute wrangle to write vax code because it's an bigino level course. So I will try to use this attribute wrangle as minimum as possible. 19. 19 Parameters And Channels: Now that we have the basic understanding of the attribute op node, how we can lay down these nodes and how we can write some attributes, work with noise. So we have built our foundation in the attribute ops. Let's learn about the Ax code as well. So the first thing that I want to talk about is the channels. So in here into the ax expression, let's see what the channels are. So in the attribute op node, here is can see we have created these parameters. So these parameters are also called the channels. In the wax. Inhale into the attribute warp, let me dive inside. Here as you can see, we have created this parameter node to create to export this parameter in hair. If I dive inside in hair, if I want to create my own arbitrary parameter, I can create an parameter node in hair, and in the parameter, I just need to set the name of my parameter, and I'm going to call this one, let's say, my palm and now if I go back and if I view the result and hers can see, we have successfully exported this new parameter that is called the M Palm. I can dive inside and I can rename this. Maybe, let's rename this to my palm with the P. Let's go back and hers can see our changes has been reflected. So right now this parameter does not doing anything, and that is because we are just creating it and we're not using it. It's just there. And here you can see, its output is empty. We're not controlling nothing with it. But that's how you can create the parameter. So in here, if I want to, let's say, store these values into attribute, you know that we can create an bind export node can create bind export, and I'm going to rename this let's say value. I'm just creating an value attribute, and we just need to connect this in here. And now let's go back and let me go into the geometry spreadsheet. And here as can see. We have this new attribute called value, and its value should be the same as we have the parameter. And here can see fire just the parameter by this value values has been changing. And let's see how we can create these same thing inside of the ax. Let me maybe let's keep all of these things here. They're not hurting. Let's go back into the attribute wrangle. And if I middle mouse button here as you can see, we currently do not have any attributes. We only have just B. Let's go into the attribute wrangle. You know that we can create the attribute by first in signing the data type. So if I were to create float, I just need to type the float F at now the name. I'm going to type this one name and just give him an a value of zero and the semicon at the end two and the argument. Now we should see an a value point attribute. And here we have a value as an A point attribute. And now let's see how we can create the parameter in the attribute tangle in here. So to actually create the parameter, let me press Enter and onto the first line, I want to, let's say, create an a float parameter. And to create this, we need to type this CH, which means that we want to create the channel, and now we need to define the data type. And if we want to create an float parameter, we just need to type the F in here. So CHF mean the channel float, which means that we want to create an A floating parameter. And now we need to create an A braces. And inside of the braces, we need to type the name. The name is referring to this name. Here you can see, we have this one called my palm. So now we need to define the name of this parameter. And because name is an a string, so it should be written in semicolons. So you can create double colon or single column, both of them will work. So this time maybe let's just use the double column. And in here, I can type the name. I'm going to type this one or my palm. So let's rename this and we need to also add the semi column at the end in here. So we need to type the name inside of these quotation marks. And after that, let's add an A breaker phrases to close this. And to end the argument, let's add an a semiclumnPress Enter and here is can see our errors has been gone, which means that our syntax is correct. But right now, I cannot see my parameter. And to actually create the parameter, we have this icon in here, and here is you can see, it says, create spare parameter. So just click on it, and it will create the parameter for us. And here is can see, we have the Mi Palm parameter. And here I can play around this with this and we have this parameter. And right now, this MPOm is not doing anything because we just creating the channel and here we have it, and it's just there. It's not doing anything. So what we can do, we can write these values, these let's say, 0.27, we know that we are creating this parameter. But now let's store this value inside of the variables. What is an A variable? So variable is the information that actually store inside of this ax code. The way that we can create the variable is by first defining the data type. We need to type the whole data type in here. For example, if I want to create an float variable, I just need to completely type the name, float and here is can see and press space first, I have assigned the data type float. It must be written complete. Now the name of the variable, and I'm going to call this one maybe, let's say, Mar, M underscore var. That is my variable, and now we need to assign some values. So as you know, we need to press at the equal sign. And for this time, I'm going to just, let's say, add any random value, maybe one, two, and end this with the semiclumn. So we have successfully created our variable floating ti variable, My wor, and its value is 12. Which means now I can call this value with just typing the name. So if I were to access the 12 words store inside of this, I just need to call this name. What does that mean? Let's say if onto the F at value, here we are creating the attribute. And here as you can see, we have the value as an A attribute. And let's say I want to store this number, whatever inside of this variable. If I want to store this as an A attribute and onto the value, right now, I'm saying I'm just assigning an A value zero. What I can do, I can just type the variable name. So in here, I'm going to call my variable. So that is called the Mivar so I can just type. M underscore var. So now we are this at value attribute is equal to Mi var. And here is can see Mvar is an A float and it has some values in it, and I can see the same value in my attribute. Value I can check, going into the geometry spreadsheet, and we need to go into the points, because we are creating the point attribute, and here's can see we have the value, and it's correspond to this value that we have stored. I can change this. Maybe, let's change this to value of 16 and here is can see we have the 16 as an A attribute. Which means I don't need to manually type number in here. I can just at this argument, this channel flow, which means that because we know that this channel is actually storing this information, this parameter information. So onto the Mivar, I'm going to just delete this and I'm going to just copy all of this and in here, I'm going to copy this text and onto the equal, just paste it. And here as can see when we paste it, we have these two semicolon. We just move one semicolon, we only need one. And now in here, I'm going to just remove this because we don't need this. Let me clean some of these lines. Let's click in here and now we should see this value in our attribute. Let's go into the Gem tree spreadsheet. Here is can see we have the value and I can play around with this parameter, and here is can see we are storing this as an A attribute. The way that we are working, first, we are creating an a variable name Mivar first, we need to define the data type that is float var, and it's equal to the channel. This line here is creating the channel, the floating point channel, and we have the name of this channel, this parameter name, M palm. And we have some values that is responsible for this part, and all of the information are now stored in the Mivar and we are calling these values inside in here, Mbar and we are writing them as an A attribute. So variable is an A type of information that live inside of your code, which means that if I were to create another attribute wrangle and in here, if I were to call my same Mivar this myvar inhere, I can. So let's say I'm going to create another attribute, I'm going to call this one F at. I'm going to just call this one maybe result. I'm creating an result attribute. And if I were to call my variable, we know that we have called this variable. Let me see Mivar I'm going to call this one Mivar and the argument with the semicolon. And here as you can see, we still have the error. And the error is that this attribute triangle cannot find the Mivar variable because we do not have defined this Mivar variable up here. So variable is an A type of information that live inside of this code. All of these information are inside of this code. I can access them anywhere down the line. For example, if I want to create, let's say, another attribute, this time, I'm going to call this one, create another floating point variable F at Dbug. I'm writing another. And this time, I'm calling MVR again. Let's call this Ivar and add this with the semicolon. And here as you can see, we have the debug and value. Both of these are the same because we are retrieving the information from Mivar and MIR is storing this value. That's basically what the variables and the attributes are. And I can create an integer variable as well. So the syntax for that is we need to type the int. And here as you can see it is our syntax color has been changed to blue, which means we are creating the argument for our variable, and now we need to just set the name. I'm going to call this one maybe an A MI and Okay, that is the name. And for this one, right now, I'm just storing an A value of one at the argument. So we have successfully created our integer variable. Right now, it's not doing anything, but we have some information in here. And in here, if I were to create my string, I just need to type the string in here. And now the name of the variable, I'm going to call this one MyString. And in here, because it's an string, it must be written in colons. So I'm going to type and colon let's say hello word. And this and 20 argument as always at the semicolon. So we have all of these three variables that store some information, but right now we are not using them, but that's how you can create the variables. And we can also create the parameter. And here is can see, we know that how we can create the attribute with this. First, we need to define the data type and the add sign for the attribute. Now let's see how we can create different types of parameter. Right now, we have created this one channel F, and in here, let's say if I want to create an A integer parameter, right now, I'm storing this as a one. Let's say if I want to expose this as a parameter to set these values. Create an integer value, first, we need to type CH, which means the channel and now the data type. And the data type for integer is I just type I, and we need to add bracket in here, and now we need to define the name. I'm going to call this one, let's say, M and and we need to end this in the colon, and we also need to add an closing bracket. And lastly, we need to add the semicolon. Just click on it and to update this parameter, just click on this button. And here you can see we have successfully created another parameter. And same way, if I want to create a vector parameter, I can just type CH, which means the channel, and now I want to create a vector, so let's type, CH V channel vector. Now inside of the braces, we need to define the name. I'm going to call this one my vector, M underscore PC, and we need to add this inside of quotation and close the braces and at the semicolon two argument. To actually update this parameter, just click on it, and here us can see we have our M vector and it has three components. I can individually define the X, Y, and Z. So that's the basic syntax of creating this parameter and creating the variables and attributes. And as you know, if you want to create this primeter, it's much easier to just go into the attribute op node, and let's dive inside, and in here. Here as can see, we are creating an A float parameter. And same way, if we want to create an integer, we just need to define the type. In here, I'm going to say int, and we should have an A integer. My palm as an A integer. And if I want to create another parameter, I just need to create a parameter node, and inside the parameter, we just need to type the name. For example, this time I want to create an string, I'm going to name this My string. And now we need to define the type of the theta. And in here, here can see we have the string. Just click on it. Now if we go back. And here, as you can see, we have the MyString, and in here, I can type anything. And that will be stored in here. And same way, just need to create another parameter I'm going to call this one vector. So I'm going to rename this to my for my vector, and we just need to define the type. Let's change this to vector. Now if we go back and in here, we should see our myvector this parameter. And all of these values are now stored inside of this parameter, and we can output them by connecting this out node. I can keep adding this parameter node to create the parameter in here into this attribute wop node to play around with this data. And same way, you can do this with the ax code by creating these channels and storing them inside of your variable. 20. 20 Remap Values In VOPs: Now that we have some basic understanding of both obs as well as the x, let's put some use how we can use this knowledge, this scripting knowledge to actually benefit. And Here's can see, we have this second attribute angle that is throwing an error, and that is because we are writing an attribute and calling the variable that does not exist, that is the error. But I'm going to just delete this because we do not need this in here, maybe let's come over into the side and create another example first, I'm going to create a line node in here we have the basic line. Let me go into the parameter of the line, maybe zoom into my node editor, and onto the line, using the line node, we can create just this basic line. I can define the length of the line. I can define the number of points if I enable my point display. And here as you can see, I am creating more or less of these points, and here can adjust the position by playing around with the origin and we have the direction. Right now, we are creating the length along Y. Let's zero it out and onto the X. Let's maybe add an A one. Now we are creating the line along X axis. I can play around with the length. And in here, if we want to create more or less these points, we also have an A node called resample. Let's type resample and add this. And what the resample node will does, we can adjust the length parameter to create more or less of these points. So we can subdivide these lines with the resample node. If I were to go into my line, and let's say I want to lower down the number of points, let's maybe keep them only just these two points, the point number one and two. In able my point number. Hers can see, we have the starting point and the endpoint, zero and one. And now, if I add an resample node, hers can see, the resample node is resampling our line and adding a lot more points. We are dividing our line into multiple points. We are adding more divisions. And we can adjust these number of points by playing around with the length parameter. So we are adding number of points at the length of 0.1 meter. If I were to increase this value, I can create less points because I am adjusting the length. If I were same way, if I were to lower down this length value, I am creating more points. So by using the resample node, you can resample your lines to add more points. Let me hide my point display. Or into the resample load, resample load will also output some attributes for us, and the one attribute that we are interesting in is the curve view attribute. So if I enable this, it will create an A curve view attribute onto the line. If I press and hold the middle mouse button here as you can see, we have an A attribute that is called the curve attribute. So what is the curve attribute? It will store the values that will start from zero. So when our line is starting, we have the value of zero, at the very end, we have the value of one. So the one means that we are at the end of our line. So we can visualize this hour attribute, and you can visualize any attribute if you hover over tap through that node and press on this e button. And that will just bring up this inspection window, the same inspection window that we were inspecting by pressing holding the middle mouse button. That window only appears as long as I have pressed and hold my middle mouse button. And if I want to keep this window open, just hover over to that node and click on this eye button, and that will bring up this inspection window. Let me click this again. And now by clicking this, Harris can see we have some on off switches. So what are these on off switches are? These are the visualizer. So if I enable this option, Harris can see now we have the curve view attribute visualized as an a color. So here we have some color going on. So at the very start, we have an purple color, and at the end, we have an a red color, and between we have some interpolated values. That is why we are getting the different RG and B values. And I can actually adjust this visualizer. I I don't want to visualize this as an a color, let's say if I want to visualize these values, what are these values? I can adjust the visualization. So whenever you click on this option, enable this, what that will do, it will add a visualizer. So we can play around with the visualizer setting if you come over here onto this location mark where that looks like an allocation mark. These are the visualization, and if I just click on it and heres can see all of the visualization has been turned off. And if I click this again, now I have visualization turned on. And if you press hole, sorry, not present hole, right click on it, and Hears can see we have some visualizer in here. And hers can see we have created this curve view point attribute. That is the scene visualizer, and onto the object, we have some of these options. But right now, when we click click this option, that has created an A visualizer in here at the scene level. And here as you can see, we have this curve point attribute visualizer, and we can adjust the setting by clicking on this button, click on it, and here as you can see, we have the curve view visualize. And right now we are visualizing this as an a color. And here is can see, I can change this into the type. Okay, so right now we are visualizing this as color. And let me click on it, sorry, right click and enable this to enable my visualization. And here as you can see, I can enable or disable my visualization in here as well. Now, just click on this button, and in here, I'm going to change the type from color to marker. Okay? So what will work this visualizer will do, it will visualize our attribute as an A values. And as you can see onto the style, we have the style as an a text, which means that all of these attributes should be visualized as an e text. Let me close this and heroes can see we have some values. At the very first point, we have the value and 0.05 and this value is increasing. And it will end all the way up to one. So the one means that we have reached the end of line, end of our curve. And between them, between the zero and when we have these interpolating values. And the value of 0.5 should mean that we have reached the center of our line. Curve view is an A very useful attribute. So let's click on it. I can just disable my visualization in here, and here is can see. Now this visualization, remember our settings, which means that please visualize them as an A marker. And I can also inspect this by going onto the geometry spreadsheet and here is can see we have a point attribute curview and at the very first point, we have the value of zero, and at the very last point, we have the value of one. And between them, we have these interpreating values, and we are visualizing these same values by this visualizer. If we click on it, and here is can see, we have these values. I can play around with the resample node to create more or less of these points, and we have these attributes updated because now we have more point, we are dealing with more point. So maybe let's create more of these points so that we have a lot more divisions to work with. Maybe let's lower this down to a value of 0.1. And let's hide the curve view visualizer, and let's also hide the point display. So now let's create an attribute, b node in here. And let's connect this and now let's dive inside. And Hers can see we have these two nodes, the geometry b global and the geometry b output. And in here, Hers can see we do not have the curve view option, which means we need to create our own pine node to import our curve view attribute. So let's add pine node in here. And now we need to set the name of the attribute that we want to import and we want to import our curve view. So let's type the name of our attribute, and it is an float attribute, and we have successfully imported our curve view attribute. What I want to do with this attribute. Now that I have imported, so what we can do with this attribute. For this one, let's say maybe let's create an AP scale attribute with this curve view. I can write this attribute by adding an a point export node. And I'm going to create an P scale attribute. Let's connect this in here fi middle mouse button. Now we have the P scale and the curve view attribute, and both of these should have stored the same values because we are importing as well as exporting them. So nothing is happening in here in between. If I go into the geometry spreadsheet and here can see curve you and P scale, both of them have same values. Basically, what we just did, we just duplicated our curve view attribute and just rename this to P scale. And in here, now that we have P scale, which means I can create any geometry. Let's say I am going to create an A sphere, let's create an primitive sphere because it's a very basic piece of geometry to work with. It's very lightweight. Let me move this aside and inhere, if I want to create an a copy to points node, and you know that copy to points node, understand the P scale to set this input geometry scale. So let's connect this. That is the geometry to copy, and these are the points. Now if I view this and heres can see, now I have this gradually increasing my P scale value. And now I can play around with the resample node to create more or less my copies. I know that at the very start, I have an P scale value of zero and at the very end, I have I value of one, and that is creating a some sort of light bulb. And now let's go into the attribute op node, and in here. Let's remap these values. Let's play around with these values because right now we are just importing and exporting them. So in here, let's do some operation. And the one operation that I like to do, I like to remap these our incoming values. So I can add an fit range node. Okay, so let's add this. So the fit range node will remap our values. So it has this one value, the value that we want to fit, and I want to play around with this value, this curview and now onto the output that is called the shift. Let's connect this at the output. Now we have some operation going on in between. Let's bring up the parameter of this fit node, and here as can see we have the source men and source max. Source mean and source max represent that. What are we have the minimum and maximum value on our source? As you know, that curve view is our source, and I know that this attribute, start with the zero and end with one. I know the source input range. I can go into the fit range node. I can say that source min is zero and max is one, and that is correct. And the destination mean, we are just keeping all of these values same, which mean that the output is mean and max are the same, which means that this node right now is currently not doing anything. We are importing the attribute as zero and one and writing this at zero and one. What I can do, I can just play around with this destination mean. Let's say I don't want the maximum value to be one, my output values to be one. I can just play around with this parameter and heroes can see. As I am playing around with this destination max, what I'm effectively doing whenever we have the value of one, which means at the very end, we will not get the value of one, but we will get the value of 0.3. I can play around with this. I can change this to 0.2. And I can actually expose the parameter as well. And here as you can see, we have the source Min and max and we have destination mean and max. Because I know that source is zero and one, I don't need to export this. Let's maybe just export this destination win and max. So I can just press and hold the middle mouse button, press the middle mouse button and click on this promote parameter, and I want to promote my destination max as well. So just press the middle mouse button and click on this promote parameter. So now we should have the parameter exposed in here, and here can see we have them. And here we have this one. These are renamed to minimum value, in the destination range, minimum value in our sorry, maximum value in our destination, that is the minimum value in our destination. And we have this parameter. And we know that we are starting with zero. I can fit this. Let's say I don't want the values to be zero, but I want to start with something. Let's say value of 0.7. And now here you can see our very first sphere will not get scale of zero, but a value of 0.07. And by doing so, I can play around with this remap, our values. And if you want to rename this parameter, right now, Hers can see we are getting this very long parameter name. So what I can do, I can dive inside and I can expose the connected parameter by just double clicking on this button, and Hers can see we have connected this parameter. As you know that this parameter is responsible for exporting and just double click on this to expose our second parameter as well. That is the mean and that is the max. So in here, hers can see we have the name and we have the label. So we are labeling this in here. That is the label. What I like to do, I would like to just rename this to minimum. So I'm going to just remove all of these, and just keeping these to minimum. And now, if I go back and Hearers can see this parameter has been renamed to minimum. And now let's just rename this to maximum as well. So let's click on this second parameter, that is the max, and let's rename this label to maximum. Let's go back. And now we have changed our label minimum and maximum. Now in the next lesson, let's do this same operation by writing the ax code. 21. 21 Remap And Ramps: Okay, now let's repeat the same setup inside of X how we can write the VAX code to achieve the same result. So in here, we have this op method. Let me duplicate node, all of the network node network, and let me rearrange some of these. And I'm going to just remove this attribute op node. And in here, we were just creating the line and we are resampling them and we are copying our sphere onto these points. And right now we have the uniform scale because we do not have B scale attribute. And onto the resample, we have the curve view attribute. So now let's add an A attribute, wrangle node in between, let's set this. And in here, now let's create our P scale attribute based on our curve view. You know, we can create an AP scale attribute by first defining the type. So we know that P scale is a float, so let's type F and now the add sign and after that, the name of the attribute. I want to create an AP scale, so now type the name. And now that is equal to, and for this time, I want to set this onto my curve view attribute. As you know that we have curve view attribute present, and we can import the attribute in here by typing the name of the attribute. So first, we need to set type the add sign, which means that the attribute and now just type the name of the attribute that you want to import, and I want to import my curve. So let's type the name of the attribute curve and now to end the argument at the semiclumn. Now if I let go, and here as you can see, we have the P scale. Now the P scale is driven through this curve and now we should have to attribute as before, curve view and P scale, and these values should be same. Let's go into the geometry spreadsheet, and here can see we have the curve view and we have the P scale, and all of these values are same. And same way, we are just creating an P scale attribute, and we are importing the values from curve view, and there is nothing happening in between. Let's add an fit range node that we have created in the attribute Wop node, this one, fit range node. And to actually create this, we have an AVX function. So in the VX, all of these nodes are called the function. Let me sorry, hide the parameter. So all of these nodes, this fit node and all of these nodes, these are called the x function. If you are going to write the vax code. You can find all of the x function by going to the help and contents as in here onto the reference tab to the reference, find the ax reference and let's scroll down and we have another reference, and we have these vax functions. Let's click on it, and here we have a long list of ax function. These are the vax functions that are available for you to write your code. And for this one, I'm going to find the fit. So onto the filter, I'm going to make search query for the fit. So if I type fit, and here as you can see, we have several different function. We have Efit and we have fit and we have Fit 01. Let's see the fit and we have the help and say takes the value in one range and shifts it to the corresponding value in a new range. So that is the function that we are looking for. Let's click on it, and here we have the syntax of this function. So we can type this. The float is an A output data type, which means that if you are going to fit your data type, that is an A float. Okay, we can call this function like the name of the function fit, and we have the braces, and we need to define the value that we want to fit. And if it is an a float, if you are working with float, and in here, the next argument, these arguments should be separated by this comma, which means the input, sorry, that says that 00 mean means that here we can see take the value in range O mean and O max. So which means that O mean are the input. O mean, we need to define what are the incoming values, okay? Minimum incoming and maximum incoming. And now the mean is the new minimum and new maximum. Same way if you are going to fit your vector, we can call this function with the vector as well. We need the value. And here we have these three Min max, min and max for the vector. But right now, curview is in a float, so let's use this float in here. So what I can do. So first, we need to call the function fit. So I'm going to just delete all of this. So I'm going to say at P scale, now I'm going to type the function name fit, and here we have the fit, and it should be written in this bracket, this small bracket. And now, the first thing that we need to do, hers can see we need to define the value. So what is the value that we want to fit? And I want to fit the values that are stored in my attribute. So in here, I'm going to type the add sign, which means take the values from my attribute. The attribute is called the curve U. So I want to fit the values that are present in the curve view attribute, and now to separate the argument, we need to press them, so comma and we need to define the minimum value. I know that I have the incoming minimum value of zero and now comma again for the next argument, and the next one is the max. I know that my incoming max value is one. So let's type this and add another comma. Now we need to remap this into new value. Minimum value and the maximum value. And here I can define my new value. Let's say I say I want to create a minimum value of 0.1. I don't want the values to completely zero. And now I can separate this with comma and now we need to define the max. And I'm going to say the maximum value should be 0.5. And after that, we need to close this small bracken. So let's close this and to end the argument, add an a semiclumn. Now, let me close this and heres can see we have our starting value is 0.1. And I can change them. If I were to change, say, let's say, I want this very first this starting value to be, let's say, 0.2. If I were to change this to 0.2 and hers can see, now we have these new values that are starting from 0.2 to 0.5. I can change this to 0.3 maybe and hers can see. We have this variation. Now we can create some parameters in here because right now we are just manually entering our values. So what I can do, I can create an a parameter. And as you know, we can create the parameter by creating an channel expression. So I'm going to press enter to move this line down. And at the very first line, you know that we can create the channel float with the CHF function and to actually bring to actually store these values, we need to create a variable. So we know that the data type is flowed, so I'm going to type float, the data type, and now the name of my variable. I'm going to call this one my variable name to min and that is equal to now the channel function. So I know I want to create an A channel in here, the parameter, and it should be float. So CHF now start the bracket, and in here, we need to type the name. A name is a string and string should be written in columns. So let me add an edible column this time, and I'm going to call this one an A, let's say, whatever you want to call, I'm going to call this one Min and let's add this inside of this quotation, and now we need to close this bracket and also add an a semiclumnt argument. And now let's create another parameter. Let's add an float, and I want to store this enough variable. I'm going to call this one max and that one, let's create another channel float and I'm going to call this one Mac capital X, Max. I'm naming this. Let's close this with this small bracket and the argument. Let's click on it. And now to actually create this parameter, we just need to click on this button. Let's click on it, and here as you can see we have this parameter. Now we can pretty easily just use this graphical interface to set our values by using this slider. And here as you can see right now these sliders are not doing anything. That is because we are creating these values and storing them in the variable, but we are not actually using them. So to actually use them, I just need to replace this value. You know that that is my minimum value, so I'm going to select all of them. So instead of manually typing this, I can just reference M T variable. To reference this, just type the name of the variable. I'm going to type one Min. So if I click and now Hears can see I have put use to buy this minimum slider because now I am getting these values from my T Min variable. And same thing I can do this for the max. Right now I'm manually typing this. I can just remove this and replace this with this max variable. So let's type Max and now I can use this slider to actually control my min and max value. Okay. So we have effectively built the same functionality, the same thing that we have done inside of these by using these nodes. And now let's go into the attribute wrangle and hers can see we are creating this function fit. We are importing the attribute, and we are remapping our input value zero and one to our new min and max. We are getting these values from these parameter. And if you remember, if we go into the contents and let me go into my x reference and into the ax functions, and if I type in here and a fit, and down here, here as can see we have another function that is called Fit 01. Let's click on it. So the Fit 01, this function is an shortcut of this fit function. Fit 01 means that we don't need to define our input range. So the fit 01, assume that your input range is 0-1. So which means we need to just tie fit 01 and now the value and we only just need the new mean and new max. We do not need to define our own this zero and one. So we can actually save our time by just creating an fit 01 function. So let's see how we can do that. So in here, I'm going to this one called My This function fit 01, and here as can see we have this function menu appear. I can just pick function and press Enter. Now it will be going to be written in MVX code. Now we need to type this inside of these pass, and now we need to set define the value that we want to remap. And as you know, I want to remap my cur view. So in here, I'm going to type at sign, which means the attribute, now the name of the attribute, curve view, and now we need to separate the argument with the column. Now we only just need to define the new mean and new max, and I want to set new mean new Max with values that are stored in this variable, which means I can just type Min this variable name and column and the max for the max value. And to end this, we need to end this small bracket and semiclumn at the end for ending the argument. Now, if I click and heres can see, we have our exactly the same, our result can play around with my maximum value. I can play around with my minimum value, and arrows can see we have basically the same function, but that is an a shortcut, which means we are not defining the minimum this fit 01, assuming that your input range is in zero and one range. So it's an A shortcut function. Now let's talk. Let's see about the RAMs. Let me duplicate all of this node graph and let me connect. Come over here. Right now, we are remapping the value with this fit range node, creating some parameters. And we also have another node called the RAMP Pi type, here we have this RAM parameter. If I add this, and that is another type of parameter that uses the RAMs. So let me show you what I mean. So I'm going to just remove all of these parameter and the fit range. And what I can do, I can just input this curew as an input and now output the ramp as an AP scale. So now we are not using the fit range function but the RAM function. Now I can go back and this node will create the parameter by default. Here, if I enable the parameter, here as you can see, we have some of these default settings. These settings won't do anything. These are just the default settings. To actually control this parameter, if we go back, hers can see, we have this new parameter AMP. This RAM parameter this AM parameter automatically expose its values onto this level. So whenever you create RAM parameter, its values will going to be exported into this attribute wap level, this inhere. So now I can define the color. By using the color, I can set the values. So we know that the Black mean the value of zero. So black represents zero values and white represent the values of one. And between, we have these increasing values zero to one so that we have the gray and we are traveling toward the white. So if I enable my the copied points and hers can see, now I have exactly the same look. Now I can play around with this color parameter and hers can see by adjusting the color, I am adjusting these values, but now I'm using these color. So for example, I can add another knob in here by clicking on it, double click, and in hair, I can play around with the value. If I change the value, let's say, dark in hair. And for this one, I'm going to, let's say, change this value to white. And by playing around with the lamp, I can really otrat my this look. So these values will actually not do anything. This color value because it's an float. We only gray skill values will affect. I can use this color to set by P scale, remap our values. And right now we are using the color ramp, but onto this AM parameter, we have the option to actually change these two spine RAM. Here onto the RAM type, heres can see we have the RGB AM. We also have an Spline am that is for using the floating point values because P scale is an F float value. Let's change this to spline am, which means that it will use the float values. All of these MP scale has been set to zero. Let's go back into this level. Let's see, and heres can see by default, this spline ramp has been set to zero, and we have these knobs. We can remove them if you press and track them down. That will just delete these knobs. So I'm going to just track them down to remove them. And in here, now I can just click and draw and heroes can see. Now I'm using this spline type ramp to remap our MP scale values. And this ramp represents our let me select and drag to remove this knob. So the very first mean that our start of the line. So that means we are starting value with the zero. I can play around with this. And at the end in here, I can play around with the value to set my P scale. I can play around with this and to really direct my P scale value based on my curve view attribute. And right now we are setting the B scale attribute. We can actually change this curve position as well. Let me duplicate all of this node graph in here and let's tie inside this attribute op node. And for this time, I'm not going to use the P scale. I want to just adjust my this Y position, this line Y position, as you know, that this Y position is zero. Because currently, we do not have any offset of this position onto the Y. So let's dive inside, attribute B node, and this time, I'm not going to create an P scale attribute. So let's delete this bind node. Let me bring this down. And in here, I want to adjust my this line Y position, this point Y position. So we know that we have this P, it is an A vector, and it has three values X and Y and Z. Can actually break down these individual component by adding an converter. We have an A node called vector to float. So let's say this. But that will do it will expect an a vector, so we can give an a vector P position, that is an a vector, and that will separate all of these components. That is the X, that is the Y, and that is the Z. And we have the P as an A output. We know that position is a vector, which means we need the vector. I can convert all of these float back into vector as well by adding an A flow to vector node. Here we have the float to vector. Let's add this. Now, this will expect these three values, the X, Y, and Z. I'm going to just connect the X and the Z to Z, Y to Y. Now this will spit out as an A vector, which means I can connect this into P. And heroes can see right now nothing is happening because we are importing the P and we are outputting all of these values back. So nothing is happening in here. But what I can do, I can just not use the Y position that is incoming from my original position. So I'm going to just remove the Y from the Y. So just click and drag. Here what I like to do, I like to use this curview as an AI value. So which means I can just connect this in here and to adjust my this line position by using this ramp. And let me remove all of them, all of these nodes. Let's make this value to zero. And now here can see we have the Y value zero, which means no offset has been added onto the Y. As I know that the curve view, sorry, let me go back. At the curve view, we know that the value of 0.5 means that we have the center we have reached at the center of our line of our curve. So which means I can add an A knob at the 0.5 position, if I just add in here, and here we have the position. I'm going to say add an A knob at the 0.5. I can manually type in here. Now, we know that we have reached at the very center of our line. And in here, I want to change the value. And here as can see I am pulling this point position from the middle, and I can adjust this knob to offset. And if we want to create a more, as you can see, we have this fading type ramp, I can change the interpolation. If I come over here onto the interpolation, I have some of these interpolation. I can change this to constant. And that will make all of these constant, which means I think I need to change all of them to constant and this one to constant as well. And let me see. We need to play around with this as well. I'm actually bringing I'm playing around with this ramp to actually move only just this point up. And we also have some other interpolation method. I can change this to Catmulom that is smooth interpolation and Hearers can see. Let's change the first one, this one, to CatmulRom as well. And now Hearers can see I can play around with this ramp in a very smooth fashion. Now, let's build this same am setup inside of our wax as well. So let's do that in the next lesson. 22. 22 Ramps In VEX: Now let's build this same am setup inside of x by writing our own Vx code. So for that, I'm going to first duplicate the setup where we have sett the P scale. Okay, here we have it, where we are using the ramp to set up this P scale. Going to just select all of these nodes, press and hold the key to track, to duplicate them, and I'm going to place them in here and let's remove the attribute vb node. And now we get the same uniforms P scale value. And in here, let's add an attribute wrangle node. Let's connect this in here and in here, we know that we want to create an AP scale value. So first data type, the attribute name, attribute I want to create is the P scale. And now I want to remap my values by using the RAM. You can actually create the RAM Let me first change this to zero and add an SEM column. Otherwise, this will throw an error. So here as can see if I just leave it like that, it will throw an error, this attribute angle, which means that we forgot to end the argument. That is why I was just initializing this to zero. So in here, let's create meter RAM type parameter. We know that we can create the float channel by typing the CHF for the float and for the integer for the I and to actually create the amp. We have an A also have an A channel called channel RAM. So CH now we need to type the name amp. And here you can see, we have that channel amp. That is the function. And same way, we need to just type at the braces and in here, we just need to type the name of our ramp that what we want to call, we can call anything of our ramp so let's see how we can actually create an AAM. First, I'm going to store this in a variable because we know we can just type variable name to set an A scale. So first, I'm going to create an A float variable. So I'm going to type the data type float. And this time, I'm going to call this 1:00 A.M. So that is the variable name. And for this one, I'm going to create an A channel ramp. So let's add an amp. CH RAM, which means we want to create an RAM type channel. So that's inside of the press. We need to create the name of our parameter. I'm going to call this one my AMP. I'm going to just rename this my RAM, and it should be inside of this quotation. And now, it requires another argument. The other argument is the values that we want to fit by using this AM. And I want to fit my curve U attribute by using this AM. So in here, I can just type the attribute name. By adding an add sign and now the name of the attribute. And the name is called the curview and we need to close this inside of this small bracket and the argument with the semicolon. And now let's click and to actually create the RAM, we need to just click on this option. Let's click on it, and hers can see we have the RAMP parameter created. And it is called MRAM because we are calling this one MRAM. And it is fitting the curve values. And now we just need to use this ramp to set our P scale. Right now we are setting this as NA value of zero. So onto the P scale. Let's use this am variable to set the P scale. So in here, I'm going to just replace this with my variable name that is called the RAM. And now, errors you can see, we have the same functionality built in now by the ax coe. I can play around with this ramp to really Otrack my all of these B scale values along the length. And now, finally, let's use the RAM to actually adjust our position of our curve. For that, I'm going to just duplicate this same setup or maybe these three nodes, these two nodes. Sorry. Just select all of them come over here and in here, let's create an A attribute wrangle again, connect this onto the first input and maybe let's zoom bring up the parameter, and first, let's create an a variable float where we will going to be storing our ramp. And I'm going to calling this variable name to AMP and now to create actual channel, we need to type the CH and now I want to create an AAM type channel. And in the process, we need to define the parameter name. You can call anything that you like, but I'm going to call this one Mam. And remember, that is the label that is going to be assigned when the parameter is going to be created. So I'm going to call this one MM, and it should be inside of the quotation. And now the column to add another argument, and the other one is the attribute that we that we want to control with this AM, and I want to control my curve you attribute. So at and curve, and that should be close this inside braces and end the argument with semiclumn. And to actually create the RAM, just click on it, and now the Am has been created. Our this parameter has been created, and we are calling this one MAM because we have written this MAM. And now to actually control our Y position, we know that we want to set our P attribute. The position is to inside of P. So in here, I can say at P, P. Now that attribute toward the position and it is A vector. So which means I can say at P and say this is equal to if I say at P, and let's end this with semicolon. So nothing is happening. We are importing our P, our point position attribute, and we are setting this at P again. So nothing is happening in there. But what I would like to do, I would like to change its Y position. So inside of X, I can separate the vector component by adding after the attribute name, add an a trot, and after that, you can type the component name. Let's say if I want to change the X component at p dot X, now which means that we are changing the X component. And same way, I can say I want to change the Y component, I can say at P dot Y, and for the Z, I can say at P dot C. But right now because I want to change my Y position, in here, I'm going to say at p dt Y. So I'm going to say in here that our current point position, please import Y position. So at P Y. So our current point Y position, and that should be equal to the RAM. We know that Y is an A one value, it's an float, which means I can use the RAM. Is an a float. So in here, I'm going to just type an AMP variable name, and it should work like that. And here as you can see, we have our Y position adjusted according to this ramp, which means I can play around with this ramp and my Y position should represent the same as we have the RAM and same thing if I want to adjust my this middle position, let me clear out all of these dots, all of these position rams. And I'm going to the first one is zero and the last one, I'm going to change this to zero to bring everything down. And at the middle, I'm going to add an A point. And to actually change the position, we have this position slider. I'm going to go to the at the center. The center is the 0.5. And now I can adjust the value by adjusting this knob or by adjusting this value parameter. And now we are moving our center Y position up. Same way, I can change this one interpolation. Let's change this to monotonic. Cubic, that is smoother interpolation. Let's change the first one to monotonic cubic as well, the last one to monotonic cubic as well. And we have this smoother interpolation between these RAMs. That is the basics of the channels, how you can create the channels, create the RAM parameter inside of both x and ops. 23. 23 Volumes And Voxels: Now let's talk about volume and axels. We will use volume for creating the smoke simulation or creating the fire simulation or explosion or clouds or any kind of volumetric simulation. We always deal with axels. Let's talk about what are the axels. So to explain this, let me create an Jumpt node in here and dive inside. And in here, I'm going to first create, let's say, robotoi geometry. Let's add this. And in here, Heras can see we have the Roberto geometry, and it is made out of points. If I enable my point display, Here can see we have these points, and it is made out of points and primitives, these are the primitives that we call the faces. Let me enable my selection tool. Okay? These are the primitives. In Houdini, these are called the primitives in other software. I I think called the faces. But it's a simple polygonal piece of geometry that is made out of points and polygons. And same way, if we want to convert this into volume, we need to convert this geometry into voxels and to convert this geomry into volume. We have two types of volume inside of Houdini. We have the DB volumes, and we also have the native Houdini volumes. So let's see how we can create both of them. To create the Houdini volume Houdini native volume, we have a node called IO offset. If you type IO offset, let's add this node and connect this in here let me activate my ISO offset and heres can see. Now I have this fog representation that is the volume. And onto the IO of set parameter, He can see, we have the output type. It is set to fog volume, which means we are converting this into an A fog volume. I can change this to SDF volume. Here we have the SDF, that is the sine distance field. And if I middle mouse button, hers can see right now we have one points, and now we have an A one grid volume. And here we have one grid volume, and that is an A Houdini volume, Houdini native volume. And the other way you can create an A VDB volume we have a node called VDB. If you type VDB, and hers can see, we have a lot of different types of VDB that are used to add the different kind of operation with volumes and to convert our polygonal geometry into volumes, we have an node called VDB polygon, VDB, from polygons. Let's add this because we want to convert this polygonal piece of geometry. Our source is an a polygonal and we want to convert this into volume. So let's connect this and let me activate this VDB from polygon node. Now if I enable my parameter and same way, we have an Tristance VDB, and that is why we have this visualization and we can also convert this to fog volume by enabling this fog VDB option. Let me enable this and let me disable this Tristance VDB checking this and Heres can see we have our fog volume. Now if I press and hold the middle mouse button, and Heres can see we have an A one VDB volume and here it is written, it is an A VDB volume. And if I go into my Io offset and press and hold the middle mouse button, it says one grid volume. It means that it is an A Houdini native volume. And we will talk about what is the difference between the VDB and the Houdini native volume is. But right now, let's talk about the voxels. And here you can see we have a very coarse representation of our geometry. If I view this rubber toy and here is can see that is our input geometry, and if I were to visualize this, that is the Houdini volume and the VDB volume. Let me maybe do better visualization enable my Tristan's VDB. And in here, I can see a little bit of improvement if I enable the Io offset, but both of them are not accurately converting my geometry or this polygonal representation of a geometry into accurate volume. And that is because the resolution of volume right now is very coarse and we have low resolution volume. We can increase the resolution of volume by decreasing the axel size. Right now, the axel size is set to 0.1. And if I were to lower this value down, let's say, let me lower value down to 0.03 maybe. Let's check. And here as can see now I have a much better representation of my polygonal piece of geometry. And if I want to add more of this resolution, I just need to decrease the axle size. So maybe let's further decrease this 20.01. And now here as you can see I have a much higher as representation of my original piece of geometry. And same way, I can go into the Io offset and to actually increase the axel size, we have this option under this dimension tab, and right now it is using this Max axis and the uniform sampling provisions method to add the resolution, which means I need to increase this value to add more resolution. Or I can change this method from max axis to by size. And now Hears can see we have an indivision size, which means that in here, I can say how big my axel should be. Here, as you can see, we have the value of 0.1, and in here, we have the value of 0.01 axel size. Same way, I can just need to lower this wax value down. Let me change this to 0.05 and maybe further decrease this to 0.03, and here is can see you can continue decreasing this value down and you will get your volume representation, you will get your volume sharper and sharper. Okay, so we are keep adjusting this axel size. Here, it says division size, and here it says Waxel size. Both of them are same. That is the auxel and that is the auxel. But now let's understand what auxel actually is. And to explain this, let me create an grid inhere and this is the result of the grid. And here as you can see we have this polygonal piece of geometry with these points if I enable my points. And right now, I have a lot less point, which means that my resolution of my grid is right now low and I can increase the resolution by increasing the rows and columns. And heroes can see by increasing the rows and columns, I'm adding more points, more polygons, and effectively, I'm increasing the resolution of my geometry, which mean if I were to add tree tail, I can. So maybe if I explain this let me change the rows and columns to their default values. And in here, let's say if I want to add an sculpting ttail or any kind of deformation tree tail or extrusion, let me let's create an sculpt node in here. I can sculpt my geometry by adding an A sculpt node. So let's add this and connect this. And right now it's throwing an error because it expecting the input geometry. Now we have that. Let me activate this. The error is gone. Now set the node when the node is selected, hover over to the viewport and press Enter. And that will enable this manipulator. Here we have these tool manipulators. And in here, I can just draw to sculpt my geometry. And right now, I cannot see any taformation, and that is because my brush size is too low, so I can increase this brush size. Here as you can see, we have some shortcuts listed in here. So I can increase the brush radius by scrolling my mouse wheel. So let's scroll. And here we have an piggre brush size. And now, let me change the camera angle. Hars can see I am adding the deformation. And maybe it is easier to see fiber to change this to smooth frame wire shaded, and hares can see I am adding some deformation. And I can reverse the effect of this culpet node. If I come over here, here as you can see, we have the inverse operation. If I were to press and hold the control key and then draw, then we will have the reverse effect. So let's press and hold the Control key and draw. And now we are adding the inverd of this inverse operation. And I can change the different brush type here if I come over here onto the brush, right now we are using the clay brush. I can change this to move, which means now I can just select my points and just move them. And we also have all of these different types of brushes, sculpting brushes. Let me change this to clay again. And you can also scroll down your brushes by going through the number, heroscanc one, two, zero, which means I can just type one, two, and now we have clay strip three, four, five, all of them. These are the shortcut by using these numbers, I can just move through all of these brushes or I can just change this to clay. Change this from here. And now let's increase the resolution of my grid. I I want to add more resolution, I want to add create a fine detail. I must have to have more resolution, let's go into the grid and let's increase the number of rows and column to increase the resolution. Let's go into this CulpetTol and onto the edits. And in here, I can just click on this reset culpet and that will reset all of my operations. And let's go into the grid. Maybe let's continue to increase the rows and column. So maybe let's change this to 200 by 200 and now we have a lot more points. So now let's go to the culprit tool, and now press however to the viewport when the node is selected and press Enter so that we have access to the manipulator. Now I can just click and draw. Let me now change this to smooth shaded because it is harder to see with all of the wireframe. Let's change this to smooth shaded again. And also, let's reset this culprit. And in here, let's lower down the brush size. Now I can draw and I can increase the strength by here as you can see, we have the strength. So just press and hold the middle mouse button, and let's increase the strength of our brush. And now I can create a more exaggerated I have more exaggerated effect of my brush. Let me reset this again and lower our brush size down. Maybe let's lower this one down too as well. And in here, let's draw maybe a smiley face. So let me lower down the brush size. And in here, I'm going to draw an A big face right in here. Sorry, that is not the correct circle. Let's try that again. Just click and this time, I'm keeping my mouse steady. No, that is not correct, too. Okay, one last try. I'm not going to bore you guys. I just want to create a good looking smiley face. Okay, I think that is correct. Now let's create some eyes. And to create the smiley face, I think we need to create this. It's more like it. Now we have this smiley face. Let's add some teeth in here by just looking and dragging this. Now I can make this smile to be an travel smile, which means that it is an devil that is smiling. So the devil should have these sharper teeth, and I'm going to create another sharper teeth in here. And it's still not looking like a travel, and that is because I think we need to create its pointier horns. Let me add this. Now that's more like it. Now it's starting to look like a travel, and I like it. And now, if you want to smooth this, let me increase the brush size. And the smooth operation is present, hold the shift key, press and hold the shift key and draw. I can smooth out the detail. Maybe let's lower down the strength value to the value of the 40.5, press and hold the shift key. Oh well, that is not an a sculpting lecture, but as you know, we have increased the resolution and now we can add more detail. And same way, these are the voxels work. So which means that by lowering down the axel size, we are effectively adding more and more voxels in this bounding box if I were to maybe you can visualize your axel by creating an A VDB visualized tree. So let's add an VDB visualized tree node. And that is an AVDB visualizer. So let me connect this in here, and here as can see we have these little boxes. So these boxes are the voxels. That is the resolution of our volume, and we can adjust them by decreasing this axel size. And if I were to let's say increase this, if I were to increase this to a value of 0.2, and now heroes can see we have bigger size of these boxes, which means we have a very low resolution. That is why we are getting a very coarse representation of our volume. And if I were to lower down the axel size to lower value and let maybe continue decreasing it, and hers can see by decreasing the axel size, I'm creating more axels and creating more resolution. And thus, we are getting this accurate representation of our geometry. So you can think of the axels as an A three D pixels, right? Because we have these auxel. These are the boxes. So you can think of them as an A pixel. The more pixels you have, the more sharper your image get, right? And I can even explain this in here to make my point. Let's create an grit node in here and I can add an UV attribute from Map node to actually apply an diffuse map onto my these points. So I have node called attribute from map node. So let me add this and view this. And that will use the image file to add an a texture onto our grid. So onto the attribute from map node, I just need to define my map. I can define my map By onto this Services map source that is set to file. That is correct. And now I can just pick any image file that I like to apply onto my grid. So just click on this and in here, let's go into the Houdini pick texture folder. Let's click on it, and maybe in here, we have the option, I think for the preview images. I can do so by right click, and here we have the option to show images. So let's check this and we have some textures. And we also have some more. Let's go back by double clicking on this true dot folder, and that will get you an A one step back. So we are right now in the Houdini directory. Now we are in the Houdini pick directory and in here. Let's find some so think of these boxes, these points as an A voxel. If I were to create more sharper image, I just need to increase the voxel size or sorry, in the pixel size, right? I can do so by going on to the grid. Let's increase the rows and columns by Okay, that is the correct orientation. And by increasing the rows and column, I'm effectively lowering down by the box sizes. These polygon sizes, I'm adding more resolution. I'm adding more pixel to say, I can continue adding more and more pixel and my image will get sharper and sharper. And same way, we have these axels. So these voxels are basically an A three D pixels. I think it's enough on the topic of axels. In the next lesson, let's explore the difference between the VDB volume and the Houdini native volumes. 24. 24 Houdini Volumes Vs VDB Volumes: Let's talk about the difference between the Houdini native volume and the VTB volumes. And in here, let's create an geometry node. First, we need to create an empty sp container. So let's dive inside. And in here, first, I'm going to create an a polygonal piece of geometry that later we will going to be converted into volume. And for that, I'm going to this time add an Traors in here. Let's add this primitive so that we have a nice circular hole at the center. I'm going to first, let's lower down its radius and we have this uniform scale. Let's increase the uniform scale and maybe further lower this down its inner and outer radius. In here, I'm going to now convert this into volume. And first, I'm going to convert this into Houdini native volume, and for that, we have a node called IO offset. Let's add this and connect this. And now we have successfully converted our polygonal geometry into volume. And same way, if we want to convert this into VDB volume, we have the nodes VDB. So let's drip VDB from polygons. And we have that node. Let's add this, connect this in here and view this. And by default, VDB from polygon node convert this piece of geometry into what we call the surface VDB. Surface VDB is still a volume. It's just displaying this geometry as an a surface, but it's a volume. It's not an actual polygonal piece of geometry. If I activate my selection tool and heros can see, I do not have access to this polygon or if I change these two points, heros can see, I do not have access to any of that because it's not an a polygonal piece of geometry, it's a volume. Let me activate my this. Tool. It's just displaying this as an A surface. So surface is an A kind of volume. We can convert this into fog volume. So in here, let's enable this fog DB, and now we are creating two volumes. So one, we have the surface, and now we have this fog volume that is named to tent. And we can check if we press hold the middle mouse button. And here as can see. We have an A one VDB volume, and in here, we have these two VDB volumes. The first one is the density and both of them, we are calling both of them density, and that is not correct. We are actually calling one surface and the sacrament to density. Let me see why it's showing me that now we have this. We have these two VDB volumes. I think it was just a matter of refreshing these nodes. Now, five present hold the middle mouse button, hers can see it has refreshed itself and now we can see two VDB volumes because we are creating two volumes. And in here, we can see their name. The first one is the surface VDB, because we are calling this surface and the second one density. And we have the auxel size information. Here we have the axel size on each axis, that is the X xs, YXs and Z axis, and we have the overall axel size. So let me uncheck this distance VDB. So now we are only creating a one volume fog volume. And now if I press and hold the middle mouse button onto VDB from polygons node, and here is can see we have one VDB volume and we can see its name. And same way, I can name this Houdini volume as well. If I go into the ISO offset and middle mouse button. Here you can see, we can see the one grid volume, which means that it is an Houdini volume. But in here, it says no name because we are not assigning name to this volume. So to assign the name, let's go into the ISO offset and here is can see we have the name filled, and right now it is empty. So we can call this name anything. We can call this one, let's say, My volume, wi tapping my vol. Now if a person hold the middle mouse button, and here is can see we have the name uppear. So we have one grade volume and we have the name. So maybe let's change this one to the same name as we have in the VTB density. So let's go into the IO outside and rename this name. And pressenHld middle mouse button, and here we have the name. What is the difference between these two volumes? So the difference is that Houdini native volumes, they are not spars, and the VDB from polygons, these VDB volumes are more efficient because they are sparse. Does that mean sparse? Sparse mean that if you take a look at this geometry, let me view my original geometry. Hers can see we have right here. We do not have any geometry information. We have the geometry right here. So we are adding vax cells where we have the geometry, and we are discarding this empty space to save our calculation time. That is why these VDBs are more efficient. But these Houdini native volumes, they will just take a look at the bounding box of our whole geometry. So if I add an A bound to visualize the bounding box, we have an end call bound that will draw the bounding box. If I press and hold the middle mouse button here can see we have this size that is the overall size of our geometry. These are the bounds, we can create them by we connect this here onto this bound node and activate. And here as can see we have this bounding box information that is the overall geometry. I can view this and maybe template this. And here can see inside of this bounding box, we have our geometry. So the Io offset, this pudin native volume will use this bonding box and add axels everywhere inside of this bonding box. And Hears can see we are adding axel on all of this bonding box, and that is not an efficient way of calculating the volumes, so that is why we have these VDBs. They are more efficient, and we can actually visualize the active vaxel if we go into the VDB from polygon's node and we can view these voxels where we have the voxels. We can create an AVD visualized tree node. So let's add an VDB visualized tree. Let's add this and connect this in here, and heroes can see we are visualizing this, but right now the visualization is not accurate. So let me go into the VDB visualized tree. And Heres can see we are currently visualizing these leaf nodes. So let me uncheck this. But I want to visualize the active axels. So in here, let's enable the active axle option, and heres can see we have these axel represented as NA points. And we can change the visualization. Let's change these to wireframe boxes or we can change these to solid boxes and Heres can see we have these three D pixels, these ax only where we have the geometry. If I were to let's say increase the resolution, which means that we need to lower down the axel size and remember that we are manually saying that that is the axel size and Heros can see we have this box, these are the axels. We are adjusting its size onto the auxel size. Let's lower this down to a value of 0.05. I can continue lowering this value down to create more high rise representation of our volume and Heroes can see we are adding auxels only where we have the geometry. And we are not adding voxels where we do not have the jumped information. So we are saving out a lot of calculation time. That is why we call this one VDB, that these volumes are sparse. And here you can see that we have this sparse representation of these voxels. But if we go into the Io offset these Houdini native volumes, let me increase the volume sampling to add more resolution. And I can same way, let's create the visualizer to view the individual voxels. And to actually visualize these voxels, we do not have an visualizer. For this deniative volume, but we can create our own VDB visualizer for these hoinative volumes with the wobs and for that because it is an a volume, hers can see, we have one grid volume to work with the volume, we have an a volume wb same way, we have the attribute wb if I add an attribute wb and heres can see, we have the runover method, the points, primitive and words C but we do not have option to run over volume. And that is because we have a separate volume wb node. So let's add volume wop node. And here we have the volume wb. Let's set this and connect this in here. And what Tit will do, it will run over these axels, because it is a volume and we are working with axel. This volume b will run over volume. So if we dive inside, we are in the same context, we are in the wax Builder, that is not another context. If we right click and take a look at the node, and here is can see we have all of these same nodes. But it's just that we are running over these volumes, these boxels and onto the attribute bop same way we are running over these points, but now we are running over volume. We are working with voxels. So let's dive inside the volume b, and let's dive inside. And here as you can see we have this wax builder, by default, this node different, and we have additional bind node, this built in bind node, and we are importing the density volume by default, and we are outputting as an A density volume. So nothing is happening here. And that is why it is essential. It's actually not essential. It's just easier to just name your volume to density because when you create volume op node, it is by default designed to work with the density volume. So here we are reading the our density volume. So what I would like to do, I would like to add a point where we have the axels because we are running our axel every axels so I want to add an A point. For that, we have a node called Add Point. Let's add an A add point node, and here is can see. And for this one to add the point, it needs the point position. So right now we are adding an A point at the origin at 00, and if I zoom in, maybe enable my point display. Hers can see at the origin, we have a one point. And if I were to adjust its position, I can see that this is moving. Let me check this and visualize. Here's can see we have the point at this position. Let me zero this out. But what I would like to do, I would like to control this point position where we have the axles, which means I can just connect this into the P. Now, this P means the axel position. Because we are working with axels with volumes. So let's connect this P, and it will add point where we have the axel. And heroes can see we have all lots of these points. So these points represent voxels. Heroes can see if I were to let me template my bound. Or maybe let's just view the bound and tramplate these points, and hers can see we are filling our entire bound with these voxels, and we do not have any sparsity in hair. That is why these volumes are not efficient, and maybe we can actually add an box in hair and for that, let me remove this. And to actually create this box type visualization, we can create an a box in here. Simply just create an box node. And because we have these points, which mean we can create a copy to points node. Let's add this, and that is the geometry that I want to copy, and let's use these points where we have these oxels and before I activate my copy points, let's go into the coopted points and enable pack and instance so that we are packing our geometry. And now let's view this and hers can see now we have this scaling issue. First, it is right now it's working very slowly. So maybe let's lower down the uniform sampling to lower down the boxel size, and it's still lagging. Let me check. We have the pack geometry. Let's view this. We are actually working with quite a lot of these voxels. So maybe let's low this value down even further. So now we have a much snappier interface because we are creating a lot less voxels. Now, let's use the voxel size to set out this box size. If I press and hold the middle mouse button, hers can see we have the axel size, and axel size is 0.2. So what I can do, I can create an AP scale attribute in here to control this box size because right now, if I were to just change the uniform scale and view and Hers can see I'm just manually scaling down these boxes. But what I would like to do, I would like to create an A P scale value in here to procedurally set the scale of this box to accurately create this VDB visualize this visualizer. And for that, let's import this auxel size attribute. Here as you can see, have this information present axel size. Let's read this and set this axel size as an A P scale attribute. And for that, because we want to set this P scale attribute onto these points, which means I need to create an A point angle by creating point wop, we could use the attribute wrangle to write our own ax code, but I think it is much easier to just use the wop. So in here, I'm going to create an attribute wb and by default, it is set to run over points. So let's dive in sign. Inside of that, you know that now we are in the same ax builder, but now we are running over onto these points. And to actually set the P scale, you know that we can create an A point export node. And in here, we just need to type the name of our attribute, and I want to create the B scale attribute and to actually read this auxll size, this waxll size attribute. These attributes are called the primitive intrinsic because we have Heres Conceive we have one primitive. The volume is called volumes are in the primitive category. So Heroes Conceive we have one primitive attribute name, and inside of that, we have this density volume. So volume is actually goes into the primitive categories, but they are volume. So let's go into the attribute warp and onto the geometry spreadsheet, and we need to go into the primitive. So let's go in in here, and here as you can see we have an name attribute and its name is set to tensity. The same name that we have setted in this name field density. So that is the same name. And to actually view this voxel size, this attribute, these are what call the primitive intrinsic attributes. And to view these intrinsic attribute, heros cananc we have this option intrinsic. Let's click. Heres can see we have all of these intrinsic attributes, but I am interested in my axel size. So let's enable this and Heres can see we have the axel size information, and it's 0.235% hold the middle mouse button and Heres can see we have the axel size on each axis, X, Y, and Z, and its value is same in all of the axes. So that is called auxel size. Hers can see auxul size that is the value attribute. And to actually read this intrinsic attribute, let's dive inside the attribute wop and for reading the intrinsic attribute, we cannot use the bind node. You know that we can read the attribute by using the bind node and typing the name. To actually read the intrinsic attribute, we have an separate node called prim intrinsic. So let's add and here can see we have this primitive intrinsic. Let's add this. And in here, we need to define the file from where we want to read the attributes from, and we can either use this output of input one, two, three, four. So these are these inputs. Here as you can see, we have these inputs. So which means onto the file, I can just connect this one, which means that I want to read this from this very first input. In here, we need to type the signature and the attribute name that we want to read. And right now we are reading the transform and it is an A matrix. But I want to read my auxel size, and we know that Vauxhal size is an A vector. Let me find vector three. It has three components. Let's dive inside. Sorry, go back and check eroskenc. We have three values, which means that it is an A vector. But we can actually change this. Let me go into the primitive intrinsic and we can change this to float and type the name. What that will do, it will just only import this X value, this very first value. So we can actually say that it is an e float, even though it's not an e float. And now we need to type the name of the attribute that we want to import. I want to import my axel size. That is the intrinsic attribute that I like to read. So let's click, and now it will import that and spit out from this in here. So which means let me move this aside, and let's connect this in here. And now we are using this axle size to set our scale. And I can check by going onto this, change these two wireframe shading, visualize this as wireframe, and here as you can see, none of the boxes are intersecting because we have set the size accurately. So we have very accurate representation of our axel where we have all of our axels, right? And heroes can see we have all of these axels fill inside of our whole geometry, and we do not have any sparsity. I can go into the IO of set. I can play around with the max size to add more resolution and heroes can see as I continue to increase more resolution, my viewpoint is getting slower, and that is because we are adding a lot more aux cells, and we are also adding vax cells where we actually do not need and you know that we actually do not need to add axel at the center, but we are still adding the axels as well to the whole bounding box. DBs are more efficient and you should always use the VDBs for creating your own volumes. And there is come time when we need to convert we do need to use our Houdini native volumes. And for example, the Houdini Pyro solver or smoke solver. These solver use Houdini native volumes, and we simulate them in Houdinative volume, and later we will convert them to VDB to save out our disk space to actually take benefit from the VDBs that is the difference between the Houdini native volume and the VDB volumes. 25. 25 SDF Volume Vs Fog Volume: Now let's take a look at the different types of volume the two types that we have the STF volume, and as well, we have the fog volume. So let's see that. So in here, let's create an A geometry node and type inside. And in here, I'm going to create an A rubber toy geometry. So let's at this. Now let's convert this into volume, and I'm going to convert this into VDB volume because VDBs are more efficient because they are spars, let's convert this into VDB volume by adding an A VTB from polygons node, and let me add this and connect this. In here, we have successfully converted into volume, and by default, VDB from polygon node will convert this into an A SDF volume, and that is the SDF representation of our geometry, and we are naming this our volume to an Asurface volume. And same way, if you want to convert this into fog volume, you know that we need to just enable our fog VDB as well. Now we have both of them. Let me uncheck this Tristan VDB. And now heres can see we have the fog volume, and the fog volume is used to create the volumetric type of effect, for example, creating the clouds or the fog or for example, the smoke simulation or explosions, all of them are fog volume. And the SDF volume here, the surface representation, we can use the SDF volume to create all sorts of geometry operations. For example, we can use the volume modeling techniques to use the volume to create more complex Booleans operation, the combination and extract subtraction. Let me show you what I mean. Let me lower this down to let me first increase the resolution, which means we need to lower down the axel size so let's lower this down to a value of maybe 0.01, sorry, not 0.051, but 0.01. Here as you can see, we have a much higher representation of our geometry, and it is an A volume. Remember that it's not an a polygonal piece of geometry, which means I cannot have access to its primitive because we do not have any primitives and the points, we do not have any points because we are right now working with voxels and inside of the voxels, we have the information. So where we have the geometry, where we have the polygons, the vax cells will get an a value of one, which means we have geometry in here and we are visualizing them as this surface, but it's an a volume, and to actually convert this back into original polygonal piece of geometry to convert this into polygons, we have a node called convert VDB, so let's say I convert VDB node let's connect this and let me add this in here and view this. And by default, the convert VDB node will convert your incoming volume into Houdini volume. And here's can see, we have the convert to option to volume, which means that we are converting this into Houdini native volume. And if I were to middle mouse button, and Here's can C we have one grid volume. One grid volume means that the Houdini native volume. And before they convert VDB into the VDB from polygons node, Hees can C we have one VDB volume. And this convert node is converting back into Hutini native volume. Also change its parameter, and we can change this to VDB, let's say, if we have the incoming volume, the Houdini native volume, for example, the volume that is coming from the smoke solver when later we are going to create the smoke simulation. Smoke solver will output Houdini native volume, and we can use the convert VDB to convert our incoming hot native volume into EDB volume, or we can convert this into polygons. So let's enable the polygons option. And now Hears can see we have our polygonal representation. It's not a representation. Actually, it's an actual polygonal piece of geometry. And if I were to middle mouse button, and Hears can see, now we have the points and primitives, which means that we have the actual geometry. Now I can able to select my individual points. I can activate my primitive and select all of the primitive, the edges. And here as can see we have this polygonal piece of geometry. And because we are in here working with volume and we are converting this pack into polygons. Into the volume, we can use these VDB nodes if I type VTB and here as you can see, we have quite a lot of VDB nodes to create all sorts of different operation with the volume. And first, let's create the Booleans type of operation, the SDF. We can combine multiple volumes. We can subtract them, and let's see how we can do that. First, I'm going to, let's say, I want to punch a hole in this rubber toy. And for punching the hole, first, let's create an geometry. And for that, I'm going to use an A slender, and slender is called tube inside of Houdini. So let's add this and let me view my this geometry. And in here, let's add the end caps to add the end caps at the end. So let's enable this. And in here, let me enable the columns to add more resolution to create more smoother surface for this geometry, and maybe let's lower down its radius and I can increase its height to create a longer. Maybe let's increase its height to value of something 2.85. And after that, we need to convert this into volume, and for that, let's set an VDB from polygons node because we have the polygon as an incoming geometry. So let's set this. And now we have successfully converted this into volume, and let's lower down the auxel size. I'm going to lower this down to a 0.01 to add more resolution. Now we have these two volumes. We have this VDB polygon this Rubatoi and this cylinder. And to actually combine this, we have an node called VDB combined node. So let's add an VDB combined node in here. And in here, I can use the A VDB, that is VDB A, and I can convert this second input, and that is the our B VDB B volume. And now let's view the VDB combined node. And in here, Harris can see right now I am not combining them. It's just outputting this VDB A. So let's enable the parameter of this VDB combined node. In here, we can change the operation. So let's click. Here is can see we have quite a lot of operation. We have this Boolean operation, so it is written in here. It says SDF union, which means we can combine both of these SDF volume, this A volume and the B volume. In here, I can change this to SDF union. Here is can see we are uniting both of these volumes, and I can also change this to SDF intersection. Now where we have the intersection, we are only outputting the intersection volume, or I can change this to SDF difference, and that will just create the difference, and it will actually using the SDF difference, we are basically subtracting this DB B from or this VDB A, so in here, maybe let's add an transform node to let me adjust the position of my this cylinder. So after that, we have converted our volume. I can add an a transform node. Let me view this VB combined node and in the node editor, let's select the transform node. And when the node is selected, hover over to the Vpod and press Enter so that we have this handle. So let me move my this tube on this cylinder. And here is can see I am punching hole where we have this volume, and I can even rotate this. So let's rotate this our box, and we should have this our hole. I can move this around and I can increase the radius. Let's increase the radius scale. Okay, that is quite big radius. So to snap your interface, maybe let me lower this value down. So let's go into the VDB combine with this. Now we have this much bigger hole. And now we can convert this back into polygon by adding the convert VDB non, so let's add and convert VDB, connect this, and to convert VDB, let's change the to polygons. Okay? So now we have the polygon representation over this polygonal piece of geometry. And to hide the wireframe, I want to see my smooth geometry. So let's hide this wireframe. Let's go in here and change this to smooth shaded. And here we have this polygonal piece of geometry. And we can also add some other operation. For example, if I go into the VDB combine, I can change this to SDF union, and here is CC now we are uniting both of our geometry. And it is uniting them accurately so that we do not have any weird geometry uniting that we have that we can get with the basic Boolean operation. So which mean if I zoom in, if I go inside of this geometry and Hears can see, we have these holes accurately. We have punched this hole accurately sorry we are not punching the hole. We are uniting them. So let me zoom in. And Heres can see we have this union pretty accurately and we are not getting any types of weird artifacts in our polygonal piece of geometry. So you can really create your crazy complex geometry with these volume modeling techniques. Can combine multiple pieces of geometry, for example, let's add an pig head in here. Let me add the pig head, and let's connect this into this VDB from polygon node. And let me lower down the scale. I'm going to let's change this to half value. And to the transform node, let's adjust its position and rotate this And let's go into the convert VDB node, and hers can see we have this combination. We have the combination of both of these geometry flawlessly, and it's working as if we have modeled them like that. So you can actually create crazy complex geometries with these volume modeling techniques that is called the volume modeling. And after that, we have some other operation. For example, we can smooth out entire this SDF. So if you type VDB smooth and Heres can see we have these three, we have these two smoothing operations, VD be smooth and VDB smooth SDF because we are working with SDF volume, let's add an VDB smooth SDF where we have the VD we combine. After the VDB combined, we are in the volumes, we need to connect this in here and view this and Heres can see we are smoothing out our entire volume. Let's go into the VDB smooth. I can change the filter voxel radius to really exaggerate the smoothing. I can change the operation, change this to gaussian. We have these different types of algorithm for applying the smoothing and after conversion, and Heterosc we have this very smooth conversion of geometry. And let me activate smooth Wireshd to C and scan C. It is an polygonal piece of geometry. It's not a volume, and it is very smooth and it's a very complex piece of geometry. And we also have some other operation. So after the VDB combine, we can add the noise in here. So if I type the volume noise, let's add volume noise node in here. Hers can C, we have these three nodes. We have the volume noise fog and we have the volume noise STF because we are working with SDF volume, so let's add the volume noise SDF node. After the VD we combine, I'm going to connect this in here. So what that will do, it will just add the noise on top of this volume. Let me activate this and Hears can see it is using the surface volume, and we are adding the noise in the surface volume, that is correct. We have this noise. We are using the simplex noise. We have fast noise. We have multiple types of noises. Maybe let's change this to simplex, and in here, let's increase the amplitude to really exaggerate the effect. Let's change the amplitude value of one. I think the value of one is too high because here can see it is calculating. Let's I'm going to press escape, but it is actually calculated, but it was taking long. So if the volume is taking long, you can press escape to cancel the operation. But now we have this really weird volume representation. So maybe we need to just change this very lower amplitude. Let's change this to 0.2, and let's change this to 0.3. Okay, so we are adding the distortion in our geometry. And now we are adding the VDB smooth node, and VDB smooth node is actually right now, it's smoothing out all of this geometry. So maybe let's change this to mean value, low down the iteration, and it's breaking. Median value, let me change the different type of algorithm. Okay, I think the median value is working fine. And after the convert VDB, now we have our polygonal piece of geometry. You can use the volumes to actually create your create you can model your geometry. That is called the volume based modeling. Now let's take a look at the fog volume. So in here, I'm going to create a rubber toy in here and let's create an VDB from polygon node to convert this into VDB volume. And this time, let's use the fog VDB. So let's uncheck the distance VDB and enable the fog VDB. And in here, I'm going to lower down the waxel size to create more high representation, more high as volume. And here as can see we have this fog type volume. And we can use this fog to create volumetric type of effect, for example, the fog or clouds. So maybe let's turn this Rubbertoi geometry into fog. And right now, we have this very smooth representation of this very smooth looking ruberty and I can adjust the tensity to create more thicker volume right now. Our volume is thin. To actually visualize this as an then, we can actually create an volume. Visualize nod. Let me add an A volume, visualize and let's connect this. Please note that this volume visualize is just for the viewport visualization only. So if you want to actually adjust your visualization at random time, we can make this adjustment in our actual material. So later when we are going to render this inside of solas, we have the material. So we can actually adjust the same setting at our material level and we will get the same result at random time. The volume visualization is only just for the viewport visualization. In here, I can increase the density scale. So let's increase this. And here you can see, we are multiplying our density volume value to actually create an thicker volume. And in here, let's maybe calculate the ambent oclusion and for that, I'm going to enable the shadow color. Sorry, ambient shadow. So let's enable this. And by enabling the ambient shadow, we are basically creating the ambient oclusion and we can change the amid eclusion color by enabling this send ambient color. And onto the occluded color, I can change this to anything, for example, the blue because it's in a cloud, or maybe let's desaturate this value, and I can increase the shadow scale to create more thicker type of our shadows. Or maybe let's change this to default black. And let me lower down this shadow scale and it's just the viewport visualization. And let's increase the density value and let's maybe add some noise into this volume. And for that, after the conversion, let's add volume noise by typing volume noise. At this time, I'm going to use the volume noise, fog node. So let's add this and connect this in between and let me view this. I'm going to actually view this with my volume visualization. So let's go into the volume noise fog and in here, we can adjust the parameter of her noise. Let's play around with the amplitude. And right now, I cannot see the effect. So maybe let's change the range. It says to positive range. Let's change this to zero centered. And now I can increase the amplitude, and here's can see, we have some cutoff. And onto the element size, we can adjust the frequency of our noise. So maybe let's lower this value down to 0.1 to create a high frequency noise. And here's can see we have some breakups going on. Maybe let's change increase the element size to 0.5 and I'm going to create this bigger type for this noise. Let's just the amplitude, and we can actually also animate this noise as well. If I enable the animation, let's enable this and let's enable our playbr if we hit play and Hears can see we also have the animation let me stop this and go back and you can adjust your animation speed that's enable this menu, and here we have the pulse duration. So if you increase the pulse duration, you are decreasing, you are creating your animation to an slo mo. So we will have a slow evolution of our noise. And same way, if I were to decrease the pulse duration, let's say value of 0.5, 0.1, and now we will have the faster evolution because we have shorter pulse duration. So we will get a very fast animation and Hears can see. That's how you can control your animation. Let me uncheck this. And in here, we can adjust the offset of noise, and after that, let's add another noise to layer different types of noises. So for this one, I'm going to just duplicate this volume noise and connect this after that. And for this one, I'm going to create a more high frequency noise. So in here, I'm going to just lower down the element size a value of 0.1 to add more smaller breakups. And onto the offset, I can play around with the offset value. Let's zero out to change the offset to its default values. I can play around with the amplitude, and after that, I can just keep laying down these noises to create this MCloud like looking shape. So that is the difference between the SDF volume and the fog volume. So now in the next lesson, let's create the clouds by using these VDB volumes because right now we are using these just basic volume noise node to add some noise in our fog volume, but we also have some dedicated nodes for creating the clouds. And we are using the fog VDB for creating the cloud. So let's take a look at that cloud creation workflow in the next lesson. 26. 26 Clouds Creation Workflow: Now let's take a look at the cloud creation workflow with using the fog VDB. In here, as always, let's create an a jump tree node and dive inside, and in here, first, we need to create if you type cloud if type cloud in here, and heres can see we have all of these different types of nodes. To create the clouds to shape the cloud and all of them. And if I also go into the environment, this menu, and in here, we have the sub menu, and in here, we have the clouds. And here we can create the clouds. We have all of these same nodes. And we can also go into the sky. And in here, we also have a node called Skybox. So maybe let's create an A skybox in here. And let's add this, and now skybox has been added. And now, if I press and hold the middle mouse button, and hers can see, we have an A one VDB volume. So we have this density volume. It is an AFOg VDB, and we have voxel size, and I can see that it is filled with some volume because we have some megabytes in here. So here can see we have this instance location 3.68 megabytes, which means that we do have some value inside of this VDB volume. But right now, I cannot see my clouds volume, and that is because we need to zoom out. And let me take a look. Hers can see on top, we have some clouds. And to actually view all of our geometry, you can right click and click on this home all button by clicking on this home Houdini will zoom out to all of your scene where we have all of our geometry. Okay? So in here, I can see this beautiful clouds scape. And now let's go into the parameter of the skybox. And at the top, we have the axel size. As you know, auxel size is the resolution, which means if we want to create more high rise version of our clouds, we need to decrease the axel size. I'm going to just keep the boxel size to five for faster feedback. And in here we have the seed. That is the random seed because we are using all of these noises to create these clouds. So if I were to change different feeds, and here as you can see, we are getting the random variation of these clouds. I can change this to any seed value. And at the top in here, we have the fier tab, and in here, we can define the coverage. And if I were to change this to all the way up to one, and now we are filling out all of the bounding box with clouds, I'm going to just lower this value down to default 0.5, and we have the precipitation. And that is, I think for the precipitation control that if there is going to be a rain or not, and if I were to increase the precipitation and here as you can see, our clouds are getting thick, which means they are likely to rain. And let's zero this out. And we also have this anvil. If I increase the envel, it will just increase this thickness of our cloud and if I were to zone load this value down here as you can see we have these thick clouds and if I were to increase the envel we will get more thick cloud, we have its height information in here. And we are keeping this bottom as the same. So let's zero out the veil and down here. Let me make this plane a bit bigger. And in here, we can change the L. Let's click on this override L option. And remember, that is just for the viewpot visualization only. It's not going to apply material, it's just for the viewpot visualization. Right now we are using the ambient oclusion. We can change this to reverse occlusion and that will create more cloud like visualization. And maybe let's change this to ambient clusion so that we have this better feedback for these shadows. And you can collapse this menu, and here we have the density scale, and also we have the parameter for the shadows. Let me collapse this. And first, we have the sky setup, and in here, we can define the size, how much, how big we want our cloud scape to be. I can lower this value down. I can make this value bigger. These are the basic size, and we have the option for the center to place it wherever we want. And down here we have the sky layer, and first, we have the altitude, altitude adjust this Y position. And if I were to lower down the altitude and errors can see, I am effectively adjusting my Y position. And you can adjust the altitude and we have the option for creating more thick clouds and errors can see if I were to increase the thickness, now I'm getting these thick clouds, and I'm going to just make these values to defold and to revert these values to default, you can either right click on the parameter and in here, you can change this to revert to default. Click on it, and there we have it these default values. And you can also make these values default if you press and hold the Control key and middle mouse button on the parameter, it will make these values to default. If I right click and here as can see, we also have the shortcut revert to default control plus middle mouse button. Now down here we have the sky field, some other option, all of these noise parameter. And onto the next tab, we have the bellowing noise, and in here, we can adjust the element size. If we were to decrease the element size, we are creating more of these breakups we are creating more of this high frequency noise, and I can increase the element size. And in here, I can add some worldly detail. It will break up this noise even further. And here as you can see now we have a lot more detail. We have a lot more smaller, all of these clouds. I'm going to check this, and in here, we have the alligator noise. We have another type of noise. So basically, we are just laying down all of these different types of noises to create this cloud scape. And we also have the wispy noise. I can enable this to make my clouds whisper. And here is can see by enabling the wispy noise, now we are getting sort of these thin clouds. We do not have the thickness. And animation, we can enable the animation and all of these thing. And that's how basically you can create the simple Skybox. But that is good for creating this environment, this top level, this cloudscape. But now let's see how we can create the hero Cloud. The way that we can create our on hero Cloud by using an A Cloud node. So if you type Cloud and heres, we have all of these nodes for working with clouds. And down here, we have this option cloud shaped end. So let's add this. First, we need to define the shape of our hero clouds. And for that, I'm going to use the Cloud shaped generator. So let's add this and view this and cloud shapes generator has been added. And right now, I cannot see my cloud shapes. That is because our cloud shape is down here at its scale is very low, and right now we have been zoomed out to a 625 units, which means we need to zoom in or I can just press Fk on my keyboard to frame this selection. And that way, I can very quickly frame my camera onto this scene. And here can see the cloud shape node will just create this bunch of sphere, and this sphere will define the shape of our hero cloud. So we have this silhouette. So that's how our cloud is going to be looked like I can go into the cloud shape, and in here, I can increase the shape. Offset by increasing I can adjusting the shape. Offset, I'm basically adjusting the random seed. That is the random variation of our clouds. And in here, we can adjust the point separation by increasing the point separation, I'm increasing the scale of our sphere, and I am creating less of these points. And same way, if I were to decrease the point separation, I am adding more sphere, and thus, we have the smaller scale size sphere. I'm going to just make the point separation to default. So press and hold the Control key and middle mouse button to revert all of these changes to default. On top, we have the initial size. I can change the initial size to make my cloud bigger or smaller, and we have the cloud species. So let's see. So in here, I can change this to humulus. Let's see. And onto the mulus we have these different types of these flatten out clouds, and I can also change this to congestus. And now we have these clouds that have this vertical alignment. I can change the shape offside at the random seed, and I'm going to change this at the zero, and maybe let's change this to the value of default and into the length, I can adjust the length of my cloud. And onto the width, I can adjust the width of my cloud. Let me make this a bit into the revert into the defaults, and we have the option for the distortion. I can distort my shapes, and we have the option for flattening the button, and Hears can see below why we have these shapes flatten out. I can uncheck this, and now Hears can see we do not have any flattening effect. So maybe let's enable this flattening option. And I can adjust by this plane, flattening plane. So let's default this out as well. And in here, I can play around with the rotation of my cloud. So maybe let's change this to default as well. And right now, heroes can see we have these points. If I were to middle mouse button, and heroes can see we have these 427 points. And it is an asphare tie points, which means it is an a primitive type sphere. If I were to create an A sphere, add an sphere, and here as you can see, we have these two types of sphere, polygon and primitive. If I were to add primitive sphere, that is the sphere. And basically, this primitive sphere is just a one point, and it has a certain radius value. So we can set the radius by using this uniform scale, and Houdini is drawing this point as an a sphere, and same thing is happening here. We have these points, and these points are visualized as an Sphere, but they are just point, and with that, we have some attribute. We have an Cloud ID, and we also have the P scale. Now, P scale is important. So cloud shape is generating scattering bunch of points and creating this cloud looking type silhouette with these sphere radius, and it has the P scale value. So now we just need to convert this into fog volume because right now it is not in volume. These are just points. To actually convert this, we have a node called VDB from particles node. So VDB from particles will use the points as an input because we are not working with polygons. These are not polygons. They are just points with the radius value. We need the VDB from particles node. So let's add this and connect this in here and let me view the result. And here as can see we have the surface volume, surface type volume. So surface type volume is the default settings for all of these converting VDB nodes. So let's go into the VDB from particles, and let's uncheck this surface VDB, but enable the fog VDB. And now we have the volume representation of our cloud. And we can adjust the resolution by decreasing the axel size. So let's lower this axel size to an MIB value of 0.05 to create a bit sharper cloud, and heroes can see, we are getting this accurate silhouette, and that is because of the P scale value and the VDB from particle node will use the P scale value to set the scaling of this far VDB. And if I were to, let's say, remove the P scale attribute. So if I were to add an attribute, Delete node inhere, and I'm going to just click and inhere check delete non selected, which means we are removing all of the attributes and heres can see if we do not have any attributes, but we just have this basic shape. Now if I view the result and heroes can C, we are getting this thick blob, and that is because of the p scale. We do not have p scale, so the VDB from particle node will use this point radius scale to set the scale. I can adjust the scale by adjusting by this parameter and heroes can C, we are manually setting out this p scale value, and that is why this p scale value is essential. So let me remove this attribute lead node and heros can C, we are getting this lot smaller scale because now this will act as a multiplier of our original p scale value so I'm going to just change these two value of one, which means that we are completely choosing the values, p scale values that are coming from this cloud shape node. So let's go into the cloud VDB from particles. Now we have the fog VDB. And now let's add some of these noise disturbance onto these clouds because right now it is a very smooth looking cloud shape. In here, let's type Cloud node, and in here, we can see all of these nodes. So I'm going to just add an Cloud noise node. So let's set a Cloud noise and click on it. And with the result and here is you can see, we have some noise happening in here. I can increase the amplitude. Let's continue increasing the amplitude. I can really break up my cloud shapes, and I have some octaves. I have the element size. This one we have some override look option, which mean we can calculate the ambient occlusion to better visualize in our VPOd. So let's enable the override look. And now hers can see I am getting a much better representation of this VPOt visualization, and same way onto the ambient occlusion, we can change this to reverse occlusion that will create this more accurate cloud looking visualization. Let's change this to Embed occlusion. Same thing. I can play around with the density and play around with these shadows. I'm going to just keeping them at the default and same thing onto the pillow tab, we have the noise. I can play around with the amplitude to increase the amplitude of my noise. I can lower down the element size to add the smaller scale details. And let's add an word detail noise as well that will further breakdown this noise. So maybe let's lower this down amplitude value to an value of 0.1 because I think zero point let's maybe change this to 0.3. We have a lot of breakups. I think the value of 0.1 is fine. I like these breakups. And let's go into the advection tab and let's enable the advection. This advection will just further distort this primary noise. I can increase the amplitude scale. Let's continue increasing this. And I think we need to lower down the element size, and that will effectively just distort this primary value noise. Let me increase the element size and lower down this element scale. So we are getting some breakups in here and to actually capture more of these tree tails, as you know, we need to increase the resolution. So I'm going to just change this to value of 0.01. And it is taking longer to calculate, but we will get a higher resolution volume, and hers can see. So for faster feedback, I'm going to just increase the axel size so that we have a bit snappier user interface. Let's go into the cloud noise, and onto the processing tab, we can define the number of noises, and we can if I increase the number of noises to two, and that means we are creating these multiple layer of these below noises. And I can play around with its parameter. We have the expand scale. And right now all of these options are not very snappy because of the high resolution. And after that, we can just keep laying down the noises. I'm going to add another noise. This time, let's add an Cloud wispy noise. Let's add this and connect this. And here as can see we are creating this wispy type noise. Let's bring up the parameter. Here I can adjust the amplitude. And same thing, we have the element size. I can increase the element size to create high frequency or low frequency noise. I'm going to just create a high frequency noise, and maybe let's lower down the amplitude value and same thing advection that will restore the noise. And onto the velocity, we also have the option to enable the wind. Let's enable the wind. And that will use this direction to add a wind type deformation. So I can increase the wind strength from here. And hers can see right now we are using the wind type in the X direction. And heroes can see the noise will affect as if we have the wind and it is blowing out the cloud onto the X direction. And maybe let's increase the amplitude value to one, and heroes can see our cloud has been eaten up by the wind from the X axis. I can change this to minus X by changing this direction to minus one. Let's play around with this value to exaggerate the effect. Let's keep the two a value of one and go into the wispy noise, and this time, I'm going to just lower down the amplitude value. Let's lower this down to maybe a value of 0.5. And after that, I can add another cloud noise in here, and this time I'm going to just add in a simple cloud noise. So let's add this and connect this in here and I can adjust the amplitude, and right now, it's calculating. Okay, I think it has been calculated. Let's increase the amplitude, and heroes can see we are creating this very nice looking cloud and we are getting some lot of breakups. So you can just keep adding these noises and you can keep massaging this hero cloud noise to your own liking. And in here, Herz can see we are using this simple cloud shape generator. We also have some other options, for example, if type cloud and Heroes can see we have this cloud shape from polygon node. So let's add this. That we expect an e polygonal geometry, so which means I can create an a rubber toy by this geometry. And connect this in here and let's plug this. And what that will do, it will just scatter the points. It will pack these spheres. I can go in here, I can play around with the packing density to create more or less of the sphere. Again, as you know, these are just points, which means we need to connect this into VDB from particles, noid particles to convert this into actual volume, and let's view the cloud noise with the cloud noise. And I think we need to adjust the parameters. So first, I'm going to just take a look with this cloud bellow noise. And here we have the cloud shape from this rubbery and we also have some other option let me find. Let me type this here because it was cutting off. So into the cloud, we also have this one cloud shape from line. So let's add this. What that will do, it will expect an A line. I'm going to create an helix node to create an A line. So let's view this here here cans, we have the helix, this spring type. Let's bring up the parameter, and we can adjust the parameter. I can adjust the height, I can adjust the turns. I can adjust the radius. We have this radius scale value, all of these options. Now I can just connect this in here and let's view the cloud shape from line and here as can see it is just scattering these bunch of sphere along with these helix. I'm going to increase the point separation for creating more or less of these points. So now we just need to plug this into VDB from particles node. I'm going to just plug this in here and we should start to see the clouds and here is can see. We have these clouds and they are based on our spiral, so I can adjust its height and here is can see. We have this visual live feedback. So that is the basics of creating the clouds. That is the cloud creation workflow. 27. 27 Smoke Simulation: Now that we have the good understanding of volumes, now let's create our very first simulation. We're going to create the smoke simulation, and we are going to create the smoke simulation inside of Doubs inside of the dynamic operators. So Doubs is the dynamic context that we haven't talked about yet. So let's dive inside the daub, and let's create our very first simulation. First, let's create an A jump to node. I'm going to create an A sub container because side of the top net, if I create an atop network, here can see, we have the top net and I'm inside. That is our dynamic context. And in here, we need the source for emitting our smoke simulation. So that is why we are going to create our source inside of sobs. And for sourcing, I'm going to just create a simple box. Let me view this. So this box will act as an emitter, our smoke emission source. So let's bring up the parameter of the box, and I'm going to increase its size. So let's continue increasing its size to an a sum value. Let me zoom out, and let's also increase the size in this axis as well. And now that is an A polygonal piece of geometry. And because we are going to create an Smoke simulation, we need to convert this into volume. Let's create an A VDB from polygon's node. And let me connect this. And right now it's creating the surface VDB because the smoke simulation is an A fog type volume, which means we need to convert this into fog VDB. So let me this and enable the fog VDB. Okay, so we have the volume. And now let's bring this volume inside of Daubs for simulation. So the way that we can do that, here as can see inside into the Dubnet we have some of these inputs. Either we can connect this or you actually do not need to connect this so you can just dive inside. And in here, we can import this source, this VDB from polygons, this volume source inside of top. So let's see how we can do that. So let's time inside of the top net and to create the dynamic simulation. So all of these simulations have a certain type of structure. So let's see how we can create this. First, we need to create an a smoke object. So let's create an smoke if you type. Smoke and Here's can see, we have all of these nodes. First, we have the smoke object and the smoke solver. And down here, we have another smoke object and smoke solver, and Here's can see, it says sparse. We have two types of solver inside of dynamics to creating the smoke sum simulation. We have this smoke object and smoke solver. These are non sparse solver, and the smoke object and smoke clar with spars in here, these are the spars solver, and these are more efficient and faster. So let's use the sparse solvers. First, we need the smoke object. Sorry, I accidentally select the wrong node. Let me remove this and let's type. Again, let's add smoke object sparse. So here we have the smoke object. This smoke object will store all of the attributes, the information, and the data that needed to calculate our simulation. That is why we have the object. So any kind of simulation, either you are working with RBD, if I type RBD, and Here's CC we have the RBD object. And if I add Here's Cc we have the RBD object, and we also have the RBD solver, and here we have the RBD solver. Any kind of simulation, all of the simulation has an object. It needs the object to store your information inside of dobs and to actually calculate the simulation, we have the solvers. Because we are working with smoke, let's create smoke solver. So in here, types smoke solver and Heres can see, we have these two solver, but we're not going to use this smoke solver because it's non sparse. We are going to use the smoke solver sparse variant. So let's add this. And Hees can see this one has multiple inputs. And if you hover over to these inputs, you will see some information, and the first one is always the objects. And Heres can see it says object. We will need to connect the smoke object into this object. And in here down here we have the outputting, so we are going to just connect this in here so that we can visualize. And here you can see we have a container, and that container is coming from our smoke object. And onto the smoke object, we have the axel size that will control the overall resolution of our simulation. And here we have the position. I can play around with the center to move by this domain. Let me change this back to zero. And now to actually import our source into Dubs, this source, we need to create a volume source node because we are working with volume. Here's can see VDBs and volume. So in here, let's import our volume source. So let's type volume. And here's you can see, we have the volume source node. Let's add this. And for connecting these sources, let me hover over to these inputs, and this one is the advection. And here we have the sourcing. So which means we need to connect our source into this input of our smoke solver. Okay, it has been connected. Now let's bring up the parameter of volume source. And onto the volume source at the very top, here you can see, we have the input method and it's set to soap, which means I can just pick my soap node that I want to input. So let's click on it, and here we have this window open. So in here, we need to dime inside the object, and inside the object, we have the geometry container. In here, I like to import my VDB from polygon's node because that is a node that is creating volume. So let's hit Accept. And with that, we have imported our source inside of tops, and in here, let me bring up my play bar, and let's hit play. Okay, so nothing is happening, and that is because this very first frame or this domain is actually smaller. If we go back and here as you can see we have this volume very big size, and inside of the top or the smoke object, our container size is smaller. So to fix this, we need to go into the volume source node, and in here, just enable this option enlarge fields to contain sources. So if you enable this, it will enlarge all of your fields, all of this this container size to contain all of these sources. So let's dive inside the top net and hit play. And still I'm not getting my sources, and that is because we need to go into the volume source node. And in here, we are actually not importing our volume. And to actually import this, we have selected our saw path, but we are not importing this density volume. Here, as you can see, we have this volume. We need to import these density volumes separately. So to do that, let's dive inside the top net and inside of the volume source. And at the very top, we have this initialization. So let's click on it, and Hears can see if we can initialize these sources because we are working with smoke simulation, so let's click on this source smoke and when you click this sourcemoke and Heres can see we have some of these fields. Okay, so the three fields has been created. So the source volume, we are importing our density volume and target field is the density. Volume inside of Dubs are called the fields. So the fields mean that we are working with dubs, but they are actually the volume. So the source volume is density and target field is density, which means that our density volume from source has been imported into our density field of this top. And onto the source volume, we have another volume that we are importing the temperature, and we are also importing the volume V for the velocity. But in here, we only have created one volume, this density volume. We do not have any of these volume. We do not have temperature volume or the V volume. But that's fine. We will see how we can create and import them. But simply we are now just importing the density field. So now if I hit play, and heres can see our source has been imported inside of the top net, and it is this volume source going to be import we're going to import our source every frame because of this activation because activation is set to one, which means that every frame we are adding our source. So that is why Hears can see this density volume has been accumulating. If I go back and hit play, and Hears can see it's getting thicker and thicker because we are adding up our fog volume every frame. But right now it's not moving it's not moving. That is because there are no forces acting on it, and to actually make this simulation move, we need to create some sort of forces, and these forces will move this simulation. First, let me take care of this important source issue. It's not an issue. It's an expected behavior because want to import our source every frame. But for this one, let's see how we can animate this activation parameter to only import our source at certain frames. For example, I'm going to add an a keyframe and to add an a key to your parameter, press and hold the old key and left mouse button onto that parameter, and your parameter will turn into green. And it is indicating that the key frame has been added, and we can also see the green mark inside of our playbr which means that we have an a key at the very first frame. So I'm going to just maybe let's go into the frame number, let's say, eight. And in here, I'm going to just change this value down to zero, and now we need to press and hold the old key and click to add another key frame. So now here as you can see we have these two mark, which mean that we have these keyframes. So now let's rewind and hit play. And here as can see we are importing our source at these frames, and now we are not continuously importing our source, and that is why this density volume is not getting thicker anymore because we are just not importing this density volume every frame. So that's how you can actually animate your sourcing if you want your source to be imported in certain frames. And now let's create some forces to make this smoke move. And we can create some forces if you type gas, and heroes can see we have all of these nodes. So all of these gas nodes are designed to work with the smoke simulation, pyro simulation, and some of these gas solvers are for the flip simulation as well. But these are the micro solvers that will drive your simulation. And in here, I'm going to create an excess force. So if you type gas excess, here we have the gas excess force. So let's add this and to actually connect the force, let's hover over to these inputs. And here you can see the very last is for the forces. Which means I need to connect this in here. So gas excess force has been connected, and now let's hit rewind and hit play. And right now, I can see something is happening at the very center. If I zoom in and let's hit play, Hears can see something is happening. O smoke is moving, but let's change the parameter of the gas excess force, and we also have the manipulator of this gas excess force as well, which means we need to select the node. So when the node is selected, how over to the viewpot and press Enter. And that will enable its handle, its manipulator. And here as you can see, we have the active manipulator for the gas excess force. And here we have this cylindrical shape. I can just click and drag to increase the radius. And here we have this arrow. What this excess force will do, it will rotate at the rotation force along this axis along this cylindrical axis, which means that we are going to rotate this smoke simulation around Y. Let me make its size bigger to increase its height because let me hit play. Our source has been aligned in this way, I'm going to just rotate my this force. So let's use its rotation handle, this Y rotation, and I'm going to rotate this, and maybe let's rotate this in here and let's move this cylinder down. And now let's hit rewind and hit play. And now has can see our smoke is moving inside of this axis. And right now, its speed is slow. So let's go into the gas excess force in hair and in hair, we have some option. So these are the start and end points that we are adjusting with the manipulator. Here as can see. These values are tinging. So I'm going to just maybe rotate this down here and we have the global strength. And in here, we are applying this as an eight directional drag. Then we can change this to full drag or we can apply this as an A force. So let's maybe change this to force to have a higher impact of this gas excess force. Now, let's hit rewind and let's hit play again, and now we should see some force. And right now, its strength is too weak. Let me rewind. And either increase the global strength. So let me play around with its slider and let's increase this and hit play again. And now wheres can see we have this higher force value. And let me rewind and we have some other parameter. We have the suction force. We can enable this, but that will do. I will suck our smoke inside of this cylinder. Let's it play. And if I were to continue increase its strength, it will just suck this smoke simulation around around inside of this cylinder. And here as you can see, we are moving our smoke inside of this cylinder. And if I go into this level, here we can see that this smoke has been sucking inside of this clinder. That is the section force. Et me change this back to default and we have the excess force. We have this option. We can increase the speed and we have the speed ramp we also have the strength to actually increase the strength of our excess force, and we have the orbit force. The orbit force is the rotation force. The force that we have where we have this arrow to rotate our smoke simulation. So let's go into the strength and maybe let's play around with the strength value, and let's hit play again. And now, Hearers can see we are rotating our smoke inside around this Y axis. Let me go back and in her maybe let's play around with this slender shape. I'm going to just make this value smaller. Let's hit play again. Let's move this down and maybe let's increase the size overall. And Harris can see as I am increasing the size, I can interactively change my smoke simulation. Let's hit play again, sorry, let me stop my simulation. And Heres can see whenever we are in the dubs, we have this right now we have this yellow indicator, and if I were to go back and hit play again, and now we have this blue. This blue bar means that we are caching our simulation into our ram. Okay, so that we can scrub and here you can see, I can easily scrub. That is because this simulation, these simulation frames has been stored inside of Rams when we are scrubbing, we are not actually calculating. We are just reading the information from our RAM. And if you were to change your settings, let's say, I'm going to just interactively change my this size. Let me move this around. And as I have moved this around, this cache has been turned into yellow, sorry, into orange. Orange means that our cash has been outdated and this case is no longer valid, which means that we need to calculate our cash again. So if we were to move back, and hit play. And if no interactive changes has been happening, and this will turn into blue saying that our cache is accurate and we can use this cache. So if you were to just change some parameter, let's say, I'm going to just increase the global strength value, and here can see as I have changed the parameter, our cache has been gone because we have these changes, and same way, let me select this case access for and enable my manipulator. And if I were to move this in here, and here you can see, as I have moved this, this cache has been changed to orange again, saying that this cache has been outdated and which means we need to calculate this again. It's just an A indicator. So let's go back and hit play. So we are caching our simulation into RAM. And let me activate my view tool and let's go back. And in here, hers can see if I were to view my Dp net. I cannot see my smoke simulation inside of sobs, and that is because we need to actually import this simulation data back into SOP as well because right now, this simulation data only lives inside of tops inside of the dynamic operator. And to actually import this data back, we have an node called top Import. So if you type Dp and here as can see we have this db Import and we also have the top import fields. Because we are working with smoke simulation and the smoke simulation or the pyro simulation, we are working with fields. Fields mean the volume inside of Db are called fields. So because we want to import this volume information or this volume simulation. So let's add an atop Import field node. So let's add top import fields. Let's add this. In here, I'm going to bring up the parameter of this node, and in here, we need to define the top network. We know that we want to import this one from this top net inside of the top Import. Let's click on it, and I'm going to just pick my this top net. That is the top network, top net one accept. That is the top network, and we need to say from which top node that you want to import data from. Know that all of the data has been stored inside of this smoke object. So we need to define we need to select this smoke object because that is the object that contains all of the fields. So let's go back, sorry, into the top import field and let me select my this smoke object. Smoke object sports, hit Accept, and now we have some preset if we click. Here we have some presets which fields that we want to import, and I want to import my smoke simulation. Let's click on it, and it will import all of our fields inside of sobs. So which means I can view by this top import field node and Hers can see. We have our simulation information imported inside of sobs. And if I were to middle mouse button, Hers can see, we are importing five grid volumes. You know that grid volumes are Houdini volumes because it's a simulation. It works in the grid volume, and we are importing density field and the velocity, velocity X, Y, and Z, and we are also importing temperature fields. So that's how you can create your Dub simulation and how you can import your source from sobs into Dubs and how we can import data from Dubs back into sobs. 28. 28 Pyro Solver: Now that we have good understanding of how this Dup network, how we can dive inside the top net and create our own simulation network. We also have the smoke solver available right inside of this sp network. And if you type in here, let's say Pyro solver, let me see, Hears can see if you type smoke, we do not have this smoke solver, but if you type Pyro in here and here is can see at the very top, we have the Pyro solver. Let's add this and here is can see. We have that. And the pyro solver, you can use this pyro solver to create your smoke simulation, your fire or explosion. You can do all of your things with the pyroslver as well. And in here, heroknc we have this simulation type. We are using the sport solver, and we also have our regular tense solver, and we also have the minimal open CL minimal open CL is solver that uses GPU, your graphics card to run on your GPU to accelerate your simulation. And this pyrolver, this soap level solver, it's actually not another solver. It's actually a digital acid, and Heres can see, we have this log button. This log button indicates that it's actually an A digital asset, which means we can double click on this and we can dive inside. And if I double click and Hers can C we are inside of the tops. We are in the dynamics. When we double click or this node, hers can see we have gone into several level D. So we were in the Pyro solver, and we are in the top t and inside of the top net, we have an forces node, and we are right now in the forces node. But it's actually an atop context, the dynamic context. I can go back and to actually view my nodes and all of these settings, I can just right click and in here, let's enable this allow editing of contents. Let's enable this. And when you click this Heresknc our lock has been open, which means that we can now dive inside and edit this Pyro solver. So let's dive inside. And in here, Heres can see, we are right now inside of the sops. We are in the geometry level. And there we have quite a lot of these nodes, and they are just there to set up your perimeter and simulation. And inside, we have this top net. If I zoom in and Hears can see, we have the top net. So I can dive inside the top net. And now we are in the dynamic context. And now if I zoom in and Hers can see we are using the Pyro solver and right now we are using the sparse Pyro solver. And we know that this very first is the object. If I were to trace this, we should see our object. And here as can see we have this smoke object. We are using the smoke object sparse variant. And this will store all of your information. And it's actually an atop context, but with all of these preconfigured node and all of these settings, the Spyro solar hers can see we have some options and their color has been turned into blue. And these are indicating that all of these parameter has been promoted into this level. Let me go back onto the pyro solvers. We have all of these settings. So these are the settings that has been promoted from this original pyro solver, and we have some other simulation nor we have some forces, and all of these things has been preconfigured for us to easier to work with, which means we actually do not have to create our own this network every time we want to create our smoke simulation. So we can just go into the soap level and inhale, we can create a Pyro solver. I can add pyroslver and I can just start playing around with my voxel size. I can go into my sources to input my sourcing and inside of field, we have the shape tab, all of the forces built in inhere, which means I do not need to waste my time every time I want to create smoke simulation. I can go into the top net, add a smoke object at the source and all of these forces. We have all of these things preconfigured with this pyro solver. It's actually an SM top net. It's nothing new. That is the point that I want to make. Let me remove this pyro solver, and I'm going to use this one and now let's see how we can create this simulation with using this soap level pyro solver. And for that, I can just connect this this source, I can view the pyroslver no. And in here, Hears can see this source has been imported, or this source has been working with the pyroslver. I can hit rewind and hit play, and Hears can see we have the same effect. Our source has been imported. And right now, we keep importing our source every frame. That is why this density volume is getting accumulated. We are getting thicker and thicker our smoke. Let's make this force move, which means I can go into the Pyro solver. And here we have all of these settings. First, we have the axel size to control the resolution. And the next step is the bound tab. Bound tab is used for the domain size, and I can limit my max size, and I will first let me make this default, and I will explain to you later what this limit maximum size is. And the next step is for the collision, if you want to import the collision in here. And when we are working with collision, this second input hers can see that is for the collision. And if you have collision geometry in here that you want to collide with our smoke simulation, you can control your collision setting in hair, and onto the sourcing, here we have the volume source, and in here, we are importing our sources. So all of these geometry that has been connected onto this input. Okay, that is the sourcing input. And in here, we are importing our density volume into this corresponding density field of the top net. And same way, we are importing all of our fields. But right now, we only have this one volume. Okay, so that is the sourcing tab, and onto the field tab, here we can control the dissipation and to add the forces, we have this shape node. Let's time inside. In here, we can enable all of these. Forces, I can enable the wind force and I can also collapse its menu. Here is can see we have the wind speed and the wind direction. Right now, we are adding the wind in the X direction. Let's see how this X direction wind looks like. Let me hit rewind and let's hit Play and here is can see our smoke is moving in the X axis. Right now, its speed is slow. Let's increase the wind speed. I'm going to just play around with the slider and it play again, and hers can see our smoke is moving along the X axis. And I can enable some other forces and let me enable the turbulence force in here. So let's enable this. And to actually view the effect, I'm going to just really exaggerate the effect by increasing its value and let it play again. And right now we have some movement, but it's not quite a lot. So maybe let's continue increasing this value to a higher value so that we can really see the effect. Let's play again, and it's still not working. Let me collapse this menu. And that is because this turbulence has been applying onto this temperature field, but right now we are working with density. So in here, let's pick our density field. I can either type my field or I can just pick from here. So let's click on it. So now we are applying our turbulence onto our density field. Let's hit rewind and hit play again. And now I can clearly see my turbulence force acting on the smoke simulation, and it's starting to look like as if we have this dust storm I can go into the next step. Let's go into the next step. That is the L tab, and onto the look here we can adjust the look for our smoke simulation. I can adjust the density if I want to create an ether. And this look is actually applying the material as well. And here we are getting the feedback onto our V boot, but we are also applying the material as well, which means if you were to render this, you will get the same values. And we will take a look at the rendering later. But in here, let's quickly go over through all of the settings of the spyrosl to controlling the simulation. That is the density, and I can adjust play around with the smoke color. Maybe let's change its smoke color to a brown because it's an a dust storm. I'm going to create this rusty color. Let's see rewind and play. And here we have the outust storm looking like simulation. And down here, we have the option to adjust with the fire. But right now we are not creating the fire. That is why this parameter has no effect. And in here, we can play around with the color of our fire. And in the next step, let's go into the advanced tab. And to the advance, we have some solver level advanced setting. We can play around with our sparse solve and all of these advanced setting. And then next we have the output. This output is the top input field node, and this top input field node here as you can see, we are importing this field. So this pyro solver, this output is actually importing these fields back into sobs. And that is why we have this feedback into our sobs because, you know, we are in the geometry, we are in the sobs, and I can still see my smoke simulation. That is because this solver is actually importing all of our fields back in here as well. And we also have some post processing option. I can inhere, convert this into VTB because right now, if I were to middle mouse button onto my Pyro solver, and heroes can see we have quite a long list of the attributes. We have all of these detail attributes, these simulation attributes, and down here, we have some volumes. So we are working with six grid volumes, which means the Houdini native volumes. And we have all of these volumes. And actually, later on, when we are going to create the smoke simulation, we need to store our caches into disk for rendering because right now we are actually storing our caches inside of our RAM. Hers can see, we are storing in RAM. And when we are going to create an complex smoke simulation or fire simulation, and we have the l size set tool lower value, which means we are going to create a higher simulation, your system RAM may not be enough to handle all of the higher simulation data. That is why later we need to add a file cache no if I were to create an file cache no. So let's add this, and that is the file cache done in here. By using this file cache, we can write our simulation data onto our hard drive because, you know, it will this higher simulation will turn into high gigabyte data. We must need to store this onto our hard drive, and into the output, we have the option to convert this to VDB, which means before we can write out our simulation data, we can convert this to VDB, and that will convert your simulation into VDB, and we will take advantages of using the sparsity because VDBs are sparse. And now if I were to middle mouse button and Hers can see, now we have four VDB volumes. So now we are not working with Houdini native volumes, but we have the VDB volume. So they will be much easier, and they will have a much lower cache size to write onto your hard drive. Always convert this into VDB, and we can also use the 16 bit float. This 16 bit float means that we are compressing our volume even more by just lowering down the precision by default, it uses the 32 bit float, which is a high precision value. Rendering, we do not need the 32 bit float. We can convert this pack into 16 bit, and that will even make your file cache size lower and make sure to whenever you're going to write, make sure to check both of these options, convert to VDB, and use the 16 bit float. That is the basics of this pyro solver that is available inside of the sub. And right now we are using the forces that are available into this shape tab, we have the wind, we have all of these forces. But hers can see there are not all of the forces. For example, if I want to create the gas excess force, Hers can see we do not have the gas excess force. So what if I want to create additional forces beside all of these forces? And I can create them if you dive inside the pyroslvn and if I dive inside, and Heroes can see we are in the top context and in here, we have these multiple outputs. Here we have the output for the forces. Here, we have the force output, which means I can create additional forces. For example, if I want to create the gas excess force because we know that this force is not available at the hop level, so let's add as excess force. I just need to connect this inhere, and now this force will work. To actually view this work in action, let me go back onto my this geometry level. In here, I'm going to just disable all of the forces that are working right now. I'm not using any forces that are available in here. Which mean if I can go back and hit play and here is can see there are no forces. But I can see the same effect. And this movement is, you know, coming from our gas excess force. So now I can dive inside the Pyro solver. I can select my gas excess force and to the viewport and press Enter, and we have the same manipulator, and I can rotate this cylindrical shape and maybe let's hit play. I can move this down. I can increase this cylindrical size. Maybe let's increase this size in here. And also, let's play around with the perimeter gas excess force. And in here, I want to increase the orbital force, this rotation force. So let's go into the orbit force, and onto the strength, I'm going to really exaggerate the strength and hit play maybe let's increase this even further, and I can interactively change this force value, and let's increase its global strength as well. And right now we are using the one. This global strength will act as a multiplier. Okay? So we have all of these strength. And all of these strength will going to be multiplied by this global strength. So I can increase this multiplier to even increase the force effect. And let's also apply this as an F force because right now we are adding the directional trag. Let's apply this as an A force so that we have much higher effect of this force. And let's play again. And now we can see the same effect. And I can continue adding more forces into my top net, and right now we are using this one gas excess force. So in here, let's say if I were to add another force, let's say we have this turbulence force. If I enable this, and here is can see we have this turbulence. And if I were to add, let's say, another turbulence force to layer down layer multiple noises to break up my simulation, I can do so by diving inside. And in here, I can add another turbulence force by typing the gas and now the force name. And I want to add the turbulence force. So let's add this. And now to actually connect both of them, we need to merge both of these forces. So let's add an merge node and merge this gas excess force as well as the gas turbulence. And in here, I can play around with the setting. I can adjust the scale. And now let's go back and hit play. And now hers can see we have the excess force and we are laying down the noise on top of this excess force to create an interesting smoke simulation. I can go back. I can enable another layer, this force, and turbulence is actually available. We have enable inhere as well. We are mixing both of these noises. I can enable my wind force in here and let it play. And that is the basics of how you can create your smoke simulation. We are going to lay down multiple of these forces to achieve our desired look and I can dive inside the pyro solver, and I can continue adding more and more forces. Let's say this time add another gas disturb nod to disturb our field. So let's type gas disturb, and I just need to connect this into merge. In her gas disturb, I can adjust the strength, and we need to go back at the very first frame. I can adjust the strength value, and I can go back and let's view, and we should see some of these smaller breakups. We are also disturbing our smoke simulation. Let me stop this. That is the basics of the Pyro solver. Let me remove this file cache. We will cache our simulation later. But that is the method of how you can create the Pyro solver. We know that pyro solver this top net work because we have created our own top net, and we have the pyro solver, the same functionality, but with some higher level, all of these option has been promoted into this sop level higher level to faster create our smoke simulation. 29. 29 Fire Simulation: Now let's create fire and let's explore some of these option, all of these option a bit further. And first, let me remove all of these top net and the top input field node. We don't need them. And let me rearrange this node graph in here. And maybe to create an AR, I'm going to create a separate source, and I'm going to create an geometry. I'm going to just create a rubber toy geometry in here, let me view this and let's zoom in. I can press the F key in my viewport to frame my geometry. And now let's convert this geometry into volume. And you know that we can convert this into volume by using the VDB from polygons node. So maybe let's add this. And let's uncheck this surface VDB and enable the fog VDB and lower down the axel size. Going to load this down to maybe value of 0.01. And after that, let's create a pyro solver. In here, we need to just connect this and onto the pyro solver. If I hit play, our source has been imported. But here as you can see resolution is not very high rise, which means we need to go back and we need to lower down the axel size. And we can ideally connect these parameter. This voxel size with this sourcing axel size so that whenever we are going to control our axel size, our simulation, we are creating the same resolution of our source as we have in the simulation. So to link these two parameter, I can select the parameter and right click and in here, we have this option copy parameter. I can say copy parameter, and let's select the node. Let's say VDB from polygon's node, and I want to control this parameter in here, I'm going to just select this and remove the value in here. And in here, I'm going to say right click and in here, let's say past relative reference. Let's click on it. And what that will do, it will create this channel expression. I can just click on it to see what the values has been evaluated. So which means I can just control the vax this axel size from here, which means if I were to lower down the axel size, 0.05, you know this axle size will going to be controlled as well. So these two parameter has been linked, and you should always link the auxel size with your source. Now, let's make this value. Maybe let's keep these two at 0.05 and let's play. And, you know, our source has been importing at every frame, and we have this density accumulation. And right now, first this smoke is not rising. Let's say if I were to that is going to be our smoke simulation, and it's not rising and to actually make this simulation rise, we need the temperature. Temperature will cause the smoke to rise where we have the hot spot, the hot smoke will going to be rise. So we need to create another volume because right now we are creating this density volume, but in here, we do not have the temperature volume. We can go into the sourcing. Here as you can see, we are importing the density volume and adding that into the density field of the top. We also have the source volume temperature and the source node is expecting this volume, and we are adding this into the top net because we do not have an temperature volume at the source. So the temperature field is empty and thus our smoke is not rising. I can do, I can create a temperature volume in hair. So the way that we can do that, I can just create another VDB from polygon node or I can just duplicate this node, select that node and press and hold the key and drag to triplicate this node. And for this one, I'm going to just rename this to temperature. So now we are creating an temperature fog volume. I just rename its name. Now if I were to middle mouse button, and here is can see we have this one VDB volume and its name is temperature. And now let's merge both of these volumes together, adding an emerged node, and let's merge both of them. And let me connect this again, move this in here. And if I were to middle mouse button this merged node, we should see two VDB volumes, and here we have them, and we have these two volumes. And now onto the pyro solver, we are importing the temperature inside of our top net. So which means if I were to hit play and Hears can see now because we have the temperature volume, we have this heat information. Now all of this hot smoke is right rising. And that is rising because of the buoyinc force. So wherever we have the temperature, our smoke is going to be lifted up by the buoyancy force, and I can control the buoyancy force by going onto this shape tab, and Hers can see onto the shape we have all of these forces. And the very top, we have the point C force and it's set to one. And if I were to disable the boy and C, let's say, zero or the booin C, I can rewind and hit play, and heres can see our smoke is not rising, even though we have the trabatre field imported, our smoke is still not rising. That is because our booinc zero, and I can change the two values. Maybe let's change this to 0.1. So now our smoke is going to be lifted in a very slow mode because we have very slow force of the buy C. I can enable the Bon C parameter. And in here we have the buoyancy scale, and we have the gravity and the gravity direction. So all of these hard fluids tend to go the opposite direction of the gravity. So the gravity is set to minus one, which means that gravity is pushing the smoke down on the Y axis, and we are getting our smoke upward. And if I were to change its direction to up, which means the one. So now gravity is pulling the smoke up. Now we will see that our smoke will going to be rising down. So if I were to hit play and here is can C, our smoke is going onto the opposite direction of the gravity. And same way if I want to bone C to be effect onto this Z axis, which means I need to just change this Z value to minus one because I want the smoke to rise into my first of Z. So if I were to hit play and hers can see our buoy and C is lifting onto the E AXS. I'm going to just default out this parameter by pressing and holding the Control key and middle mouse button, and that will default out its parameter value. Let's say tree wine and hit play. Now we have this rising smoke effect. Let's increase the buoyancy scale to one, and I'm going to collapse this menu so that we have these same default settings. And to actually import the fire. Right now, hers can see, we are still working with the smoke simulation and I cannot see the fire. And to create the fire, let's go into the sourcing. It requires the burn field, burn volume. Burn volume will be used to create the fire, and the burn volume is going to be added into the flame field of our top simulation, and flame field is responsible for creating the fires flame. And we need two, which means we need to create another VDB volume. So I'm going to just duplicate this VDB from polygon mode and merge this in hair. I'm going to just rename this to burn. So let's rename this burn. Now, I should see fire. So let's go into the pyro solver and Harris can see. We have the fire. Let it play, and we are creating the flame and I can also see the smoke. Hers can see into the whites. Let me adjust the look of my fire by going onto the pyro solver and onto the L tab. And in here we have the density scale. Let's increase this and maybe let's darken out my smoke color, and let's increase the density value again. And here as you can see we have the smoke. We have the smoke and fire, and it's also rising. I can play around with the fire color to adjust the intensity of my fire. And in here, hers can see we are creating these separate VDBs for creating all of these volume. For density, we are creating another VDB from polygon d and to create this volume. So how many so to create all of these volume, we have these separate VDBs, but there is an actual workflow for creating all of these volume in a single load. And the way that we can do that, I'm going to just select all of this node graph and present hold the key drag to duplicate. This time, I'm not going to use this workflow to create my volume because every time I need another volume, I need to create another PDB and set the parameter. What I can do, I can create an node called pyrosurce. So if I were to add the pyrosurce node, let's add this, and I'm going to just connect this in here and let me view this pyrosurce node. And what this pyrosurce node is doing, let me zoom in into my viewpoint. It's just extracting the points, and here can see. We have these same points. These points has been extracted. So the pyro source is removing the primitives and just keeping the points. Let me bring up the parameter. And Heres can C, we have this mode. It says input. Keep input mean that keep only the input of these points. In here, we can change the mode. We can change this to surface scatter. So the surface scatter means that we are going to scatter some points onto the surface of geometry, and I can control how many points I like to scatter by playing around with the particle separation, which means that the distance between particles. And if I were to lower down this particle separation, and here you can see, I am creating more and more points. And same way, if I were to increase, I'm creating less and less points. So that is the surface scatter methane, and we also have the method to volume scatter. And what that will do, it will scatter point, I will fill out our geometry with these points. So we have all of the points onto our inside of our geometry as well to create a thicker volume. And most of the time we will going to use the volume scatter because we need the thick source of our smoke or all of the volumes. You can change this to surface scatter to create a hollow volume. And this hollow volume will create a very thin flame or smoke. I'm going to just change these two volume scatter, and now we have these bunch of points. And onto the initialize, I can just initialize this. If I want to create the smoke simulation, I can say source smoke because I want to create an a fire. I'm going to just click on this one source fern. So let's click on it. And when you are going to select the fern, it will create these two attributes, the burn and the temperature. What's the pyro sources doing if I were to middle mouse button, it's just creating points and adding some attributes. We have the burn attribute and the temperature attribute, and we also have the P scale, the particle scale. And we know that particle scale is essential to set the scale in here. Next, I can just say VDB from particles. I can add an ADB from particles node and to convert these particles into volume. And in here, I want to create an fog volume. So let's enable this, and in here, I need to lower down the axel size. Maybe let's lower this value down to 0.01. And here is can see we have our volume back, but in here, we are still creating an A one volume density volume. But I would like to create multiple volumes. So we have another node called volume rasterized attribute. So let's add a volume attribute node, and let's add this. What this node will do, it will use the input attributes. Here as can see, we have these two attributes. It will use these attributes and convert these attributes into different volumes. So which means I'm going to just remove this and connect this in here right on to the volume rasterized attributes. Let me enable the parameter of this node. Here, we need to define the attributes that we want to convert into volume. So in here, I want to convert my burn field into volume, and here as can see, I can see my volume and if I were to middle mouse button, and here I have one VDB volume, and it is an A tnsity volume, and in here, I can select multiple attributes. So in here, I'm going to let's select an a temperature. Let's select on it. And now we should see two volumes if I were to middle mouse button. And here as can see this node has been refreshed. It was saying that we have the density volume, but it's actually was the burn volume. And Hees can see, we have these two VDB volumes. One is called the burn. The same name that we have set it onto the attribute, the attribute, burn and temperature it will converting them and assigning the same name to VDB volume burn and temperature. And I can even create multiple volumes. Let's say, if I want to create an density volume, I can go into the Pyro source node, and in here, I can add other attributes by clicking on the option attributes. Let's click on this plus button. In here, I'm going to say any name that I like, but onto the attribute, here we have some presets. Let's say I want to create an eight density attribute, and in here, we should see these three attributes. If I were to middle mouse button, and here as you can see, we have the burnt temperature P scale and our newly created density attribute. And if I were to convert this into volume again, I just need to go into the attributes, and in here, let's select our density attribute as well. Now if I were to middle mouse button, and Heres can see now we have three VDB volumes, burn temperature, and it's still sync temperature. Now it is sync density, which means we always need to just refresh this and if I were to middle mouse button, burn density and temperature, these three volumes, it is a much easier way to convert your attributes into volume by using this simple and a single node. And before that, heroes can see we are creating these three nodes, and now we can use just one node to convert all of these attributes into volume. Now I can go into the pyroslver and we should see the same effect if I were to play, and Heros can see we have imported all of our fields into the sourcing, density, temperature, and burn. And all of these three volumes are going to be imported to create this fire simulation. In here, I can adjust some parameter. Let's say, my temperature is rising fast, I can inhale. We have this method acceleration strength, and that is because its operation is set to pull or I can change this to add. We have this different type of operation. In here by using the add, I can say that all of the volume should going to be added every frame. Or I can change this to 0.1, which means that I want the 0.1% this incoming volume should be important in here into this top, which means we are adding less heat in here, and we should see the slow rising of our filame if I were to hit play, and here is can see, I think the 0.1 value is still too high. I can lower this value down to 0.01 and now and heroes can see we have a very slow rising of this fire because we have a lot less heat and same thing in hair. If I want to create less flam, I can increase this sort scale. This is actually just a multiplier. So I'm going to just change this to 0.1. Let's go back and he'll play and heroes can see. We have less flame, but we have more smoke, and that is because density represent the smoke and we are adding more density, which means we are creating more smoke and less flame. To actually apply forces, let me go back and maybe let's change its film field to one to the value of default. And in here, I'm going to just change this value to 0.1, and I think that this rising looks fine. And in here, I can go into the shape tab and I can enable the disturbance and turbulence, and let's hit rewind and hit play, and we should be able to see some breakups and maybe we need to increase its value. I'm going to change this all the way up to one and let's hit play. And I'm still not seeing much effect, so maybe let's increase this value. And here as you can see, I can really start to see this force kicking up. And heres can see this bounding box is increasing as this fire is increasing. I can go into the bound tab. Here we have the bounds. Here we can limit this domain size if I were to enable the limit. And in here, I'm saying that you are allowed onto these ten units. So our bounding box will grow onto the ten units only. So if I were to hit play, s can see this bounding this domain is growing. But after the ten unit, it's going to stop growing and this fire simulation is going to be cut off. And I can confirm. Hers can see when we have reached these bounds limit, this simulation is cutting off at the top. And what I can do, I can say that after we have reached these bounds, I want these bounds to not cut off my geometry, but act as an collider. So which means the simulation will not going to be cut off, but they are going to be colliding with these walls of these bounds. So I can do that by going on to the collisions. And here we have the option for the ground planes. So let's enable this. And here as you can see, we have the X, Y, and Z ground plane. So these ground planes represent these bounds. So right now, here you can see this Y, this one is cutting off. And say, Y ground, please say close above. So which means that close above zero, our dictainer will act as an a ground plan. Let's go back and hit play, and I can adjust its value to increase to match these bounds. I can inherit, maybe let's increase its value to three. Let's go back and hit play. And with the unit of three, we will start to see some collision effect. And Herros can see if I were to check, you will see that simulation is not cutting off, but it's actually colliding with the walls of these bounds. There we have these ground planes, and in most cases, we want to add the ground plane below Y because that grid is our ground. So in here, going to say closed below, and I want to change this to zero. So which means that below zero, which means that below this ground, this grid, we have the ground plane. We have this ground, so let's play, and heroes can see we have some collision happening in here. Most of the time, we are going to add the ground plane like so. Maybe let's explore some other option of this pyro solver, and let's explore them in the next lesson. 30. 30 Pyro Solver Forces: Let's continue exploring our Pyro solver that is available in SOb let's talk about the general approach, how you would normally approach whenever you want to create smoke or fire simulation. And for this one, I'm going to just duplicate my all of these setup. I'm going to select all of them and just track them in here. And here as you can see, we have some calculation. And whenever you are working with tops, make sure to keep your playbar at the very first frame. And if you were inhale, some other frame, any changes you made, the pyroslver all of the top net will going to be calculated at this frame. So it's a good idea to just always be at the very first frame. Now in here, I'm going to just delete this pyroslver. I'm going to add my pyroslver on my own to freshly create the pyroslver. And here we have our source geometry. After the source geometry, we are creating the pyrosurce. Pyrosurce will scatter the points. You can change the method, and in here, we can play around with the particle separation value to create more or less of these particles, and onto these points, this pyrosurce node will going to create some attribute, all of these attributes, and we also have the P scale, and we can control the P scale by this particle scale value. Let me make this default. And after that, we need to convert all of these attributes into volume. And you will use the volume straize attributes. Et's view this. And in here, we are straizing all of our attributes into volume, and we have the axel size. And if I were to middle mouse button, we have all of these volumes. Now it's just a matter of creating the solver. So let's add an pyro solver node in here and let's connect this. Let me view this. And here as you can see, we have the fire, and that is because I think we are creating burn field, and here we have the burn field density and we have heat information, and now we should see a simple rising simulation that is well and good. Let me go into the Pyro solver in here. First, you need to link this auxel size with this volume restra attribute auxel size to control your incoming volume resolution. And also, you need to link this particle separation as well, because if you want to create a more high rise source, you will need more points. All of these three inputs must be connected with this axel size. So for that, I'm going to just right click and say copy parameter and onto the volume restorize, I'm going to just paste onto this axL size. So right click and say paste relative reference. And let me click this back and heres can see we have these two parameters link. And we also need to link this with this particle separation. This particle separation control the number of particles. In here, I'm going to say right click and say paste relative reference. Now, whenever we want to create high rate simulation, we just need to go into the pyroslver and play around with this global auxel size. Slower this value down 0.05 maybe, and heres can see we have our highs source. Our source has been also updated because we are controlling this. Our particle separation has been also changed to 0.05 and onto the volume rest rise. We have the auxel size and its value has been set to 0.05 and this simulation as well. So that would be the general approach for controlling the auxel size your overall resolution. Now if I were to play, and now we should see much cleaner result because we have more auxels information. And in here, if you want to create the fire simulation, we actually do not need the trans t. Trent is used to create the smoke because we are going to create an are and fire should naturally emit the smoke. So which means we do not need the density in our source. So what I can do, I can just go in here and just completely remove this to not create my density volume. Or for this explanation purpose, I'm going to just go into the sourcing, and here we have this. I'm going to just zero out my this source, which means that we are not importing density field into this top net into this simulation network. Now, if I were to hit play, and here as can see we are not getting smoke. We do not have smoke. We only have the fire. And if you want to emit smoke from the flame, and go into the field stab in here. These fields are, you know, the volumes inside of dubs are called fields. So in here, we have the density field. Density is a smoke, and we have the precipation, and it is enable down here, we have the emit from flame. Let's enable the emit from flame option that will emit the smoke from flame. Let's hit rewind and hit play. And here we should see smoke has been added. And heroes can see I can see some of the smoke. Maybe let's go into the look tab and play around with the color of our smoke. I'm going to just make this value dark and maybe let's increase the density scale, and heroes can see we have our smoke. I can emit more smoke. Let's go into the field tab. Here, I'm going to just increase the smoke amount emit from flame. That will emit more smoke, and here I can clearly see that smoke has been added. That is the smoke that has been added systematically by the solver. And if you want to create more smoke, if the smoke is not enough, you can also go into the sourcing tab and add your own smoke, inject your own smoke in your fire simulation as well. By just increasing the source scale, I'm going to just change this to one, which means we are going to import this density volume into our dobs as well. So let's say rewind and it play, and we should see more smoke. And right now, I think the result looks the same. I can exaggerate the effect by just increasing the source scale. I'm going to just increase its overall value and we should see a lot more thicker smoke. And hers can see we have more dark, more thicker smoke. But generally, whenever you want to create a fire, you should not import your density field because fire will generate smoke for you. Let's go back into the field stab that is emit from flame option, and in here we have the dissipation. Dissipation is control the dissipation of our smoke. And if I were to disable emit from flame, and here as you can see, we have the dissipation enable, but our smoke is not enabled, which means our smoke has not been is not in the system is not in the simulation, which means this parameter will have no effect if I were to increase the value all the way up to one, and we shouldn't see any effect in here because we do not have smoke. And to explain the dissipation, let me go into the sourcing tab. And this time, I'm going to just increase my smoke value to one, and I'm going to not import my burn field, and I can do this by zero this source scale, which means that we are going to create an smoke simulation. We are only importing these two volume and we are not importing burn. Mean the smoke simulation. And Hears can see our smoke is not rising. We have our source or this density source, but it's not rising. And that is because onto the field step, we are dissipating all of our smoke. And if I were to lower this value down, and we should start to see some smoke. And Hears can see we have our smoke and it's going to be dscipated very quickly. And I can lower this value down. I'm going to change this maybe 0.1. And now errors can see we have this smoke back. And this dissipation control the dissipation of your smoke. And you can play around with this setting to control the amount of smoke that you like in your simulation. That's the dissipation. And down here, we have the temperature, and onto the temperature, the first parameter is the diffusion. Diffusion will just blur out our temperature field. Let me go back into my sourcing, and in here, I'm going to enable my burn or maybe we actually do not need to enable this because, you know, we have our temperature in hair. So let's go into the field tab and I can visualize all of my field in hair, and to the top, we have field guides. Right now, it says no guides. Here I have visualizer. I can visualize any field. Let's visualize our temperature field and let me adjust my camera angle. And here you can see we have our temperature field visualized in hair onto this side. And if I were to enable the diffusion, it will just blur out this hot area. So I'm going to just increase this diffusion to all the way up to higher value. And now, here as you can see we are blurring out temperature, and that is why we have this slow rising simulation. Let's play around with the diffusion value. And so, basically, it will just blur out your temperature to smooth out your rising of simulation. I'm going to just zero out the fusion and we have the cooling rate. Cooling rate will cool down your heart area over time. So if I were to increase the cooling rate, we will get at the very start, we will get a higher value of temperature, which means our smoke will rise fast at the start. But as simulation grow, our temperature will going to be cooled down quickly, and we should see that our smoke will going to get slow over time. So that's the cooling rate. I'm going to just make these values default, I can also emit the temperature from flame, which means that flame will add more temperature in our simulation. And down here, we have the color. Let's enable the color, and I can manually set the smoke color. That will control the smoke color. Let's play. And hers can see I am adding an A color in my smoke simulation. Let me disable this field guide. Let's change this to no guide, and here as you can see we have some color added in here. I'm going to just uncheck this option, color option down here we have the speed field, and we're not going to talk about this field yet. Let's go into the shape tab. The shape tab will add the noises. All of the forces are built into the shape tab. And we actually inside of the fields, we actually forgot to talk about this flame. Let me collapse this menu, this flame. And here we have the flame lifespan. And that is the dissipation for the flames. And to explain this, let me go into the sourcing and this time, I'm not going to import the smoke into my system. I'm going to create the flames. So let's go into the burn and enable the flame. Let's go back and hit play, and now we should see flame. And here as you can see, we have the flame length. We have this flame height, and to actually control the dissipation of the flame, let's go into the field stab. Here we have the flame option and it says flame lifespan. Here we can manually define how long our flame should live. And these values are in seconds. And if I were to lower down this second value, which means we have this flame will get a shorter lifespan, and let's go back and hit play. And we should see that this flame will going to be dissipated very quickly, and Heroes can see I can even lower this value down maybe 0.2, and let's hit play again. And heroes can see we have a very short lifespan of our flame. That is the dissipation for the flam, and I forgot to explain this. Let me go back check this. Now let's go into the shape tab, and into the shape, we have all of these noises the first one is the buoyancy force, all of the forces to the shape. Buoyancy force, we know that buoyancy effects make our simulation rise where we have high temperature, and the second force is the wind force, and I can enable the wind and I can add directional wind in here. I can collapse the menu and here we have the direction. Right now we are adding wind in the X direction if I were to hit play, and you see, and I think we need to go into the field and enable this flame lifespan and default of my flame lifespan, and let's hit play again. And now we are getting our flames live back. Let's go into the shape tab, and to add more wind, let's increase the value. And now you should see that these flames going to be blown out by this wind. So it's a very basic wind force. Let me uncheck this wind. And down here we have the disturbance. Disturbance this force will do, it will break up our mushroom shape. And if I were to zoom in, and maybe let's go into the field stab and in here, I'm going to just default out this dissipation default out to 0.1. And onto the sourcing, let's import import our smoke into simulation by changing the source scale to one and let's play. And hers can see, I can see this mushroom. Here we have this smooth out mushroom. What the disturbance will do, it will add a high frequency noise into our simulation, which means it will just break out this overall mushroom shape. So if I were to enable the disturbance and to really exaggerate the effect, let's increase the value all the way up, and let's play and right now I cannot see the effect. Maybe let's continue increasing this value. And that is because disturbance will affect less when you have a high speed flame or smoke wherever we have high speed, this disturbance will affect less, and it will affect more wherever we have these simulations slow. To actually compensate this, I'm going to just increase the disturbance value. And here I can clearly see that this mushroom shape has been broken into with this high frequency noise. And I can control this noise size if I were to collapse this menu, and here we have the base block. And here, if I were to create bigger create high sorry, low frequency of this noise, which means the bigger shape, I can just increase the block size, and let's play again, and we should see some bigger breakups and same way you can lower down this value to create high frequency noise to create to break your mushroom into smaller scales. So that is the disturbance. It will add high frequency noise on top of your overall simulation. Let me uncheck this. And down here, we have the turbulence force. What that will do it will change the overall movement of your simulation. And if I were to increase this, and here you will see that our overall movement will going to be changed. This will add noise into our overall movement. And right now I cannot see much of effect, and let's increase its value to exaggerate and let's play. And hears can see our overall movement has been changed, and I can collapse this. And in here, we can define the sol size and to increase the sol size, which means we are creating low frequency noise, and we will see some bigger movement changing. And now, if I were to hit play and hears can see, we have this bigger movement into overall movement of our simulation. So that is the turbulence force to control the overall movement of your simulation. And let me uncheck this. And down here we have the shredding force, and what shredding will do, it will add the noise field at the noise wherever we have high temperature to create the burning effect. You should always enable the shredding whenever you're working with fire if I were to enable this, and I can just increase its shredding amount. And here you will see that let me zoom in. And Hearers can see we have some of these noise added where we have high temperature to create an penning like effect. I'm going to just continue increasing this value, let's this 250 to exaggerate the effect. And Hears can see wherever we have high temperature, we are breaking. We are adding noise in here, and now it's starting to look more like fire because where we have the hard spot, we have the noise. So shredding always help. Whenever you are working with fire. I'm going to just lower this value down, you need to play around with the shredding value to your own liking, and hers can see we have this burning like noise. And if I were to disable the shredding, we will see very smooth movement. And if I were to hit play, and hers can see we are not getting any breakup. It's just a very smooth movement, upward movement. That's what shredding does. And down here, we have the flame expansion it will add the expansion, it will expand our overall simulation. And if we were to increase the expansion rate and play. And here, as you can see, our mushroom shape is going to be expanded over time. And let me increase this value. Let's increase this value. And here as can see our simulation is expanding. Right now our expansion is too high and our simulation is breaking, and that is useful for creating the explosion. And if you want to create nuclear explosion, you can animate this first, you will start with very high expansion rate, and then you can lower this value down. Let me go back. And that way you can achieve your nuclear explosion. Look, that's the flame expansion. And down here we have the viscosity. What this will do, it will blur out all of your velocities. And if I were to enable the viscosity and let's increase the value, it will just blur out all of your simulation information. And here as you can see the value is too high, and that is why we are getting this very slow rising of a simulation, let me play around with this viscosity value and hit play. And here as you can see we are smoothing out all of our details. We're not getting more noise in our simulation. Let's maybe lower this value down even further. And this viscosity is useful for creating the viscous fire. For example, the candle fire. In the candle, we do not have a lot more noise. It's just a smoother looking film. That is the viscasity. I'm going to just uncheck this and let's go back and Hers can see at the pyro source, you remember that we are creating all of these attributes and creating all of these different volumes. And what we can do, we can break up this entire source to add even more breakups. And to explain this, I'm going to just not restteriz all of these attributes. I'm going to just delete all of them. And in here, I'm going to just create one volume that is our tensity volume. What I can do because we are creating attributes in here, I can add an attribute, noise node to noise up this attribute. So let's inhale, connect this inhale. This attribute, this transits and a float attribute. So let's go into this. Attribute noise, what this node will do it will add the noise into your attribute. Here we can define the attribute. I'm going to change this. I think we need to click on it to actually update. So in here, I can click on it, and I cannot see because I think we are using this as an e vector because all of these input attributes are float. So let's change this to float attribute, and now we should see all of our attribute, and there you go, we have them. Click on this tens T, and now we are adding the noise onto our two attributes CD and density, let me remove the CD from here. I want to add just noise onto our density, and I can play around with the noise amplitude, element size. And now if I were to view my volume restize and let me increase the amplitude value and let's play around with the element size, and I'm going to also change the ranges. Let's change these 20 centered, and here as can see we have some broken up source. I can even animate my noise, so let's enable the animation. So now we are getting some breakups in our source. And now I can go into the Pyro solver, and now we should see some improvement. And here as can see this simulation is not rising because we need to add temperature in here, so let's add and temperature into this volume rest rise, and now we should see the rising. Let's go into the pyroslver. I'm going to change the look of my smoke color. Let's change this to value of one. And in here by breaking up the smoke, hers can see we are getting a lot of details. I'm going to go into the shape tab and hers can see all of the forces has been turned off and information, these breakups are only coming from our source. That is why it is important to just keep breaking down your attributes by adding noises to create natural looking simulation. 31. 31 Writing Simulation Cache: Now let's see how we can write our simulation information onto our hard drive for later rendering because we actually do not need to write our simulation information into hard drive. If you have enough RAM, you can use this, for example, here as you can see, we have all of our caches stored in my RAM. In here, I can just create null at the end, and this null node, this node will just not do anything. It's just therefore we can reference it somewhere else. So we need to just connect this and in here, I'm going to just call this one out and render, rename this null. If I were to import this into Solaris, I know that I just need to reference this out node to better find which node I want to render. It's just there null. It has no parameter. It just won't do anything. It's just for the reference purpose, which means I can just go into my lob context, I can go into my stage context by going in here, or it will just change your viewport to the Solaris context. Let me go into the object onto the geometry level. Or if I want to, I can create an opt in her lop network, and I can dive inside, and now we are in the Solaris context. And in here, I can just say sop import, and in here, I can just reference my render node render that we have created, let it accept and hers can see our smoke has been important in hair. Now I can just create materials and render my overall simulation. But as you know, later when we are going to add more detail, let's say, let me increase the resolution of my pyro solver. So let's go into the setup time, and in here, I'm going to lower down the axel size to value of 0.01 and let's hit play. And Has can see right now it's taking longer to calculate because we are working with a lot more axels and we have a lot more high risk simulation. And you will see that our cache size will get bigger, and we will fill out our entire system RAM very quickly, and our RAM may not be enough to store all of our cache. And later, we are going to apply material and they will also going to be stored in RAM. So it will just create problems. It's easier to just write your simulation into hard drive and read your simulation information back to avoid filling out unnecessarily your system RAM. So for that purpose, we need to write our simulation information onto our hard drive. First, let me go into the Pyro solver, and for this time for the faster feedback and for the faster working, I'm not going to create that much high resolution. Simulation, I'm going to just change this to value of 0.05 or maybe let's lower this into 0.03 and hit play. And I think that is enough. This resolution is enough for our purpose. And let's go into maybe the shape tab and let's add some of the turbulence value in here. I'm going to just lower down its turbulence value, and let's collapse this and inhere, as you can see, we are adding the turbulence onto our temperature. And if you want to add the turbulence into your smoke, you can just change the field. But right now, hers can see the temperature field is because present, let's go into the sourcing and middle mouse button. And let me view this again, and here as you can see, we are creating our temperature volume. Our temperature field is present, and that is why we are getting our turbulence effect. So we can just keep this onto the shape tab, just keep this temperature field, and I can just lower down the salt size to create an high frequency noise. I'm going to just load this down to maybe a value of 0.5 and let it play, and that will just create an noised up smoke simulation and down here, let me stop this. Let me collapse this one, and let's also enable the disturbance to break up our simulation even more. And right now here can see there is too much breakup going on, our overall simulation is breaking. So I'm going to just lower this value down to a value of five, a bit more manageable value and to actually pick up more of the noise information. As you know, we need to increase the Vauxel size, but I think the value right now is fine for this sample project. And let's say that I am happy with our simulation. Now I can just go into the output node, and in here, I can define which of these fields I want to import from tops. And right now we are importing all of these fields. And if I were to middle mouse button, and here as you can see, we are importing six grid volume density and all of our volume. And because right now we are working with smoke, we actually do not need to import the flame or temperature. So to not import them, let's uncheck this option. And let's also uncheck the flame and also the CD because we do not have ACD, and let's uncheck this. And now if I were to middle mouse button and Harris see, we are only importing the transt and we are importing the velocity. Velocity is essential for creating the motion blur. Later when you are going to add the motion blur, you must need the velocty here you can see because it is AHdnNative volume, we have separate components, separate volume for the velocity X and another volume for VloctyY and another volume for velocDC. So let's convert this into VDB, and let's also use the 16 bit float because we do not need the 32 bit precision. We're not working with simulation. We are just going to render this, so 16 bit float is enough. Let's present hold the middle mouse button, and now we are down to two VDB volumes. The density and it's still sink temperature, we need to just refresh this view this again and present hold the middle mouse button. And now our inspection window has been updated. And now we are down to two volume density and l in the velocity. And it is an A vector volume. And here I can see vector. It has three values, and density is float volume. And VDB sports vector volume, which means we do not need to create separate volume for the X and Y, and Z. We can just use a one vector volume to store our velocity information. And that is why VDBs are more efficient. VDBs are awesome. Now let's write out our simulation into our hard drive. We are ready to write. And to write this, let me make drag this lob net in here and in here, we need to create a file cache node. So let's type file cache, and here we have it. Let's connect this and make sure that it is connected and it is connected. Let's go into the file cache, and I'm going to bring up the parameter of this node. And first, we need to define the base name. And onto the base name, we have some expression going on. First, we have the Dloine hip name, the dolosin hip name, your current project Flem If you have save your scene file and let's say you rename this one to smoke sim, it will just use your project filename and add in here. That's what the Dloine hip name expression is. And we are adding the dot. After that, we are adding another expression, Dlosine OS. Dole sin OS means the operator stream the operator name itself. And I'm going to just delete this dolosine hip expression and dot. Just keeping the base name Dlo sign OS this operator name itself, which means if I were to just rename this and right now, if I were to see what this expression is evaluating, just middle mouse button onto that parameter. If I click and here is can see, it's saying that file cache one. And if I can middle mouse button again, now I can see what the expression is, and by pressing the middle mouse button, I can see the evaluation of the expression. It says file case one. That is the name of the node itself. And if I were to rename this, let's say, if I were to rename this to smoke, and here you can see this name has been changed also, which means we are grabbing the name from our node itself. That's what the dollar sign OS expression is. I can delete this expression and I can manually type the name that I like to store. I'm going to just say smoke underscore sim and now I am just manually typing my name in here. And onto the base folder, we need to define the location where we want to store this simulation data. So I'm going to just pick up the location. Let's click on it. And in here, you can pick up your location where you want to store. You can pick up your location. I'm going to just create a new folder in here. Let's click on it. And I'm going to call this one our SIM and let hit Accept. And I'm creating an Assim folder in my this location and hit Accept. And right now, its name is not Greg. Let's go back and in here, we have the SIM folder. Let's dive inside and hit Accept again. And now we see the correct location, Talus and hip and SIM. And in here, we are going to create this smoke SIM. So at the front of this, we have the file extension. Right now, we are using the dot pgt SC the BGO file is the Houdini native file format. For example, for importing the models, we have the OBJ file format and we also have FBX, we also have Lambe. Same way, BgdotSC is an A Houdini native file format. I can change this to VDB if I want to store my caches as an A VDB type, or I can change this to BgdtSC which means the Houdini file format, and you should always use the dotpgdtSC. The dot SC mean that the compression so BGO is a native file format and dot SC, which means that we are using the compressed version of our BGO to space our file cache size. So let's use this BgodtSC and now in here, we have the sequence. And here as can see we are using the frame range and our simulation option has been checked on. So whenever you are working with simulation, writing your simulation cache, make sure to keep this option enable. Right now we are using our entire frame range, this playbrFrame range to write our simulation data. And if you want to limit your frame range, your writing frame range, you can just either adjust your playbar range, and I can adjust this by coming over here. And heres can see we have these two values. We have 240 here and 240 here. The first value, it will control the zooming. If I were to lower this value down, let's say, I'm going to change this to 50. But that will do it will just zoom our play bar to 50 frame, and Heres can see we are starting with one and ending with 50. But our entire frame range is 240, which means I can just adjust this slider. And that is just the zooming. I can also control the zooming by clicking this slider and here as you can see, as I am zooming, I'm also adjusting this value. And if you want to adjust your range, your overall this play bar range, you need to adjust the second parameter. In here, I can say, I want to write my 50 frame only, so I can just type 50 in here, and Heroes can see we have our 50 frame range. Our entire range is just on 250. And in here, if you take a look or the start and end range has also been changed to 50. I can change this to, let's say, 70 frame, and you will see that this range is going to be changed also. Let's click this Heroes can see we have this range one and 70. So it is getting the information from our playbr I can do, if I want to manually adjust add our range, I can just right click on this parameter and just delete the channel. And because right now if I click on it, here can see we are using an expression, Doll sign F and, which means the frame. Right now we are using this expression to get our information. I'm going to just right click to delete the expression. Click on this delete channel, and that will just delete the expression. Mean I can independent our simulation range. Let's say I want to render only 50 frame. So no matter if I were to change this back to 240, you see we are just using the 50 frame. And now I just need to press Save Tris option to write out our caches. So let's click on this Save to Triscoption. And by clicking this, you will see down here, and here we have this window. And in here we are caching our simulation data into our disk, and right now it's going very fast. And I think because we are working with a very low resolution of our volume, and maybe let's keep cashing out this simulation. And when this simulation cache is going to be done, I can just click on this load from Trisk option to load our caches back. And you will see that when this cache has been done, this file cache node will automatically going to check this option on. Which means that we are not going to calculate our simulation up here, but we are going to use our caches to load our simulation data back into this Houdini session, all done. And here as can see we have this option right here. Here we are getting this icon, this disk icon. It means that our caches has been present in our hard drive and load from disk option has been enabled. And if I were to disable this or this icon has been gone indicating that we are not loading our caches from disc, but we are calculating our entire simulation in hair. And if I were to enable this and this icon has been enabled, saying that we are not calculating information. And if I were to view my out render and I can scrub, and here you can see, I can easily scrub and I do not have this blue bar, which means that we are not calculating all we have calculated all of our information and written out our caches, which means I no longer need to connect this. If I want to, I can just delete this and I can go in here and I can independently load my caches because they are written in my hard drive. And if I were to middle mouse button, and Hears can see this particular frame is using 100 megabytes. So we have this frame 100 megabyte, and I can change this to maybe, let's say, frame number 50, and let's middle mouse button. And Hears can see we are using the 226 megabyte of This frame is 226 megabyte. Okay, that is the cache size. Now, which means I can go into the lop Net and hers can see our new has been imported, new simulation, which means I can scrub and onto the sop import because we are referencing this out null, all of these changes upstream is going to be also updated, and that is the benefit of using the null, which means if I were to change this input, let's say if I were to add fare inhere and connect this into the out. And now you should see that this sphere is going to be imported in lob net. Let's go into the lop net and here can see we have this sphere. And that is because this sop import is referencing our out null node. So that is the benefit of using these nulls. I'm going to just delete this and connect this in here because I want to import my smoke into my lop net. Let's dive inside the lop net in here. And now we are ready to create the materials and render our smoke simulation. 32. 32 Rendering Smoke: Now that we have written out our simulation into our hard drive, now let's see how we can render our smoke simulation. And let's apply first, we need to apply some material into this simulation. And for that, I'm going to create an material library down here. Let's add this and connect this in here. So in here, you know that either we can create some material onto other material network, we need to go into the fill and define our material network or we can just dive inside and start building our material. Let's dive inside, and in here we are in the wax builder context, which means we can start to build our material. And in here, I'm going to create our kerma material builder. So let's go into the Kerma. Here we have the kerma material builder, but we also have the material for the pyro. So because we are working with the simulation, all of these simulation related material this explosion, fire and smoke material are inside of this pyro section. In here, let's go into the Kerma pyro, and in here, we have this era Cloud material if you are going to render your cloud, and we have the Kerma Pyro explosion material if you are going to be entering your explosion, we also have the fire material, and we also have this pyro smoke material. Let's add the pyro smoke material because I want to render my smoke simulation. And here we have the smoke material. Let me enable the parameter and to actually access the parameter, it's an subnetwork. Here as you can see, it is written a sub network, which means we need to dive inside to have access to the material itself. So let's dive inside. And now we are still in the wax builder, but now we have the access to this kerma pyro shader. And here we have these properties. Let me move this down and the inputs, we just don't need this let's delete this node. In here, let's select our pyro shader that is our actual shader and bring up its parameter. And in here, you can see we have this enable smoke option, and right now it is enable. And first, we have the transty, which means I can adjust the density or this smoke. I can create thick or thin smoke by playing around with this density value. I have the option for the color. First, maybe let's assign this material. So let's go back onto this lop Net and in here onto the material library. We need to click on this auto fill material to fill out this slot. And so let's click on it. And now here can see our Kerma material builder has been important. In here, I can just click on this assigned to geometry to assign our material onto our geometry right here from the material library. Or I can create a material linker. It's a material linker, and that is actually a preferred way of assigning the material. You need to connect the material linker and in here, bring up the parameter, and here we have the material list, and here we have the geometry list. And if I want to assign this, I can just click and drag onto my geometry. Now these materials will get assigned to this sub Import. Or I can just remove this and we also have option to assign this onto our jump tree right here. So let's enable this and I'm going onto the jumtree path. Just click and drag onto this path, and this will going to be assigned. And now we need to create our render node. Right now, we do not have a render node. But first, let me create an light because we need the light for creating to render this smoke simulation. And for that, I'm going to use an dome light inhere. So let's add a dome light and connect this in between, and let's view the dome light and in here, going onto this texture slot. I'm going to select my HDRI. You can use any HDRI that you might have downloaded from the Internet, but I'm going to use the default HDRI that came with Houdini. So let's click on this Houdini pick HDRI. And here we have these three HDRI that came default. I'm going to use this one Skylight Garage and Heixcep and here can see our DRI has been imported. I can let me activate this view tool to adjust my camera angle. And in here, I'm going to just select an A angle and create an A camera. And to create the camera from this current angle, come over here where it says, No cam. Let's click on it, and in here, just click on this new camera option to create the camera at the current angle. So let's click on this and heres can see our camera has been added. And in here, I can activate my camera view tool when our Viewtol is active. And right now, Hears can see we are using this camera one. And into the node editor, Harris can see our camera has been added and its name is said to camera one, which means we are looking through this camera one, and this lock button is enabled, which means that if I were to enable my view tool and play around with my camera angle, my this original camera location is going to be changed. And here, as you can see, onto the transform load of the camera, as I am moving, these values are changing, which means that I am interactively placing my camera. And if you are happy with the location, let me zoom out let's say I am happy with this camera angle. I can just uncheck this lock button, and what that will do, it will not adjust the camera position interactively, which means I can freely move around and my camera position will not going to be adjusted. And here I can see the camera in my viewpod. That is the camera location. And if I want to look through this camera, I just come over here where it says no CAM, click on it, and in here, we need to just select our camera. Here's can see cameras camera one. Let's click on it, and now we are looking through our camera. And if I were to adjust the angle, let me adjust this, and here is can see we are not using any Cam because we have changed our location and Log button was disabled. So which means we cannot adjust this position any longer interactively. That is good. Now all that we need to do is just create our render node. So down here, let's create an Kerma node by typing the kerma, let's add this. And when you create Kerma, this will add these two nodes, this USD render. That is an essential node for rendering out your sequence, and that is the actual render settings. We need to connect our input stage in here as well, let me view this kerma render setting, and in here, we can play around with the settings. I can change the engine. Right now we are using the CPU engines, so that is why we have these CPU parameters. I can change this to XPU, which means we are going to use the CPU plus our GPU to accelerate our rendering. Maybe let's use the XPU, and I'm going to look through my camera and in here to actually render this with karma, this karma render node. I need to come over here where it says perspective. Let's click on it, and here is can see we are right now using the Houdini VK, which means the volcan Houdini Volcan view booard. I can change this to Kerma CPU or Kerma XPU. I'm going to just click on this Kerma XPU to render my this smoke with the Kerma XPU. And here as can see we have this optexs. This optexs means that the GPU, and right now our her are compiling, which means all of our information is going to be stored into the GPU RAM. And when this compile has been done, we will see that our GP will going to start render and we will see some acceleration. And right now it's compiling and we need to wait. Take time at the very first frame, but when all of the information has been stored, once it has been stored inside of GPURAM, our simulation is going to be accelerated, and Hearers can see our simulation sorry, our render has been done. Now I can just activate my view tool. I can interactively adjust my camera angle, and hearers can see my render speed has been increased. And right now our smoke is looking too dark, so maybe let's play around with the light. Let's go into the dome light. And in here, I'm going to adjust the intensity or exposure. Maybe let's increase the light exposure. And let's go into the transform node and let's play around with the rotation. I want to rotate my HDRI onto my Y axis. Let's keep rotating this until we like the angle of our light. Now, let's dive inside the material library to play around with the material setting. First, this HDRI light in the background is very distracting. So let's disable this light in the viewpoard and to disable this, we need to click on this I button, open display option. That will open your display option, and we need to go into the background where we have the settings related to our background. And in here, we have this options environment light as background. So let's check this, and that will hide our environment light as a background. The light is there, but we are actually not visualizing in the viewpod. We are hiding it. Now the color scheme, we are using the light scheme inside of Solaris. We can change this to dark or maybe let's change this to dark gray. And now let's close this window. And same way, if you want to hide your grid, hers can see we are visualizing the grid. I can just click on this button that will hide the grid. And down here, we have the guide for our light. This yellow dome, sorry, white color sphere. This white color sphere mean that that is the indicator for the light. We have this dome light. So if you want to disable your guides for the lights, we have this option that is the display light guides. Let's uncheck this. Now all of the guides has been gone. And if you want to create, let's say, if I have multiple lights in here, I'm going to create an light node and if I were to add this into my scene and play around with the position, and hers can see I have a guide for this light as well. And when we are going to create multiple lights, we will have all of the lights scattered around in our scene, and if it's going to be distracting, you can just click on this button. I will just hide the guides. So that's the guide visualizer. So let's view this from our camera angle, and maybe let's delete this light. We don't need this. Now let's dive inside the material library and onto the kerma pyro smoke material. In here, let's play around with the material setting. First, we have the density scale. If you want to create thick smoke, you can play around with the density. Same way if you lower the density and heres can see, I am creating thin smoke. Let's lower this value down to 0.1, and Heres can see, we have a lot thin smoke. Maybe let's change this to value of one, and in hair, we can play around with the smoke color. If I were to change this blue and Hears can see we have this blue color. I can continue playing around with my smoke color. I can make my smoke darker or lighter. And same way, we have the shadow. And right now, Harros can see we have the density for our shadow. If you increase the shadow, we will get these darker shadows. And same way, I can lower this value down, this shadow density down to create a more light these shadows. Now I can play around with my color. Let me adjust by this overall color and maybe lower down our shadow density. Let's low this down to 0.2. And I'm going to play around with this overall smoke color and also maybe increase our density to create a thicker smoke. And you can keep playing around with these pyro material, the smoke settings to your own liking. And here we also have the shadow color, which means wherever we have the shadow, we have this dark color. I can change this to blue. Now we will get these blue shadows and when you are happy with your result, I can go back. Let's say that I like the look of our material of our simulation and all of these lighting. I can go into the era render setting. In here, we have this output picture, and in here, we can define the location where I want to store my image sequence, my render sequences. So let me pick up my location, and I'm going to go into this location. I'm going to go into Edlosign hip inhere, and I'm going to create a new folder and I'm going to call this folder render, hit Accept and hit accept in here. Sorry. We also need to define the name of the file. We have setted the location. We have created the folder, and now we need to set the name. I'm going to name this one, let's say, smoke underscore, render. And whenever you are working with animation because we are going to store multiple frames, we have 50 frames. And whenever you are working with multiple frame, you need to add an unique identifier for the wise when the render is going to happen, it's going to use the render this name. And in the next frame, it's going to when it's going to render next frame, it will still going to use this same name, smoke render, which means that we will going to be overwriting our previous frame. And to actually avoid this, to render all of these sequence separately, we must have unique name. And to add the unique name, I can add the Dal sine F expression, F. This Dloine F means the frame number. Expression will insert insert your current frame number. So Doline F means that because right now we are in the framework 23. After that, the smoke render, we are going to add an A 23 in here. So maybe after the underscore render, I'm going to just add an A underscore in here, and after that, I'm going to use the Tal sine F, which means the unique identifier, and for the unique identifier, I'm using the frame number. So we will not going to overwrite our sequences. And now we need to set the extension you want to render out your EXR sequence, you can add the dot and the extension name. If you want to render EXR, just type EXR in here, and same way if you want to render your PNG sequences, after the dot, you can type PNG in here and Houdini will render them as an PNG sequence. And same way, if you want to render your basic JPAG, you can just change this to JPG and it will render out simple JPAG. I'm going to render the EXR sequences. So in here, I'm going to type dot EXR and texcep and now onto the output picture, has can see we are using this expression, the Talosge which means our current store location or this current saved scene file location. And in here, we have the render folder, and inside the render folder, we are going to use the smoke render and the TalsgeF mean the current frame number, this sequence. And now down here, we are using the resolution. You can change your resolution from here. You can click on this and here we have some presets. If you want to render out your trenty sequence, you can just pick or if you want to render your four k sequence, you can just click and pick. And now we are going to render our four que sequences. I'm going to just keep this at default 12 80 by 720, and now all of these settings has been set. Now we just need to render them. To render your sequences onto your hard drive, we need to come our hair onto this USD. Render rob. This render Rob is responsible for rendering out your sequence onto hard drive. And in hair, we need to press render to risk option, and that will render out your sequences into your hard drive. Down here we have the valid frame range, and right now it's set to render current frame, which means that it's going to render single frame, the current frame. Right now we are at the frame over 24. It's going to just take the 24 frame and render out the single frame. If you want to render out your entire frame range, I can just click on it and change the to render specific frame range. Let's click on it, and now here we have the same option and it is using this Dlo sine F and this expression. To take the information of our play bar, and we are right now using the 240 frames. And as you know, let me close this console in here. As you know, if you want to render out your strict frame range, either I can adjust my playbr, I can change this to 50 inhere, and this will going to be changed also. Or you can just delete this expression by clicking on this delete channel. And in here, you can manually type how many frame you want to render. Let's say I want to render 30 frame, you can type 30, and now it will render your first 30 frame. And just press on this render to disc option and it will going to start rendering. And first, we need to change this to Houdini k which means that the Houdini volcan viewpoard and make sure that you are not rendering inside of the viewpoard by the Kerma XPU because it will slow down your render. I'm going to just change this to Viewboard which means we are not rendering and going to press Render Today's cption and it will going to start render all of my sequences. 33. 33 Pyro Burst Source: Now let's take a look at the pyro first source. Pyro source is used to create the explosion source. Let's see that. In here, I'm going to create an jumped node in here and let's dive inside and in here, let's type pyro, and here we have all of these nodes related to creating the pyro simulation. And I'm going to inhere add an Pyro first source. Let's type this and add this. Here we have the Pyro bust source and let me enable my playbr and inhere, we have some animation built in. Let me zoom out, and if I scrub my playbar here C, I have some animation. And essentially what that node will do, it will just create these bunch of points. So we are creating these points. We are creating these interesting shapes. These shapes will create an interesting source for our explosion. And whenever you want to create explosion, it's not a necessary thing or it's a must think that you must need to add pyro per source if you want to create explosion. It's nothing like that. It's just interesting source. If you want to create explosion using sphere, you can add an sphere in here. And after this sphere, you can just scatter a bunch of points by using the pyro source node. Let's add a pyro source. I'm going to connect this and you can play around with the particle separation, and we need to change this to surface or volume scatter for this parameter to have an effect. And down here, you can just add the noises onto your attributes and build your VDB volume for sourcing and import them into your pyro solver to create the explosion. You can completely do this. But this node, it will create these interesting shapes for our source. We have these bunch of points, and we can play around with the parameter to adjust these shapes or these points shapes. So in here, I'm going to just remove this and let's take a look at its parameter. And in here at the very first step, we have the shape type and the worst type. And right now we are using the explosion type preset, and I can also play around with my shape offset to create an shape that I like. And that way, by using the shape offset, we are basically adjusting the random seed, and I can play around with this random seed and go through the shapes that I like for my source. I'm going to let's change this to any value and inhere, if I were to hit play, we have some animation built in in here and I can control my initial size. If I want to create an bigger size source, I can just change this value, and that way, I can create my this initial size bigger or smaller. And by changing the initial size, we are starting with three units and we should expand we are this three unit. That is the shape size. I'm going to just change this to its default value. And down here, we have the direction at which direction I want these points to grow. I can change this to any direction. Let's change this to X and maybe zero out the Y, and now we have these points growing in that direction. Let me change this to one again and zero this out. And in here, I can play around with the spreading angle to create more pointier shapes and in here. Can see we are adjusting the spreading and I can play around with the roundness. And if I were to change the two all the way up to one, now it will try to keep all of these points inside of this conical shape. And if I were to play around with the spreading angle, and here as can see, we have this cone looking shape. And by adjusting the spread, I can play around with the spreading. And by lowering down this roundness value, I can just randomize the scale to create the random scale of these trailing. So maybe let's add some randomness by adding the roundness to break up this round conical shape. And down here, we have the number of trailings, how many trails that we want to create. If I were to lower down the number of trailings, I am effectively creating less and less of these trails and same thing, I can keep increasing this to add more and more of these trails, and down here we have the trail trailing separation. And while lowering down this value, we will going to be creating more and more points if I were to, let's say, lower down the number of trailings and right now, errors can see we have these points, and these points are very sparse. We are creating very less points. I'm going to just lower down the trailing separation value, let's change this to 0.01, and now errors can see we are creating a lot more points. And same thing. Let's just default this out by pressing and holding the control and middle bows button. And in here, we can adjust the trailing length, and that will control the length of our trails. And if I were to lower this value down and Hers can see we have these shorter trails. And by increasing the trail length, I can continue increasing this length. And I have this trailing thickness, and that will control the overall starting thickness if I were to lower this value down, and maybe it will be easier to see if I were just to make more of these lower down this trailing separation to add more points. And if I were to adjust the trailing thickness, and here as you can see, I am creating these lines. I am zeroing out its start radius. And in here, I'm controlling its start radius to create this conical shape. And let's go in here. First, we have this burst type. Right now, we are using the explosion preset, and we have some presets built in. For example, if you want to create an A muzzle flash, I can just add a muzzle flash type, and right now it's not looking like a muzzle flash. We need to default out all of the settings. So I'm going to just press and hold the Control key and I'm going to middle mouse button on all of these settings to zero or default out all of these parameters. So now we are back at the defaults, and here we are we have this muzzle flash type. And here can see our source looks different, and I can change this to shockwave and that will create this ground shockwave type source, which is and in here, we can also change this to blasing. It will create this blasting that we will get when we are going to create a nuclear explosion. When nuclear explosion happen, we will get the blasting because of the high pressure. So you can create blasting by using this preset. I'm going to change this to explosion or maybe let's change this to shock wave and in here, we have some other option. With the shock wave, I can add an a shaped noise, and heres can see we have some other parameter when we have changed this to shock wave, now we have this azimuth start angle and azimuth angle. And if I were to lower down this angle, I'm effectively just cutting off by this round shape, and which means if I were to grub my playbr and heres can see, I am creating this shock wave in half of this angle. I can continue playing around with this to create this shape like this. I'm going to just change these two all the way up to 360 because shock wave is circular, so let's keep this at circular. And to actually break this circular shape, we have this ad shape noise. Let's enable this. And by doing so, I can just add some noise, amplitude. And let's lower down its size. That is the frequency of the noise, and heres can see we are breaking up this round shape. Now we have some breakups and breakups are always good. I'm going to lower down its particle separation. Let's change this 20.05 to better view all of our these settings. And here we have the shaped noise amplitude. You can do so. Let me disable this. And now let's go into the next tab, which is the burst animation tab. Let's go in here. And in here, we can define the start frame, and I can change this to. Let's say I want the shock wave to start maybe let's say frame number. Going to change this to 15 maybe. Now if I were to go into my frame number 15, here as you can see, at the frame number 15, we are getting our animation, and that is the start frame. I'm going to just default out this 21 because I want my animation to start at the very first frame and here we have the frame duration, and that will control the overall frame length. And right now we have the animation at first five frame, and if I want to add more of our animation frame, I'm going to just increase this value and by doing so, I am creating my this slow more growing effect. I'm actually slowing down its overall speed by increasing the frame number, and let's continue increasing this. And let's hit rewind and hit play, and Hearers can see. And right now this animation is playing as fast as it can. And to actually play this in real time, we need to enable this clock button, and that way, we will going to be playing animation in real time. So let's hit play, and Hears can see that is the real time animation. And I'm going to just low this value down because we want this shock to start at very high speed. And in here, we have the interior expansion that will control the interior, and it's right now harder to see, which means I need to go into this advanced frame. So let's go in here at the frame number 15, and now I can clearly see the effect and that controls the interior expansion and same thing I can play around with the exterior expansion if I were to lower this value down and maybe increase this value. And that way, I can just create growing circular effect, create a growing circle. Let me play around with this. And here we have the directional translation. What that will do, it will just move your offset this blast ring. And if I were to adjust this value, and here is you can see, this blast wave, this shock wave is moving at the Y. And if you want to lift your source up, you can do so by adjusting this directional translation. And now let's go into the burst component. And here is can see if I were to zoom in, and we have this weird visualization of these points. And here we are getting some of the points. We have white points and we have yellow points, and we have some blue points. So what are these? These are the attributes that we are creating. This pyro source is adding. And if I were to middle mouse button, and here as you can see, we have quite a few attributes. We have p, we have density for smoke, and we are also creating the temperature and V for velocity. And these colors are actually visualizing all of these attributes. And if I were to come into the burst components, bust components are the attribute that this node is adding. And in here, here as you can see we are creating three attributes, and the number one is the density for creating the smoke, and the second, we are creating the temperature, and the third, we are creating our burn attribute. And if I were to remove this attribute, I can just click on this remove button, click on it, and I can click this again to remove this temperature attribute as well. Now we are only creating density attribute. And Hears can see, we have the visualizer attached to it. This source will going to visualize your all of these attributes. So density is always going to be visualized as A white particles, and I can change the attribute. So let's click on it. And if I were to create temperature, and Hears can see the temperature is visualized in blue, and if I were to change this to divergence, divergence is in orange color. The divergence is used to add the expansion and we will talk about divergence in the next lesson when we are going to create the explosion. For now, that is the divergence, and we have the burn and it is visualized in yellow particles. And if you want to create multiple of these attribute, I'm going to just make the first attribute to trans T. And to create another attribute, I just come over here where it says number of sources, I just need to click on it. And what that will do, it will add another attribute. And onto these sources, I can just enable create source. And now we are adding the density field. Sorry, creating the density attribute. And in here, I'm going to just say at the temperature, and here as can see we have the temperature visualized in blue, and I can continue adding more of the attribute, just click on this plus button and create source. And in here, let's also add the burn. And that is why we have this colorful visualization. It's displaying in the viewport that we have multiple attributes present in our source. That is good. And now up here, we have this scale over duration option, and you should always enable this what that will do. To explain this, I'm going to just remove out this. All of these field, I'm just going to create an A trent attribute, and let's enable this scale over duration. And what that will do, it will use this ramp. To fade out your attribute. And if I were to play this and here is can see our color is changing, this color represents the fading. I'm going to just bring this ramp a bit closer to make to fade the attribute a bit faster if I were to hit play, and here is can see after a few frames, we have white and we are fading out to gray, and then we will change this. We are changing our color to completely black, which means that we have values of zero. And what that will do, it will create an fading volume. And if I were to create an A volume restorz attribute set a volumes attribute to rest rise or this density attribute into volume. Let's go in here. And I'm going to just select my density attribute, and Hears can see we have the volume. And right now, it starts as a very thick volume. And if I were to scrub my play bar and Hears can see, we will see some fading effect. And at the number 11, if I were to view the pyro source, and heroes can see we have this black color. We still have particles in our source, but our density attribute is zero, and in here, thus, we're not getting our volume. And when we have this value gray, when we have this gray value, we will getting this less density value, which means we are creating a very thin volume, maybe it should be easier if I were to down by voxel size. Let's change this to even lower 0.02 and inhere onto the pyro but source. If I were to play around with the ramp, and heroes can see it's controlling the fading. So which means we are using this ramp to fade out our source. And if I were to uncheck this option, what that mean that we are starting as solid and at the end frame our source, it's just gone. Let's enable this scale over duration and that will create this natural feeding effect and let me default out this ramp, play around with this ramp, and that is the scale over duration, and I can also enable the scale along trailing. What that will do, it will fade out its edges. Let's enable this, and hers can see we are fading out these edges. I can play around with the ramp, and these are the outer boundaries. We are fading them out. So maybe let's always enable both of them so that we have fading edges and fading out of our source. That is a very natural looking source. And onto the output attribute, we have some of the option to output our velocity attribute, and right now velocity is enable, which means that if I were to middle mouse button, sorry, not on the volume rests, but onto the pyro first source, five were to middle mouse button, and heres can see we have the V, mean the velocity. And we can also visualize our velocity if you come over here where it says display normal. Down here, we have the display point Trail. Point trail will visualize our veloct. Let's click on it and here can see we have some velocity information. Let me disable this and let's delete this volume rests attribute and in here at the Pyro burst source, we have some presets. For example, if we want to convert all of these, let me go into the burst component and because we are enabling this ramp, we need to scroll this down. We have the attributes, and right now we are creating one attribute, density. And if I were to add another attribute, let me enable the create source. I'm going to change this to burn. And now if we were to convert these attributes into volume, we need to add an A volume, rasterize attribute node and select all of these attributes in hair to convert them into volume. Or into the Pyro Burt source if I go up. In here, we have this quick setup if I were to click on it, and in here, we have this option to create source volume. If I click on it, what that will do, it will create a volume rasterize attribute, and it will add all of these attributes for you that you are creating. It is using the expression to bring out your attributes, which means I can interactively go into my Pyropur source, and in here, I can add more attributes. Let's say I can say create source, and in here, I'm going to add another attribute, and now this attribute is going to be added also, and now here as you can see, right now, we are creating these four volumes. We are also creating our V velocity volume as well to add our initial velocity. And that is why we have this weird viewport visualization. This weird viewport visualization always come when you have vector volume visualized, Vs and a vector, and that is why we have this visualization. I can go into the Pyro per source at top. Let's go into the output attribute. I'm going to just disable the velocity, right now, Hers Cc velocity has been disabled and our viewport is displaying our density accurately because right now, we do not have any vector volume. And same thing, I can go into the component. I can remove these attribute, and they will going to be removed in here as well. Let me remove this onto the pyro but source. We can go into this quick setup. I can directly create my pyro simulation from here if I were to click on this pyro simulation, and what that will do, it will add the volume astize attribute and fill all of the attributes in here and also create an apyroslver and import all of our sources into this pyro solver as well. Remember that these sources are not interactive, which means if you were to go into the first component and add another component, let's say, I want to add divergence, it will not going to be added interactively because in here, we are not using any of the expression to procedurally import. So which means you need to always add another source by clicking on this plus button if you want to manually add, but it will going to convert them into volume automatically by using these volume sturize attributes. But you also need to import them Pyro solver manually. So in the next lesson, let's see how we can use the pyro but source to create our explosion. 34. 34 Explosion Simulation: Let's create explosion by using the pyro burst source. So in here, let's create an geometry node and dive inside. And in here, I'm going to add the pyro but source node. Let's add this, and that will create this interesting shape for creating the sourcing for our explosion and onto the pyro burst source. We have the burst type, and it is set to explosion, which is good. And let's go into the maybe initial size. I'm going to just increase the overall size. I'm going to just change this to value of 2.5 and here we have the source. And now let's go into the burst animation, and I think the default animation values are fine. Let's go into the burst component and see what are the attributes that we are creating. We are creating the density, we are getting the temperature, and we are creating the burn three attributes. And let's enable this scale over duration and also let's enable the scale long trailing option. Both of these option to create this smoothing out of these animation fading animation, which will create the natural result for our sourcing. And in here, I'm going to just click on this Pyro simulation node to create the volume restise node and also create the Pyro solver. And now let's hit play, and we see what we are getting with the default values. Let me hit play again. And here we have the explosion. And let's play around with settings to adjust the look of our explosion. First, I'm going to enable this real time playback option so that we are visualizing this as real time. Right now, it's not real time, that is because we are calculating our simulation. But once we have this blue bar, which means that our simulation has been calculated, I can just hit Stop rewind and if I were to hit play, now I will get this real time playback. Okay, let's go into the Pyro solver, and in here, let's play around with these settings. And in here, we have the axel size. You know, we can lower down the axel size to create high as simulation. But right now for faster feedback, I'm going to just change these 20.2, and onto the sourcing, maybe first, let's go into the collision and in here, right now, errors can see we do not have any ground plane, and this simulation is going below the ground. Maybe let's go into the ground plan and onto the Y ground plan. Let's add this close below, which means that below zero, we are adding the ground plane. And let's play again, and now we should see that some of the collision happening in here. And with the collision, we will get this lingering of smoke, which is always fine, always good. Let's go into the sourcing tab, and in here, we are adding the density into our top density, and the operation is set to maximum, which means that we are using the maximum value. And I always like to change the operation to add, and let's change this to add. And by doing so that I know that I am adding the density every frame. And let's hit play. And if I want to create less of the tnsity, I can come over here and lower down this source scale value to manually control how much amount of density I want to add. And that's just the way that I like to work. And for this one, I'm going to change the source scale all the way up to one and same thing in here. And we are pulling this heat source temperature volume, same thing in here. I'm going to just change this to add, which means I'm adding my temperature every frame. Let's rewind and play again. And in here. And here is can see by changing this to add, we are getting a completely different look of our explosion because we are adding more heat and more heat means that we are rising our explosion fast and because of the fast rising animation, our explosion shape looks completely differently. And onto the flame, same thing in hair, we are using the maximum operation. I'm going to change this to add as well and that will create this fire, these flames and Heirs can see now we are creating more flames by just changing the operation, this look is changing. And let me drive down here and in here, we are adding the velocity, importing the velocity, V volume, and we are adding this into al. Velocity volume inside of top is called the well and its method is set to pull as well. Let's change this to add. Same thing. Let's play and let's see what we are getting. And here's can see. We have this velocity kicking off, and we have a completely different explosion just by changing the source. Now, let me stop the calculation, stop this. Let's hit rewind and here the field that we actually skip, and that is the divergence field. What the divergence will do, it will add the expansion. If I were to disable this by clicking on this option, which means that we are not importing our divergence. And if I were to hit play, and you will see that let me change my angle, and heroes can see or this explosion is not expanding. We do not have the expansion effect. And to add the expansion, the divergence field, it will add the expansion. If I were to add this divergence and Heres canc I have this value. And in here, you will see that this simulation is expanding. And if I were to maybe let's increase its value to really exaggerate the effect, I'm going to just change this to 50, and you will see and here Heesknc we have an quite a lot of expansion. And whenever we are going to create the explosion, we will always need to add the divergence because divergence will add the expansion, and whenever explosion happen, it always expand. And I can control this value. I'm going to just change this value to 300 to really add more expansion, and heroes can see. We have a lot more expansion, and essentially this simulation is right now breaking. But it's not breaking. It's just expanding too much, and we are getting our slow feedback because we are dealing with bigger bigger domain size mean more wax cells and more wax cells mean more calculation time. I'm going to just stop this and let me stop this. I think it has been stopped, and Hees can see we have this higher expansion. That is the divergence. And right now we are using the burn as an A divergence. And I can create an a separate divergence if we go into the pyro but source and onto the bus component, let me scroll down. Heres can see we are creating these three sources. In here, I can create another fourth volume. Let's create this source, and let's add an A divergence in here. And if I were to go into the volume restraz attributes, let me it rewine and here, you will see that our divergence field is going to be added as well because we have used the preset and we are using the expression, and here we have the divergence. If I were to middle mouse button, we have all of these five attributes that now has been converted into VDB volumes. In here, we have this weird viewpoint visualization, as you know, this weird V pot visualization come whenever we have an a vector volume. And in here, we have the V, which is an a vector volume. I can go into the pyro burst source and just not calculate the velocity. And here you will see that our V pot visualization has been fixed, but we need the velocity because it's just creating a more interesting breakups. So let's keep at this. And because we are not going to render our velocity, we will going to use the velocity to add the motion blur. We actually do not need to care about this viewpoint visualization because it's not going to be rendered. When we are going to render, it will render just fine. But still, if you don't want to see this weird visualization of the velocity, you can actually hide the visibility of this volume by creating an visibility node, let's add an visibility and click on it or sorry, add this node down here. And after the visibility, all of my primitives has been hidden. As you know that these VDB volumes, they are in the primitive category. We have this volume and they are in the primitive category. Let's go into the visibility node. And in here, I'm going to just say, please hide the V V primitive. Name is equal to V, it's added this expression, which means that velocity is still there. If I were to middle mouse button, we have our velocity volume, but we are just not visualizing in the viewpod. It's hidden and I can fix our viewpoint issue, so I can go into the pyro source and we have all of this simulation accurately will work accurately I'm just not going to add this visibility node in here. Or maybe let's just keep this. It's not going to hurt us. Let's go into the pyro solver and inhere, I have created an A. Let me go into the burst component. I have separately created an A divergence. The reason we separate all of these components and her can see because divergence was working fine. And we are adding the burn into flame, and we were also importing our source burn into divergence as well. It was working fine. So why we are going to create an a separate source or this divergence. And that is because I can separately add noise onto my this divergence field onto this specific divergence. And after the pyro burst source, before we were to convert this into volume, you know that I can just randomize my attributes. So in here, I'm going to just add an attribute noise node to add the noise onto my field, and I'm going to add this. Inhe, the divergence is a float attribute, so let's change this to float. And in here, I'm going to add the divergence and let's just delete the CD. I don't want to randomize my CD. And into the divergence, I can change its value. I'm going to change this to zero centered, play around with the amplitude and element size. I can also animate my noise. Essentially, I'm adding the breakups into my divergence. And now I can just go into my pyro solver and inherent to the divergence. I'm going to say not use the burn, but I have dedicated divergence attribute, sorry, at divergence volume because we are working with this pyro solver, we have the volume. Let's add the divergence into divergence. Now we are using this break up version of all divergence to create more interesting looking expansion. Let's play and right now it is expanding too much. Let's go into the divergence and let's maybe change this value to the way that it was, and I think it was working fine. And same thing. I can keep adding the attribute noise node to break up all of our fields. Let's add another attribute noise. And let me first, we need to go back at the very first frame. And in here, I'm going to, let's say, break up my density field. And I'm going to just remove the divergence from here. I can play around with the different amplitude value, different element size, and I can keep breaking up all of my different attributes before I'm going to convert them into volume to create more interesting shapes. Let's go into the pyro solver again. And in here, I'm going to let's not use that much of our expansion. I'm going to just add value of one and let's play. I think I think the value of one is fine. And right now, the smoke, I think the smoke amount is not enough. So let's go into this density, and I'm going to just change this value to five to add more smoke into my sim. And now more smoke has been added. And let's go into some other parameter. Let's go into the field stab, and here we have the dissipation. As you know that dissipation control this density dissipation control or smoke dissipation. Lower this value down. I'm going to lower this value down to 0.01 to have a very low dissipation effect. Let's play again and we will see that a lot more smoke is going to be added into our sim. And Heres can see we have more smoke and it's not going to be dissipated very quickly. And Heres can see our smoke is staying and we have this cool looking fire and all of this smoke and I can go into my shape tab and I can play around with the noises. And here we are adding the disturbance. And we are also adding the turbulence and we have the flame expansion also built in here. And maybe let's go into the disturbance value. And in here, we have the baseblock and you know that this base block control this will control the breakups of the mushroom shape. And if I were to disable this, first, let's go back at the very first frame. If I were to disable the disturbance, you will see that we will get an smoother looking mushrooms. Here is can see these mushrooms are very smooth because they are not getting disturbed with the noise. So let's set the disturbance and that will break up all these mushrooms into more interesting shapes. Let's play again. Here is can see we are getting some nice breakups, which are good. Let's go. Let's go into the L tab in here. Let's play around with the smoke color. I'm going to just change this to and maybe value of something like that. And let me rewind and let's go into the setup tab and in here, let's lower down the auxel size. Let's start with 0.1 to see the result. And Here can see by changing the to 0.1, we have this very high ras. It's not very high as, but it's a decent resolution. We might need to lower this auxelz value down to create more highs version of our explosion. But right now I think this value is fine. Going to just stop this right here. Let me stop this. And down here, all we need to do is to just add a file cache node in here. Let's add a file cache, connect this, and onto the file cache, just go into the base folder, and in here, you can define your location where you want to store your caches. And onto the base name, I'm going to always I always just remove this dollar sign hip name expression, and I always keep this dollar sign OS, which means the operator name itself, which means I can just rename this file cache to let's say explosion. And you know that this space name is going to be changed to explosion as well. I can click on it. Sorry, middle mouse button onto this parameter to the evaluation, and here as can see it is evaluating as explosion. This name that we have written. That is good. And now in here, I can just lower down this overall duration. Let's say I'm going to let's only cache our first 60 frame. And here we have the start and end frame to change to 60 as well. And in here, we need to just press Save to Discption to write out our cache data onto our hard drive. And before you write out your caches, make sure to go into the Pyro solver and onto the output tab. Make sure to enable this convert to DB option and use the 16 bit float. Save out your cache size, make your cache size lower. Always enable these two options. And in here, you can define which of these fields these volume that you want to store. The default values are fine. Let's just keep them as is. Now into the explosion, just save out your caches. And in the next lesson, let's create some materials and render this explosion. 35. 35 Rendering Explosion: Now let's assign some materials onto our explosion, and let's render our explosion inside of sola ras. And here as can see at the file cache, right now, I am not loading my caches from my hard drive, and that is because actually, I haven't written out my caches. And if I were to enable this load from disk, and here as can see no caches has been there. And that is because I'm using this cache that is actually stored in my system RAM. I think I have stored the first 24 frames, and because it's an A pretty low as simulation of our explosion, and I have plenty of gigs in my system, I think we are fine for creating this lecture. So I'm down here, I'm going to just create an A null for the reference because later, we are going to import this into our solaris. So at the end, I'm going to call this one out, and let's hit space and type this render and that out for render, ready for render. Now in here, let's create an a lap network in here, and onto the lop Net, let's dive inside. And in here, we need to create an A sub Import node. Let's add this. And onto the sub path, I'm going to just select my this out, render node and hit Accept. And now this explosion has been imported into Solaris. Let me activate my view tool to adjust my camera angle and down here, we need to create an Kerma node for era rendered settings. Let's connect this and we might also need to add some lights and we will take a look at creating the lights later. But now let's talk about how we are going to apply the material. And right now, Hears can say material has been assigned. Let's go back onto my geometry and onto the pyro solver. As you know, if we go into the Lo tab, here we have the material, and down here we have this assigned material option enable, which means we are assigning the material. But this material, it's actually not good looking, and Hes our explosion looks ugly. But what we are going to do, we are going to use the Pyro BC volume. So let's add pyro volume node. Let's add this. And what this node will do, let me arrange this in here. What this node will do, it will also assign a material. Here as you can see assigned material has been enable, and in here, we have the material network location, Mt net and pyro Shader. It means that inside of the Pyrobic volume and heroes can see we have this lock icon, which means that it is an trigital acid, which means we can dive inside the node to take a look and heroes can see. Inside of that, we have this mat net. We are in the mat net and inside of the Mt net, we have the pyro shader. And we have all of these parameter exposed at this level at this pyropaic volume. So inside of that, we have material network and we are getting pyro shader. And this pyro shader will create a good looking explosion material. And right now we are creating the smoke, and here I can adjust the density of my smoke. I can play around with my color, and that is the color that I can set the color that I like of my smoke. And let's go into the scatter tab and let's enable the scatter. And this scatter option will going to create this good looking or this explosion material. And what this scatter is actually doing, if you were to enable its help menu, and here we have the help for the spiro Bake volume. And I encourage you to read this help because it's written in it has been detailed. All of the information has been very detailed written in this help, and here we can scroll down and here we have the scatter, and here can see. Have the scatter and what this scatter is actually doing, it's using the temperature field to create this glow on the inside. So which means that we are creating this light scattering effect. And here we have the mask and here's can see enable mask option. And we are using the density field to mask out this fire to create this crusty explosive looking look. Let me enclose this, and let's go into the scatter, and here we have the masking option enable. And if I were to disable the masking and heroes can see, we are getting this color from this intensity. And what that is, it's actually the temperature field, which means that wherever we have the hot spot, wherever we have the temperature, we are using this ramp to set our color. I can play around with this ramp. I can change this to red color, and heroes can see. Basically, we are using the temperature and using the ramp for assigning the color to create this light scattering effect. And then we are going to use our density field if I were to disable the scatter and heros cans, we have this smoke, this density field, and we are going to use the density to mask out this temperature or this glow. And if I enable the masking, and here as can see we are masking out of our density to hide to remove some of this glow to create this look. And I'm going if I were to enable the masking, here we have the option for the masking related option, I can play around with the mask width to create a higher width of this mask. Now Hears can see I can see more of my smoke and less of my inside glow. I'm going to just default out this scatter ramp so present hold the control and middle mouse button to default out. And Hears can see I'm seeing more of my smoke and less of this glow. I'm going to default out this mask width the default values are fine. In here, we are blurring out our mask if I were to disable the blur. And hers can see we have this very harsh cut off from the smoke, and let's also enable the blur to add the blurring effect, and the default value of blurring is also fine. And in here in the intensity scale, I can adjust the intensity, and if I were to lower this value down, and here you will see that we are creating less of the intense of its inner hard core, and I can play around with this intensity scale to create more of this glow and at the Pyrobic volume, we are actually baking this scattering volume, which means that this scattering is not going to be calculated at random time. We are baking this scattering. That is why it's named to Pyrobic volume, and it is good for creating the explosion material. And now, which means I need to just connect this inhere. And because we are referencing this out null or these new changes is going to be also imported into the lob net. Let's dive inside and inhale. And here as can see our V booard has been refreshed, and now it's matching with this soft level view booard. Let's dive inside the lob net. And in here, here can see because we are using the Bake volume, and we have this material net, this mat net inside of our Pyro Bic volume, matt, this material net and this pyro shader is not going to be imported inside of Solaris. And if I were to render this, let me go into the Kerma render setting, and here you can see right now I'm using the CPU engine. Let's keep this at CPU engine. In here, I'm going to, let's change this to Karma, CPU and heroes can see our rendering is not look the same. And that is because we need to import this material into the solas as well. Right now, we are importing our volume, our explosion, but we're not importing materials. You know, to import the materials, we need to create an material library node. So let's add library because materials must be going to be imported separately with this material library. So let me add this in here. And in here, we know that onto the fill tab, let me collapse its menu, and in here, we need to define the material network. And right now this dot mean that look at the materials that are inside of this material library. If I dive inside, right now it's looking inside and in here, right now, nothing is here, which means if I were to click on this auto fill, nothing is going to happen because no materials are present inside. What I can do, I can just change this material network. In here, let's pick up the location and we know that our material lives in the Pyrobic volume. Let's click on this. Plus, I can go inside of this Pyrobic volume node. Let's click on it, and in here, we have the MD or material net. Let's like this and hit Accept. Now material net has been this location has been assigned. Now all we need to do is just click on this auto fill material. Let's click on it and hers can see. We have this pyro shader imported inside of Solaris. And now we just need to assign this. And right now assigned to geometry option has been enabled, but geometry path is empty. I can just click and drag in her to assign this pyro shader onto this sub import, and it will work. Now if I were to change this to Kerma pew, and now here can see our material is working, and I can adjust my material setting from this pyro Bic volume and let me go into the lop Nt. And in here, I'm going to just pin my viewpoard onto this Solaris context by clicking on this following selection, this pin icon. Let's click on it. And when this option is enable, our viewport will going to be looking at this location and Hees can see we have the location. We are inside of lobNd if I were to go back onto the GMT node, our viewport focus has been stick onto the lob net, which means I can come over here onto the pyropic volume. I can play around with the intensity scale and Hers can see we are changing our materials. I can come over here onto the smoke, I can play around with the color of my smoke. I can change this to any color. Let's change this to blue to make my point that this material is working. And adjust the density. Let me keep adjusting its density to create more thicker smoke. And this material, one thing to note that this pyro shader that is actually available inside of the Pyrobic volume, and now we are important in the solaris context. This pyromateial is designed to work with Kerma CPU. Which means let me unpin this because right now we are in the solas context, we do not need to pin this. If we go into the Kerma render setting, and if I were to change this to XPU and right now we are using the Kerma CPU. If I were to change this to Kerma XPU, this material will not going to work because this material is designed to work with the CPU, with the CPU render. Kerma CPU and Kerma XPU are not the same render engine. They are completely different render engines. And to actually make this material compatible with Kerma XPU, we need to create material inside of the SolaraS, which means I'm going to just I'm going to just remove this material. Ibrary I'm going to create an material library in here once again. Let's add this, and I'm going to dive inside. And in here, if we right click and here we have this kerma, let's go into the pyro. And here we have the Kerma Pyro explosion material. And this explosion material will going to work both with Kerma CPU and XPU. So let's add the Kerma explosion material. And here we have the material, and we need to dive inside to have access to its actual shader. Here we have the Kerma pyro shader node, and in here, we can adjust the density scale and hers can see the parameters are these perimeter looks different because it's a separate shader. Let's go into the scatter and by default, the scatter has been enable which means that we still need the Pyrobic volume. That's here we still need the pyro Bic volume to calculate this scatter volume. And if I go into the file cache, sorry into the Pyro solver, it's actually the same if I were to go into the file cache node because we are still using this pyro solver. And if I were to middle mouse button, heros can see we have four VDB volumes, we have burnt density divergence and temperature, but we do not have an a scatter volume. And this pyro Bic volume will going to calculate scattered volume for us to create this scattering light effect. And let's go into the Pyrobic volume because this scatter has been enable and if I were to middle mouse button, and in here, now we have five VDB volumes. Now we can see we have a new volume called scatter. This scatter volume is what this pyrobic node is calculating. So we still need this pyobic volume, but this pyobic volume is actually not going to assign material, but we are actually using this to create our scatter volume. So which means I can go into the lop net and we need the Pyrobic volume as well. Let's go into the lop net and into the material builder. And inside of our Kerma Pyro shader or scatter has been enable, which means I can just adjust the settings to create the same look. And right now, it's not doing anything because let me change this to Tini volcan viewpoard. We need to actually assign this material. Let's go into the material Library. Click on this autofil to fill out our material. I'm going to enable the assigned to jump tree option and track this in here. Now if I were to change this to XPU and Hears can see our material is working, but right now the settings are not the same. So let's go into the material library and into the pyro explosion material, and into the Kerma Pyro shader, I'm going to just increase the intensity scale, and I'm going to just increase this to 250, and hers can see we have the scattering effect back. And because we are using the XPU and heres can see the rendering is very snappy, we are going to render our explosion very fast. And inhale onto the smoke, I can play around with the density to create more thicker of my this smoke. I can play around with the smoke color because now that is our actual material. We are creating the material inside of Solaris and that is responsible for actually creating the material and assigning. Let's go back and inhere. And if you want to create an XP based rendering, make sure to create your material inside of this material library by using the Kermopyroeplosion material. And in the next lesson, let's take a look at the ***. And right now we are rendering our explosion. We have assigned our materials, but right now the colors are not accurate, and we'll see how we can fix this coloring issue in the next lesson. 36. 36 Rendering In ACES: Now let's talk about ACS color space, and heroes can see our render is not looking right. These colors are not right, and that is because if I go into the Hodni volcan, we pot and let's go back and onto the Pyrobic volume, and heroes can see we have this color RAM. And these colors, these Rams are actually designed to work with ***. And right now, by default, Houdini does not use the ACS rendering to render out your explosion. All of your rendering, it's not going to be used As by default. And to actually render our explosion or these colors accurately, we need to change color setting to *** and we can do that by going onto the edit and here we have the OCIO setting. Let's enable this in here, Heres can see, we are using the render working space with the linear Rec seven oh nine, which is an SRGB color profile, and we need to change this to ASCG. Let's change this to SSCG and now we are rendering with the ASCG we also need to change the view transform because we need to convert the As color back into ARGB because our monitors or displays sports in SRGB. Which means we need to convert these original *** back into SRGB for viewing or for displaying purpose. So onto the view transform, let's change this to *** 1.0, the STR video. And now with all of the setting set, you can just click Apply and accept Make sure to change them to ***. Let's apply and accept Okay and hers can see our colors has been changed, and now our colors look more rich colors. Now if I go inside of the lop net in here and if I were to change this to Kerma XPU and Hearers can see we have our color displayed accurately and we are entering them in red color space. I can go into the material library and in here, let's play around with this scattering intensity. I'm going to just keep increasing this intensity to my liking. Let's keep increasing this. And maybe let's go into the smoke and let's also play around with its color. I think the color is fine, but we need to adjust the density. I'm going to just continue increasing this density to my liking, and I can go into the scattering and in hair, we have the option for the masking. And I can play around with the mask center. I can lower down the mask center value to create more mask 0.05. And now by adjusting the mask center, I'm basically revealing more of her smoke and hiding my this hardcore scale. I think the value of 0.1 is fine. Or default value was 0.2. Okay, the value of 0.2 are working fine. And these are the accurate colors. But what actually is ACS? So what we just did the *** if I go into my Google chrome and here we have the demonstration of the ACS color profile. And here we have the color primaries. We have all of these colors that are actually available. These are all the colors that human eye can see and differentiate between them. Example, if we have two greens, let's say, if we have an multiple green value of a leaf of a tree, so all of the greens are not the same. We have different kind of shades in green, and the SRGB here as you can see, we have the SRGB in blue. This SRGB color space only sport so much color. So we do not have access to all of our color information. But ACs on the other hand, if you take a look at this rectangle, As sport, all of the color range, all of the color primaries. It is a much wider color space. If I go into the ACS color, and here we have the ascolorspace.com, and in here, you can read more about ACS and here we have the SRGB, and here as you can see we have fiber to expand this in here, as you can see, we have the color and we have some blown out details and the colors are not very good looking. Now if we take a look at the ASCG and in hair, we can see that we have color more rich color, and we do not get these blown out highlights, and we are preserving all of the colors and we have different kind of shades of color which are more natural. And in here, you can scroll down and here we can see the color gamet if I click, and here we have the comparison between different type of color profile. At the very top, we have the As in red, and here's can see, that is the red. And here we have the SRGB that is defined in this bluish color. That's surlan color. ARGB we find, and here we have this. That is the SRGB colors. And here's can see inside, we are actually limited by these colors. ARGB only sport just these kind of shades of the colors. And on the other hand, SS sport all of the colors. So it's a much wider color game. And here we have another comparison between SSCG and SRGB, and here we can clearly see the difference how wide this color gamete is. These are explosion materials. These colors, if we go back, all of these colors are based on AS, and we need to use the AS colors for rendering. And inhere, let me go back onto my lop net. Inhale, if I were to change this to let's say CIU settings, here we have the view transform, and we can also view this view transform. If I were to click on this kerma XPU where we have the Houdini k and all of these option, here we have the option to enable the correction tool bar, and right now it's disabled. Let's enable this. And down here we have some new option. And here as can see we are using the IO option is enable, which means that we are using the open color. And in here, we are using the SRGB display, which means that my monitor, it is an ASR GB monitor, so we are converting our As color, all of these color game let me go back or this As color gamut because our monitor cannot support the AsO monitor does not have the ability to display all of these color. We need a way to convert these As colors back into ARGB for displaying, and that's what this view transform is doing. Let me go into the OCI setting. This view transform this view transform is doing, it's looking at the AS colors and converting them back into the appropriate ARGB value for accurately displaying onto our monitor because our monitor sport SRGB. And in here, we can see the view transform. Right now, we are using the ***. I can change this to raw, and here can see what is the raw values for the As. And here we have the As. And right now, the colors are not accurate because our monitor cannot display the *** colors, and that is why we have some of the blown out details and all of these high information of colors, and we need to convert them back to ***. So let's click on this AS 1.0 SDR which means we are converting this back into SRGB, and I can click on this, and here I have some other option. I can change this to, let's say, rack 2,100 and here can see the color looks completely different. I can change this to display B three display. We have some other option, but I'm going to change this to SRGB display because most of our monitored sport SRGB, and right now it is saying untone map. I'm going to just use the ACS color lt to convert all of our colors into SRGB accurately. That is the AS and make sure to enable the AS color from the OCIO edited setting. And you should always use the *** CG because it is a much wider color space, and we will going to render out these sequences in ***. And down here, if you are going to using the ACS, let me go into the *** if you are going to use the ACS and onto the Kerma render setting, I'm going to go into the output picture. I'm going to define the location where I want to store my sequences, and if you are going to write your EXR sequences, these EXR sequences will going to be written in assays, and I can confirm if I go into the edit and OCIO settings. And in here, we have these names and the extension, and I can find. If I were going to be using the EXR sequence, and here as you can see, we have the color space. Sorry, if you are going to write the EXR, we are not going to be rendered in the essays, but Houdini will use this linear Rec 709 to use to render your these colors in the Rec seven oh nine format color space. And if you want to render them in the inside of the As CG, you need to type the As CG in your name. For example, I can go into this location. I'm going to just create some folder wherever I want to store my renders. Let's say I'm going to use this default location, and in here, I'm going to type the name, and I'm going to type the name explosion. And anywhere in the name field, I just need to type the AS As and the CG, and CG should be written in the lower case. And now, when in the name, we have the As CG, and now I can type the dot EXR because I want to write the EXR sequences and accept. And I also need to add the Tolo sine F, which means that we need to because we are going to render out the sequences, we need the unique identifier for the frame, after that, I'm going to say underscore Dlo sine F, which means the current frame number, and that will be added into our explosion SSCG and frame number. That way we have the unique name and we will going to render out these sequences. Now hit Accept. And now that because SSCG is present in the name, and now if I check into the OCF setting, and here as you can see, we have this pattern. This star means that at the start of the name, so at the start, whatever the start is, I have the start of explosion, and after that, if the name SSCG is present, right now it is present, Houdini will going to be using this ASCG color to render out your sequences. Mean that the EXR sequence is going to be written in AS color space, and then we will going to be using our composting applications such as Photoshop or Adobe Premiere Pro or Nuke because we are working with these animation sequence. Either you are going to be composite in Nuke or Premier Pro, sorry, after effects. Both of these after effects and Nuke sport the AS color space. We are going to be converting this back into SRGB color in our composting application. So make sure to render out your sequences in the AS color format. You can change this to As or I can go into the edit OCIO setting. And in here, I can say, if I were to render route my EXR sequences, XR if I'm going to render EXR sequences, please do not use the linear Rex seven oh nine. I can just click in here and I can choose. I can say AS CG. I can say it accept, which means that now, I do not need to say SSCG. I can just go in here, I can type my name. I can say explosion, and same way, I can now say Dlo sign F, the current frame number for unique identifier, and then the EXR. And now because we are using the EXR sequences, and we have set these settings in here that whenever we are going to render out the EXR sequences, please use the AS CG. Now Houdini will use the ACS as an A entering color space. So make sure to pay attention to these settings whenever you are going to be working with ***. So that's how you can render out your explosion in the correct color space. 37. 37 Intro To POP Solver: Let's dive into particles. Let's create some particle simulation. And first, I'm going to create an empty geometry node. So let's add an Jumptr node in here and let's dive inside. And in here to create the particle simulation, we need to create our Dp net because particle is an dynamic simulation, we need the top net, and in here, I can add an a top network node, and I can dive inside. And in here, as you know, all of these simulation, whether it's a particles or RBD, it's a smoke simulation. First, we need an A object. And same thing in here to create the particles, let's type in here Pop. And if you type Pop, we have all of these nodes that are designed to work with particles, but we need the pop object. So let's add a pop object. This pop object, it will store all of these attributes and particles and all of the essential information. All of this is going to be stored inside of pop object. Now we need the pop solver. So let's add and I pop, and now let's type the pop solver node. Here we have the pop solver, and here it has these multiple inputs. Let's hover over to them, and first one is the object, which means we need to connect this in here. Now, this object will store all of the attributes and data and information and this pop solver will responsible to solve all of these information. And we just need to connect this inhere to the output and to actually import the sources because, you know, we need the sort of source, some sort of emitter that will emit particles. And to import our sources, we have an ode called pop source because it's a particle simulation. So we need to type pop and now source. Pop source, and here we have it. And let's hover over to this. So the second input is the pre solve and this last one is for the sources. So which means we need to connect this in here. And with that, this particle network, this top network has been completed. And now we just need to import our sources from sob into dubs. And first, we need to create our source because right now, inside of our geometry, we do not have any source. And for that, I'm going to create just simple sphere. Let's create this, and I'm going to just connect this in here. I can dive inside the top net, and onto the pop source, here we have some of the parameter at the sources. First, we have the emission type, and it's set to scatter on surface, and we will talk about that later. But down here, we have the geometry source. And right now, it's saying that use the parameter value, which means that we need to define it from here. So in here, I can just pick my source that I want to import, so I can go into the object, Geo one, and the sphere. I can hit Accept. And now here as can see our source has been imported into dubs, and it is visualized in this blue and here we have this guide. I can enable or tsable this guide, and onto the gem resources, let's click on it. And in here, we have the option, which means we can use the use first context, second context, we have all of these context. I'm going to select this one use first context. And here as you can see our source has been still present, and that is because these contexts, the first, second, third, and all of these context, fourth context, these contexts represent all of these inputs. And here as you can see onto this top net node itself, we have these inputs. We have one, two, three, and four. We have these inputs, which means that we are referring to that please pick our geometry source from the first context. So whatever the geometry has been plugged into its first input, and we have the share in here. In that way, I can just very quickly import my sources from SOP into Doubs. And while we are in this geometry context and in here, if you type Pop Net, so I'm going to type Pop, and here as can see we have this one node called Pop Network. And if you add this, and Hears can see we have the same this dynamic context node. So it is antill Dpnet which means if I dive inside this and Hears can see we are in the dynamic context, and here we have these basic nodes already there. We have the pop object, we have the pop source node for importing the sources, and we have the merge node, and that is because let's say if I were to import multiple sources, I can create another pop source node we are not just constrained to this one single pop source node. I can add another pop source node, and in here, I can pick up my own another emitter and I'm going to just connect this in here and I can keep adding multiple of these pop sources. And that is why we have this merged node already in here in this dynamic node. You can just remove this if you don't want to, but it's not going to hurt you if you're going to keep this merge node in here. And whenever you are going to create the particle simulation, and it is much easier to just type this pop network, and it will create these few basic nodes for creating the particle simulation for you. And you do not have to every time create this pop object, pop solver, and the pop source. But since we have created, let's use all of the setup that we have just added ourselves. I'm going to just delete this pop net in here. And now let's go into the Dpneet and onto the pop sources, and we have used the first context geometry. And the first parameter, it says the emission type, and right now we are using the scatter onto surface. It means that we are scattering particles onto the surface of geometry and let me enable my playbr to actually play back our simulation. Let's hit play and heroes can see particles are being born at the surface of our geometry. Let me enable this real time playback so that we have this real time playback animation. And heroes can see these particles are being born at the surface of our geometry. I'm going to change this emission type. Let's click and heroes can see we have all of these options. So the first one is the all points. Let's click on it, and let's hit play. And heres can see this all points method. At first, it seems that it's not doing anything, but if I were to hide the guide and Hears can see by using the all points, it means that we are importing the points from our original source geometry. And heres can see at this sphere, if I were to say, extract all points, let me add this and connect this in here. And Hees can see we are extracting all of these points, and we are importing all of these. Let me enable the point display. Importing all of these same points inside of our drop net. And in here, we are using the all point method, which means that please use the point count that we have present in our soaps, which means if I were to increase the rows and column, and as you know, increasing the rows and column, we are effectively creating more of these points, and we should see that all of these points being imported in here and heres can see we have these points. So in here, we are adding all of these points every frame. And if I were to middle mouse button, and I can see how many particles are actually in my simulation, if I were to press and hold the middle mouse button onto my pop object node because, you know, here we have the pop object that will store all of these points and all of the attribute. Let's press and hold the middle mouse button. And Hears can see we have 3,000 points at the very first frame. And if I were to go a few frame in here and hit play, and now heroes can see we have 17,000 points. So if I were to keep playing this, let me keep scrubbing my playbar and press and hold the middle mouse button, and Heroes can see now we are at the 76,000 points, which means that we are adding all of these points, all of these input points every frame inside of this Dp net. Right now, we have all of these points, but they are not moving, and they are not moving because as you know, that currently there are no forces, and we need to create some forces. These forces will make the or these particles move. And to create the force in here, first, we need to type the pop because we want to control the particles. So we have all of these relevant node for the particle simulation. In here, we can create A, I'm going to just add PA force node, and here we have a PAP force, and we need to connect this in between inhere. The POW force is going to be connected in hair so First, we need the POP source and then we are going to create POP force. Inside of the POP force, let me hit rewine at the very first frame and in here, we have this force value. In here, we can define the axis at which axis we want to add the force. And let's say if I were to add my force at the X, I'm going to just change the X value that is our X Y and Z, and to the X, I'm going to just change this value to one. And now, if I hit play, and heroes can see our particles are being imported from the sub geometry into dubs and this pa force node is moving these particles onto the X axis, every frame. And down here, we have the noise, and right now, heroes can see, we have this very straight movement. We just keep trailing our original sphere geometry. Let me hit play. Sorry enable by this display point visualizer, and heroes can see we are just trailing our sphere. There particles are being bond and moving along the X axis. And in here to create some interesting movement, I'm going to just introduce some noise in our force. So down here, we have the noise built in onto this force node, and we just need to increase the amplitude of our noise. Right now, the amplitude is zero, which means no noise. I'm going to just increase its amplitude to some value, and let's hit play. And here we have some lot more interesting movement or particles. And that is our very first particle simulation. Now let's go into the pop source node, and that is the all point method, which means that we are importing all of our points from sobs into tops, which means I can go back onto the sphere. And right now, if I dive in and enable this Dp net, and here's can see how this geometry is hollow and because we are using the all point method, which means I can just add an a scatter node in here and this scatter node will just it's going to scatter some points onto the surface of geometry. And in here, I can define the number of points that I like. And right now heros can see, we have this regular arrangement. We have this even distribution of our points, and I can create this randomization of this scatter position by disabling this relax iteration option. And this relax iteration is just relaxing these points. I'm going to just disable this, and now Harris can see we have some irregular pattern, irregular arrangement of our points. And if I were to increase the scatter amount, and now Harris can see this scatter is going to be scatter points much faster because it's not going to relax these points, and if I were to enable the relax iteration, and Hears can see this force count is now or this kan node is working slow because it needs to calculate this relax iteration, and I'm going to just disable this to create a random distribution of the points. Now, let's go into the top net and inhere, let me dive inside and hit play. And here as you can see, we have this irregular arrangement of points, and we are importing all of our points from sops into dubs. And I can fill my this geometry because right now, our this scatter node is just scattering the points onto the surface of our geometry and to create points inside of our geometry. We have an node also called points from volume. If I type points, and Hears can see we have this node called points from volume. Let's add this and connect this after that. And what that node will do, it will scatter points onto the inside of our geometry, and Hears can see we have this guide onto the points from volume node. We have our original geometry guide visualized, and we are scattering points in the inside. And right now they are a bit hard to see. Let me go into the points from volume and inhere, increase the number of points. I can increase the number of points by lowering down the points separation. And in here, I'm going to just lower down this point separation value to 0.0. One maybe, let's say, and now here as can see we are filling our entire geometry with points, and maybe let's increase this value to 0.06 maybe or maybe 0.04. Okay, I think we have this nice visualization, and now to actually hide our original guide visualization, we do not have any option built in here to disable this guide. I can just create an null node at the very end and I can just view this null and that will hide this visualization. Here as you can see we have particles in the inside and right now they are in the regular arrangement. Let's go into the top net and in here, as you know, we are importing all of our points and let me zoom out and hit play. Now we have our source filled with particles and we are importing them every frame into dubs. Let's go back and onto the points from volume. Here we have some option right now. They are in the regular arrangement. I can just enable this jitter scale option to make the random distribution of our points. And now Hears can see we are breaking up all of the regular arrangement by just enabling this jitter scale. I'm going to just change this to one, and I think the value of one is just going to add complete jitteriness, and that is fine. Now let's go into the top net and hit play and we have all these particles. I'm going to just remove these points from volume load, and now let's t inside, and that is the all points. And now the second option, we have the all geometry. And what that will do, it will import all of our geometry from sobs into Dubs, and here as can see. Now we are also importing all of our geometry, which means the primitives, if I were to enable let me enable the selection tool. And enable this primitive selection, and here as can see, we are importing all of our primitive vertices and edges into dubs, which means all of our geometry. Before that, before the all points, we are just removing all of our geometry. We are just keeping the points. All points just going to import the points. The all geometry is going to import all of our geometry from sop into top. Which means we are going to be importing all of our geometry every frame. And in here, I'm going to first let me lower down the number of these points because, you know, we are going to import this every frame, and it will going to get heavy and I don't want that. So I'm going to just lower down the number of points to create a very coarse representation of our geometry, and here can see. And that will be a very lightweight geometry to import every frame. Let's go into the top net in here and let's hit play. And here us can see all of our geometry has been being imported, and all these points are going to get distorted with this path force. And if I were to remove the P force node, let's hit rewind and hit play. Sorry, I think I need to connect the force to get the particles moving. But I'm going to just zero out the noise. I don't want the noise in here. Let's hit play again. And hers can see all of our geometry is being imported in here and we are creating this some sort of trailing effect. Let me increase the force. Let's maybe increase this to value of six, and that will create a faster movement. And if you want to create this, import your um try in here, you can create this all jom try node. And down here, we have the option points. And what this points node will do, it will going to be emitting particles from the points randomly, let me increase rows and column to create this regular arrangement of our spare. Here as you can see, we have these spares. Now if I were to dive inside, and hit play, and hers can see what it's doing, it's actually still using these same points. But now we are just randomly selecting these points of our input points and adding them every frame. And I can control this onto this emission type and number of these points by going onto the Perth tab. Let's go in here. And here, I can play around with this constant birth rate. And if I were to increase this and heroes can see by increasing the constant birth rate, I can clearly see that I am still using my input geometry or these input points, and I'm just not importing all of our points, which means that before that, we are importing all of these points every frame. But by using these points method, emission type points, and now I can just control how many points I want to import by this parameter, this birth rate, which mean if I were to lower down this value, going to just keep lowering this value down to maybe 100, and here as can see we are just importing 100, emitting 100 frame from all of these geometry points. So these points will act as an source. These source points will act as an source. That's what this point method is the source animation type points. And we have the scatter onto surface. This scatter on to surface is by default, this default method is scatter on to surface, which means I can go back and hit play. And in here, we are just randomly scattering bunch of points onto our geometry every frame. So we are not using all of these points right now. Using the scatter to surface, we're not using these points, these points. We are just scattering points. And this pop source node is basically adding an scatter node that we had in here. This scatter node, I'm going to just uncheck this relax iteration. It's just going to scatter these points and import them into the tops. And we are doing all of these operation inside of this pop source node, and that is the scatter onto surface. I'm going to increase the birth rate if I want to create more of our particles, and let's play again, and there you go. And in the next lesson, let's explore some of the forces of the particles that will control the behavior of these particles. 38. 38 Particles Forces: Now let's talk about particle forces, how we can use forces to control the behavior of our simulation with using the forces. And right now, here as you can see, we are using the Pap force node. And in here, I have default out all of the settings. And at the very first, you know that we have the axis and on which axis we want to add the force. And in here, we also has an node called pop wind. That's a pop wind node, and if I were to enable the parameter and here you can see, we have most of the parameters, they look the same onto the pop force as well as onto the p wind. In here, we have this wind velocity. We have the same axis, the X, Y, and Z. And in here, we have this additional parameter there. We have the wind speed, and we also have the air resistance, and same thing onto the force, we have the force, we have the axis, and down here, we have the noise, and we have all of the noise option onto the pop wind as well. Let's see what is the difference between the PAP force and the PAP wind node is. If I were to enable my PAP force, let's say, I'm going to add an F force onto the X, and let's add this into one by using this parameter, and now we are adding the force onto the X. And Hearers can see these particles are going to be accelerated over time, and Hearers can clearly see that they are starting slow and over time, they are going to be accelerated. So the P force is a force of acceleration. So all of these parameter is going to be accelerated over time. And inhale by using the pop wind node, if I were to remove the pop force node, let's add an pop wind inhale. And same thing, I'm going to add wind velocity onto the X. Let's change this to one and hit play. And here as can see we have this wind velocity X uniform. That is an a uniform force, pop wind. It's not going to be accelerated over time, but it's going to be a uniform velocity onto the one entire of this simulation duration, and hers can see. And if I were to just remove this and let's add an APA force node in between and let's play, and Hearers can see they are starting slow, and as the simulation progresses, they are going to be accelerated over time. We can use this PAP force node to, for example, create an gravity force because as you know, that gravity is an a force of acceleration. So we mainly use this path force to add the gravity effect. And onto the X, I'm going to just zero this out. And to add the gravity, we know that the gravity value of our earth is 9.8 because we are working within this three D scene and we have all of these xs, and the gravity should move these particles down, which means we need to add an A force value of minus. So we need to add an A -9.8. And if I were to add just 9.8, as you know, it will be an faster value and our points will move up. And here you can see our particle simulation is moving upward, and to create the gravity, we just need to add an A minus sine in here, which means that we are creating an A gravity and gravity is pushing these particles down. Let's it play and heroes can see, we have these particles moving down with the gravity value. And in here, we also have an a gravity force. If I add an A gravity and heroes can see, we have an a gravity force node. If I add this and Heres can see this gravity force node looks different than this force node, and that is because this gravity force node is designed to work with all of the solver. And as you know, we have inside of the dynamics. We have all of the solver. We have this particle solver and we also have our smoke solver, if I add this, and we also have our RBD solver. And let me find here, I have the RBD solver. So we have all of these different types of solver for different types of simulation. And this gravity force is designed to work with the forces, all of the solvers, which means I need to connect this after the pop solver. So whenever you have Solver first, you need to create your solver, and down here, you can just add the gravity and it will work. And I'm going to just remove the P force node inhere, and Heres can see, I still have the gravity. And same thing, you can also connect this inhere into the pop object, and it will work fine as well. And Heres can see. You can add the gravity like so, or you can use the PAP force node and add an A -9.81 to connect this inhere, and that way, I can create my gravity. I'm going to just remove this gravity force. I'm just going to use this force node to create my gravity. And in here, now we have this pop win. And as you know, that pop wind is an A uniform force. So let's add an I Pop win in here. In here, I can just add the amplitude to add an noisy wind. Let's increase some of the amplitude value so that we have some noise, and here as you can see our gravity is pushing particles down and we have some of the noise stuff velocity because there is a wind in CD scene with this pop windlo. In here, I can adjust the wind speed. Let's increase the wind speed and hit play, and here as can see our wind speed has been increased. Let me keep increasing this and here I can clearly see the effect of the wind speed. And down here, we have the air resistance. This air resistance is a force or drag, which means it will drag down this wind speed. It will right now, it's very hard to see. Let me increase this air resistance to a higher value, and I still cannot see the effect of it much. But basically, it will add a drag force in here. Maybe if I were to just remove the force known, in here, create an pop in and hit play. And right now it is a very chaotic animation. Let me change this to value of one. And I think I need to lower down the amplitude to lower value as well, and let's hit play. And this air resistance is basically dragging down all of our forces back. We also have the drag force in here present if you create a pop, if you type pop and add an Apoptrag. And here as you can see, we have the pop drag force, and we have the pop drag simple, and we also have the pop drag spin. And this pop drag spin, it will drag down the spinning motion of the particles. And right now we are not adding spin in our particles. We are just using the noise to add noise wind velocity. Going to just zero out the air resistance and maybe let's increase the amplitude value. And I think we need the air resistance because it's an A multiplier to have an A effect. And after that, I'm going to add an A pop drag node, and let's connect this in between. I'm going to just improve this pop drag spin. Let's go into the pop drag and heres can see we have the same parameter. We have the air resistance. We also have the wind Vlocty, but in here, we do not have the noise in here. Onto the pop wind here as you can see, we have an additional noise. In here, we do not have the additional noise. In here, I can keep layer down the air resistance. It will continue to add an drag force in between. And heroes can see our particles are now sticking together because there is an drag force that is dragging these particles down. And in here, if I were to remove the drag, I'm going to just shake this node off and hit play. And heroes can see we have these particles going everywhere, and right now, all of the particles are sparse. And hers can see they are very sparse. There is a much more separation going on in our particles. And if I were to add an A pop drag, and this pop drag will going to drag down all of these forces. And that way, these particle will stick together. And here you can clearly see that now we are getting some of the clumps, and that is the pop track force. It will drag down all of your forces. So I'm going to just remove both of them pop in and pop drag and let me hit rewine and onto the pop source. In here, we forgot to talk about this perthtb and in here, we have the impulse activation and the impulse count. Right now, the impulse activation is on, and the count is set to zero. And down here, we have the constant activation, and we have the constant birth rate. And right now we are using the birth rate of 5,000. This constant activation and this birth rate mean that how many particles are this system should emit in the course of 1 second. And as you know that right now we are using the 24 FPS, and I can confirm if I enable my this global animation option, let's enable them, and here is can see we have the animation option. And at the very first, we have the FPS. And in here, here is can see, we are using the 24 FPS, which means at the frame of 24, we have reached 1 second. So it means that at the frame of 24, we should see 5,000 points. And if I were to middle mouse button, and here you can see, we have 5,000 points. So constant activation is the amount of particles emission over the course of 1 second. I can increase this birth amount, and we will get that many particles over the duration of 1 second and on the second second, which will be the 48, we will get this number double, which means that we have toys amount of these particles because right now we are at the 48 frame, which happened to be our 2 seconds. And that's the constant birth rate, and we have the impulse activation. And if I were to zero out the constant activation, if I were to zero this it means that we are not using the constant Perth thread, so no matter what value you should put in here, this parameter will have no effect because we are not using it, and we can control this by this activation. And in here onto the impulse activation, the activation is enable, but there is an impulse count and it is set to zero. It means that how many particle you want to emit every frame. And in here, I can say, I want to add 100 particle every frame. And if heroes can see right now we are at the very first frame, and if I were to middle mouse button and Hears can see, I have 100 point. And same thing if I go onto my second frame, now I am at the frame number, second frame, and now I should see 200 point. And if I were to middle mouse button, and Hears can see, we have 200 points. And I can keep playing this. And if I were to middle mouse button and Heroes can see, the point count has been reached to 1,600. So the impulse count is control how many particle you want to create every frame. And I can control this if I were to go into the impulse activation, let's zero this out, which means that we're not using this value. I'm going to enable the constant activation. Let's change this to one and hit play. And I think I'm going to lower down the number of particles. And down here, maybe first, let's create a force in here. I'm going to just add an APP force. And as you know, that not Pop excess force, but the Pop force node. Force, I'm going to just add some noise in here. I'm going to just introduce some noise by adjusting the amplitude value and hit play. Let's go back onto this pop source node, and in here, we have the life expectancy. And right now we are using the 100. This life expectancy is in seconds. And if you hover over to the parameter, and here you can see we have the information how long the particle will live in seconds. Right now our particle will live 102nd. I'm going to just lower this value down to one, which means that now our particle will only live for 1 second, which means at the course of 24 frame. Let's go back and hit play, and here as you can see at the course of 1 second, all of our particles are going to be removed from our simulation. And same thing, I can increase the life expectancy if I want to lift the particle, make these particles live long. I just need to increase the life expectancy, and now we should have a longer lifespan of these particles. I'm going to just change this to one, and in here, we have the variance, which means I can add an a random variance in all these particles. And right now, has can see all of our particles are being tied off at the same time uniformly. And in here, I can just introduce some variance by adding life variance in here. And now we should see the particles, and in here, we have the variance of plus and -1 second, 1.3 second. And in that way, I can randomly make the particle disappear from our simulation. And onto the next step, we have the attributes, and in here, we are inheriting the velocity. Right now, it says inherited velocity and use inherited velocity. And it means that if I were to remove this p force, now I don't need the B force. And in here, we are saying that use the inherited velocity. It means that please use the velocity attribute that is present in our source. And right now, we do not have velocity present in hair. Five or two middle mouse button. And heroes can see we do not have an AV. V is used for creating the velocity, and currently, we do not have that. And what we can do, we can create an AV in this soap level, and this will going to be inherited by these particles or this p source. And source, this particle simulation will use this velocity to make this particle move and inhere at the sphere, I can create my V by adding an A. Point velocity node. So if you type point and in here, we have this node called point velocity. Let's add this and we need to just connect this. And what this point velocity node will do, it will add an A attribute V if I were to middle mouse button. And here can see we have an AV and it is an A factor, which means we are adding the velocity, and we are initializing this from compute from deformation, which means that it is calculating the velocity if we have the animation on our geometry. And right now heros can see our sphere is static, it's not moving, which means this velocity attribute should be empty. It should be zero. And I can confirm if I go into the geometry spreadsheet and into the V and heroes can see its value is zero because this geometry is not moving. I can do, I can go into the point velocity node in here and onto the initialization, I can just set this to value. Let's add this and inhere, I can use this value. We have the X, Y, and Z to initialize our velocity. I can say onto the X, I'm going to just change this to one. Now this initial velocity has been initialized, and if I were to go into the geometry spreadsheet and Heroes can see, we have the velocity onto the X axis, which means if I go into this pack onto this network, and we should see the movement and heroes can see how these particles are moving because they are inheriting the velocity from SAP from this point velocity node. Mean I can go into the noise tab in here, I can add the noise in there. You can actually visualize your velocity vector as well. And if you want to visualize your velocities, just hover over to that node and rest on this node info button, and that way we have this window pair. And in here, just click on this V button and that will add an A visualizer and here can see. We have these yellow lines, and these are the velocity vectors. And right now this noise is noising up this velocity, and if I were to disable the noise, and hears can see, we do not have noise in our velocity that's enable this. And right now we have an animated noise option enable, which means if I were to play, and Hearers can see we have some animation onto our noise. And to hide the visualization, let's click on this I button and click on this V again, and that will hide the visualization. And now, if I go into this top net, and I think I need to go to the very first frame, and let's play again and heroes can see we have or this random force, and they are using the inherited velocity, which means we are using this velocity that is coming from sobs mean I can enable the scale. And this scale is an amplitude. And if I were to increase the soil size, that will create a high frequency noise. And now, if I were to hit play, and Hears can see, we have a bigger movement in our particles. And same thing, if I were to lower down my soil size, we should see the smaller breakups and in here, hers can see we have particles going in every direction because of the smaller high frequency noise. And in here onto the top net, it is always a good idea to add an APOPtrag because this pop drag will going to be tracked down our force. Let's add this in here. And let's start with the default value of air resistance. One, so that we have some sort of resistance in the air and let's play again. And now hers can see our particles are now sticking together. Let's go into the point blasting node in here. And that is the sold size. I can adjust the pulse duration to create an animation faster. If you want to create the animation faster, you just need to lower down the duration value. If we were to lower this down to 0.1, we should have a faster animation. And I think it might be easier if I were to just visualize my velocity vectors and hit play, and here is can see, we have a very fast animation. And if I were to increase the pulse duration, and here can see we have a very slow this movement of our noise, and that is the animation. And let's go into the top net, and I think I need to just disable the velocity vectors. Let's go into the top net and inhere onto the pop source, I can control the inherit velocity scale. Right now we are using all of the velocity inherent velocity scale to one. I can increase the multiplier if I were to increase this value, and here as can see we have just increased the amplitude of our velocity, and same thing, I can just lower down by inherent velocity scale. Now hers can see we have a slower movement and same thing in here, we have some other option. We can add the velocity to the inherited velocity. I I enable this, which means we are importing the velocity from sobs we are inheriting, and we can also add some other velocity by using this pop source, which means I can add additional velocity onto the X. Let's add one inhere, and maybe let's increase this value to five and hit play and Hereos can see we are importing from sop and we are also adding this to the inherited velocity in here. In here we have the option two variance, or I can just change this to set initial velocity, which means that we are completely ignoring the velocities that are coming from sobs and we are just initializing our velocity from our Pop source node. If I were to zero this down and maybe let's zero out the variance, no variance has been added and heroes can see, even though we have the velocity, we have the point velocity node and we have the V, we are not importing inside of top in here, I can just say, please add the velocity initial veloct one and heroes can see we have some. Can introduce some variance if I want, and we have some variance velocity, and now particles are moving in every direction. Let's stop this lecture now and in the next lesson, let's explore all of these parameters and some other forces in the next lesson. 39. 39 POP Axis Force: Let's continue talking about the particle forces, and right now we are using the set initial velocity. We are initializing the velocity value in here and I'm going to just remove this point. Velocity node. I'm not going to import the velocity from sub and into the top net, let's dive inside. And in here, we have the variance, and we have the velocity onto the Y. I'm going to sorry, that is an AX parameter that's zero this out. We have variants in all of our direction, which mean our particles will going to move in every direction. And in here, maybe let's go into this sphere. Let's lower down our uniform scale value and a very low value, and let's go back and hit play. Here as you can see, we have these particles going all the way into all of the axis. Because we have the variance. I can lower down the variance value. And basically, I'm just lowering down the scale of our velocity, which means we have a lower scale value of our velocity, but we have the variance. In here, I'm going to just default all of the parameter, press and hold the control key and middle mouse button, and that's middle mouse button in hair and middle mouse button in here to default out all of the inherit velocity attribute. Let's go back, and in here, I'm going to default out the uniform scald as well. Let's go into the Dp net and in here, now let's create an app excess force, Let's said apop excess force. And let's add this. And Heirs can see when I have added the Pop excess force, we have some of the guides in the viewpoard and it will use the type. And right now, Heirs can see, we have an a shape. It is an A sphere shape, and we can change this to Taurus and if I change this, and I think it would be better if I were to just low down the height. Let's lot this height down. And Heirs can see we have this round shape. And what that will do, it will use the direction. Right now we are using the Y, and it will make this particle rotate, and it will use the fall off, and all of the particles that are inside of this shape will going to be affected by the force. And right now, heroes can see no particles are in the radius of the sphere, which means we shouldn't see any movement, and heroes can see our particles are not moving because they are not in this region. Let's go into the sphere mode, and now we have all of these particles contained in here. Now if I were to hit play and here I can see the movement, we have some little bit of movement. Right now, it is a bit harder to see. Maybe if I were to just shake this pop drag node from here and let's hit play and here is can see we have the rotation movement. Particles are rotating and they are rotating along the Y axis, and Hears can see. We have the rotation along the y axis. I can change the xs. I'm going to let's change this to X axis and zero out the Y, and Heres can see we have this guide, and this fare guide is looking weird because we have adjusted this parameter, play this and Heres can see now we are rotating our particle along the X axis. And if I were to align my camera and Heres can see, we have this rotation going on on the X axis. And I'm going to just default out to Y onto the Y axis and in here, I can place this sphere, this my domain. And in here, right now, hers can see the particle speed is too slow. And what I can do, I can go into the speed tab and in here, I can increase the orbit speed. The orbit speed is what causing these particles to rotate. And if I were to increase the orbit speed, you should see that these particles are rotating fast. And if I were to maybe let's lot this value down to one, and that is the orbit speed value and we have the lift speed. And what that will do, it will lift these particles up along the axis. Right now, we are using the Y axis, which means that our particles will going to be lifted up because of the Y axis. If I were to increase the lift speed, you will see that our particles are lifting up and same thing, if I were to change the axis, let's zero out the Y axis and enable the X axis. Now, you should see that the particles is going to be lifted along the X axis and can see. So that is the lift speed. I'm going to just change this value to zero and let's make this to one. And in here, we have the suction speed. And what that will do, it will suck those particles, all of these particles along the Y axis, at this center. All of these particles is going to be sucked back into this origin. And if I were to increase the suction speed, and here can see our particles are being sucked up, and maybe let's zero out the center and in here, if I were to adjust my this axis, and here you will see these particles are getting sucked up. And I think it would be better to add an APOptragnd and let it play, and heroes can see. Our particles are getting sucked along its axis. Right now we are choosing the Y axis. And same thing. I can go into the speed tab, I can add an A minus section, and what that will do, it will just move these particles away from its axis. If I were to add an A minus force, and now you will see that our particles will going to be moved away, and here I can see that. And I can just combine these settings. I can enable the orbit speed to make my particles rotate, and also I can adjust this suction speed and also the lift speed to control the behavior of my particle simulation. Let's maybe increase the orbital speed a bit more, and onto the shape tab, maybe let's lower down the radius value down and also the height value and let's play again. And I think now the force value is this value, we need to increase this value. So onto the orbit speed, I'm going to just increase this value. And right now because this sphere or this surface is hollow, that is why we have this weird animation, this slow mo animation, and we need to just increase the shape because you know that most of the particles are not becoming in the contact of this fall off and let's play, and now here I can see them. We have this excess force working. And it might be better if we were just using the grid inhere. Let's change the source. I'm going to change the source to a grid. Now we have a much wider surface area. Let's add this inhere, and now this force should work. We should see better result with the grid being the source and hers can see. Have these particles and they are moving upward and they are also rotating. I can same thing going into the pop axis. Right now we are using the minus section speed. I'm going to just increase this to passive value so that we have particles being sucked in onto the axis. I think I need to lower down the orbit speed. And there you go. And maybe let's increase the number of particles in here. And right now, Heirs can see whenever we are working with particles, we have this particle visualization, and what I like to do better visualize my particles, I always change the visualization of particles, and you can change this if you come over here and in here, we have this option that is the display material. And if you right click on it and we have some other option, and down here, we have the particles, and right now we are visualizing the particles as points. I can change this to pixels, and what that will do, it will just fade out the color of our particles and also scale down the particles. And right now, hers can see we are visualizing these particles as a very small points, and I think that it is a better visualization method for the particles. And I like that visualization. I always change by particle visualization to pixel, and it is also a very lightweight, and hers can see why viewport is very snappy because we are visualizing them as an A pixel value. Let me twine and hit play, and that is the pop excess force, let me go back and maybe let's change the sphere as an A input in here and let's hit play again once more. And in here, maybe let's add an APOp color node to add the colorization of our particles. And right now we are using this uniform grayish looking color. And we can add an A color to our particle by using the pop color node. Let's add an Apop color, and we have the pop color, and let's crank this in between inhere and what that will do, it will create an ACD attribute if I were to middle mouse button, and here as can see we have quite a lot of attribute and in here, we should see the CD, and here we have the CD. It is using the CD, adding this CD attribute to set the color of our particles. Let's go into the pop color node. And in here, we are using the constant, which means the simple color. I can just click on this color button and I can select any color that I like from here, and it should be get assigned. And here we have the color in the blue color. And I can change this type. Right now, we are using this simple color. I can change this to random. And what that will do, it will assign the random color to our particles, and hers can see we have the random noise random noise type color applied on particles. And in hair, we also have the option to enable the amp. Let's enable the ramp. And in here, we are using this gray scale, this gradient ramp to set the color. And right now, this ramp is using the normalized edge. Are using the NH. We have some parameters in here. Sorry, some of the attributes in here, and in here, hers can see we have the He right now it is using we also have an attribute called NH, which means the normalized age. Normalized ge means that this attribute should output the age value in zero and one range. And we are using this age value to set the color, which means at the very start, our particles will get a particle of black, and as they age, they will go through this ramp. So at the gray value, our particles will have reached half of their life, and at the very end of their life, their color will be white. I were to play and Hearers can see when they get an a white color, which means that they are about to die. And that is the method, and in here, we have some presets. If you click on this. Gee, I can let's click on it, and right now it is cutting off, but we have this black to orange, and that is an color preset. If I were to change this to black to orange and in here, we are using this pyro color type ramp to assign the color and he can see. And in here, we also have some attributes into the wax expression as well. And right now we are using the normalized edge to set the color if I were to click on this drop down menu, and Hears can see we have some other of the setting, and in here, we have the edge. I can just use simple edge. And in here, Harris can see we have very first line commented out, which means that we are using this ramp. This parameter is called the amp, and it is using the ate the age attribute. If I were to metal mouse button and here we have the age attribute, and that is the attribute that we are using to set the color. Down here, we have some other I can change this to speed, and in here, it's using the length function to calculate the speed, which means that the fast moving particle will get an color of this orange, this light orange, and the slow moving particle will get an e color value of black. Let's hit play. And here you will see all of the particles that are moving fast will get this color. I can maybe change the visualization. Let's go through some other of these ramps presets, and we have the preset of magma. Let me find. We also have the sand preset. And in here, I think maybe the color, let me find this one. Sorry, not that one. I think the simple gray scale is going to work fine for us. I'm using this default gray scale ramp, and hit play and inhere, maybe it would be better if I were to just add some other forces in here. I'm going to add an force node in between to introduce some noise. So let's add an APA force node, and let's add this. And here as can see we just keep laying down these multiple forces. For this one, I'm not going to use any of these axes. I just want to add noise in here. I'm going to just increase the amplitude value and here you will see that we have this visualization. We have the pop aces force, which is rotating these particles and we have the pop force which is adding this noise, and all these particles are sticking together. We have this clump. We have this clumpy behavior. Are not separating too much, and that is because of the pop drag. This drag force is making these particles to just not get separated too much. And in here, we have this visualization by the speed, and we are choosing the pop color nod. And in here, I can add an other node, pop limit to limit the particles. Said pop limit node. And to explain this, I'm going to just go into this pop source node, and in here, I'm going to just increase the life value to default 100 very high value. And here you will see that our particles will go on forever. They will not go on forever. They will live for 102nd, but still 102nd is longer value. And in here, what I can do, I can create an domain, and what this node will do, it will create the domain. Let's add an epoplimit node in here, and I can add this in any order. I can connect this in here or I can just connect this at the very lost. This order will not going to be met too much in this case, in this particular case, you can add this in anywhere. And in here, Heirs can see when I have added the pop limit, here I can see this blue bounding box. This blue bounding box represents the domain. And if I were to enable the pop limit, and in here, we have the option. It says that kill outside the open boundaries, which mean all of the particles that should leave these bounds will going to be get deleted. Going to just lower down the size of this domain. Let me lower this down. And if I were to just lower this down and hit play, and here you will see, and I think the force value is too low, maybe let's keep lower this down and also pop excess force, I'm going to just increase its lift speed so that our particles will move up. And Hears can see all of the particles that will go outside of these bounds will going to be cleated, and here we have this cutting off. And onto the pop limit none, and in here, we have this position behavior clamp. I can change these to bounce, and now they will bounce at these boundaries. And right now they are cutting off, which means I need to just uncheck this option and in here, let's play. And right now they are not bouncing. We need to enable this close ends option. Let's enable this. And what that will do, it will create these bounds as an collider, which means that our particle will going to be collided. And heroes can see right now, our particles are not cutting off, but they are colliding in here, and here as you can see, we are preserving all of our particles. They are not getting deleted. We are not removing them, but they are contained. They are contained inside of these domains. And same thing. I can go into this behavior. I can change this to wrap. And it will just wrap these particles and here as can see we have this some sort of repeating effect. So all of these particles that are trying to move above this axis, they are just beginning from here, and that is the rap effect. That is the wrapping, and I can just change this to clamp. It will just clamp these points onto these bounds. And that is the pop limit node, and I'm going to just remove the pop limit node from here. And in here, we also have an pop curve force. Let's add an pop curve force, and here we have it. Let's add this and let's connect this. And maybe let's talk about this pop curve force in the next lesson. 40. 40 POP Curve Force: Now let's talk about pop curve force. The pop curve force is going to utilize the curve to make these particles move and to better explain and get the better feedback from the force node. I'm going to just remove the pop excess force, just select the node tell it and in here, maybe I'm going to just remove the pop force and also Pop track I'm just keeping the pop color node, and that is responsible for setting the color. And down here, we have the pop curve force. And in here, we have the geometry source, and right now it is set to sp, which means we need to define the path of our curve, and we can pick from here to location, or I can just change this to the context. And I'm going to just change this to use the second context. Let's change this to second and let's go back. And in here, here's can see or the second context is right now empty. We have no curve onto the second and I can just create one, and in here, I'm going to use an a helix node. Let's add this. And this helix node will going to be just create some spiral, spring looking curve. And onto the helix, I can just increase the height and maybe let's lower down all of these number of turns. And for maybe better following, I'm going to just create different source, and this time, I'm going to use a circle node in here. And you can use any source you want, but I'm just using the circle to demonstrate this helix, this curve force. So let's connect this in here and right now, the orientation is in that axis. Fiber to visualize this, and I'm going to tranmplate my circle and hers can see. We have the orientation. And maybe I need to increase the height and also let's increase its radius of our curve. In here, I'm going to just move this circle to match the position. In here, I'm going to adjust the center value and in here now, I think it is aligned with my this line. Now I want my particles to follow this path, and let's go into the top net and let's dive inside, and Hears can see we have this visualizer and this visualizer is coming from Pop curve force because we are using the second context geometry, and as you know that at the second context, we have the helix. And in here, if I were to hit play, as is and Hears can see our particles are moving along. They are following the axis and right now, our animation speed is slow. Let's go into the pop for source, and maybe let's not emit that many particles. Let's lower down this perth thread, and let's play again. And now Hears can see how these particles are following this path. And right now, they are not following as much. So let's go into the pop curve force, and let's take a look at the parameter of this force node, and I'm going to just go back at the very first frame, hit rewind. And in here, first, we have the air resistance, which means that we are using this as an a uniform force because we are adding this. We are treating this as an wind force. And I can disable this and here can see how this air resistance option has been automatically disabled. Which means that we are going to make this curve force as an a force. And as you know, that force is an acceleration, which means our particles is going to be accelerated over time, and her can see the effect. And right now, they are not still following the path. And down here, we have the max influence radius. If I were to lower this down and hers can see this influence radius is controlled the radius. All of the particles that are inside of this fall of radius will going to be influenced. And I think the value of 1.2 is fine because we have all of these particles contained inside of our radius. And let's hit Play again and Haras can see these right now they are not following accurately. And let me make this window a bit bigger, and down here, we have the follow scale, and the follow scale is that what's controlling the following behavior of these particles. And right now, the follow scale is set to one, which mean we are using the force value of one, and down here, we also have the ramp, and this ram control the force, which means that at the very start, we have follow scale of one. And as the particle progresses, its force value is going to get weakened and because of this ramp. And same thing, we have the suction scale, and suction scale, as you know, we going to suck this particle along this line along its center, and we have the orbit scale, and we're going to talk about them later. First, let's enable the follow scale. Let's fix the follow scale option. And to fix this, we just need to make this force value uniform, which means I'm going to just flatten out this ramp, and I'm going to select this very last point, and let's change this value all the way up to one. So we have this nice uniform follow scale of one value along the entire of this line. If I were to hit play again and inhale Hers can see how these particles there are still leaving the area. So maybe let's go into the follow scale, and I'm going to just increase its value down to a five. I'm going to just pump up its value and Hers can see they are still leaving the area. So I'm going to just increase the max influence radius. Let's continue increasing this and let's play again. And now they are still living and which means we need to enable the suction force in here to make this particle not leave these domains. So I'm going to just lower down this value, and let's also enable the suction scale. And right now, it's suction scale is set to one, and let's go into the following ramp of these force. And Here can see we have these forces, and we have all of these corresponding these trabs and in here, we have the ramps. And here can see the section force ramp is set to like this, which means at the very start, we do not have an section. So maybe let's just flatten out this section ramp and let's hit play again. And in here, I'm going to just increase the section scale, and maybe let's make all of these values two, and let's hit play again and they're still not following, so let's maybe enable this option, treat as wind and let's play again. And here you can see because this acceleration has been disabled, now our particles are better following the path. And I think it should be enabled as an A wind. And right now in here, maybe I just need to lower down this suction scale. Let's lower this value down to one and let's play again. And here can see they are still living, which means that we need to just keep increasing this suction scale to overcome this living behavior. And we have this movement, and onto the orbit scale, maybe let's increase the orbit. And what that will do, it will make these particles spin along as they're moving, they are going to be spin. And if I were to maybe that's zoom in. And right now they are bit harder to see, but they are spinning. As they are moving, they will going to get spin with these axis. And in here, right now they are following the path very smoothly. Maybe let's introduce the noise in here by adding an A pop. Force node, maybe just add an App wind node in here. This time, I'm going to use an uniform noise. So let's add an Apop wind node in here and I'm going to just increase the amplitude value to one and let's play again and there you go. And in here, we have some of the breakups in here. And Hears can see we have this pop curve force, and it's actually not this pop curve forces actually not yielding the good result. And later we will going to be building our own pop curve force to make this curve force better. But this popc curve force has its uses. You can use this to create some sort of type of these effects. Let's go into the global forces, and in hair, we have the global forces, these ramps, and in here, I can play around with the fall off. And if I were to add maybe an point in here, and I think I need to go into the very first frame and has can see by adjusting the fall off, I can right now, it is not visualized in hair. But what that will do, it will make all of these forces to just get weakened. They are going to get weakened because of this ramp and here we have the global force. Global force is a multiplier, which means all of these individual forces, all of the follow scale, suction scale, orbit, all of these forces will going to get multiplied by this global force value. In here, we have these rams. What I can do, I can say at very start of our line, we have an A force, and as these particle progresses, I can just make the ramp to fade out, which means that we have an A force value of zero, and if I were to hit play, and heres can see, right now, I think this global force value is an A right now. Ramp is actually destroying all of the force. I'm going to just keep playing around with this RAM value and maybe let's add another.in here and let's hit play again and here is can see. We have these particles and they are following and as they are progressing and in here, as you can see this force is fading out beyond this point, we have a very weak force. Same thing if I were to just make this an uniform value, now we will have an a uniform force value. And that is the global force. And same thing, we have the force along length that is control the length of this line and we have a different ramp, maybe let's increase this value and inhere, s can see we have the visualizer also built in inhe If I were to lower this down and maybe let's bring this inhe and here into the viewpoint, here can see we have this force, this visualizer influence visualizer, and if I were to drag this down, and in here, beyond this point, we will no longer have the effect. Let's hit rewind and hit play, and right now our particles are moving slow. Maybe let's go into the individual forces and let's enable the follow scale. I'm going to just make this value to five to make these particles follow, increase their speed, or maybe I'm going to just make its length, this value to shorter and you will see that beyond this point will have no effect, and Hears can see beyond this point, our particles are they are not following that. So we have these two options. We can either control this with a long length or we can control this along this entire line. So I'm going to just default out this ramp by pressing and holding the Control key and middle mouse button, and that will just change this ramp shape to its default values. And that is an APOp curve force. 41. 41 POP Curve Incompressible Flow: Right now we are using the Pop curve force to make these particles follow along the line. And in here, we also have another node that is called the Pop curve incompressible. If you type Pop curve. And in here, we have this pop curve incompressible flow. And if I were to add this and this force node, this was designed to work with the flip simulation to control the particles behavior of our fluids, our water. But we can also use this to control this normal particle simulation as well because it is an pop node. It is designed to work with particles. So there is no reason that we cannot use this with the particles simulation. So in here, I'm going to just remove this pop curve force and I'm going to just use this first. We need to go back at the very first frame, and let's connect this in between inhere and inhere onto this pop curve incompressible flow. We need to define the geometry source, and right now it's set to stop, which means I can just pick my line location or I can just change this to second context because we have our line in the second context, and there we have it. And in here, let's play this as is. And here as can see we have particle movement, or particles are moving. And right now, Heirs can see they are following the path accurately, but right now, they're moving slow. So what I can do, I can inhere, increase the velocity scale, and to the parameter, we have the velocity. Inhere, let's increase the velocity scale. I'm going to just increase the two and some value, some higher value, and let's play again. And heroes can see. We have these particles. Now they are moving fast, and they are adhering to our curves fatter, and they are following this path a bit better, and they are also preserving their volume in here, Hears can see, these particles are moving incompressible way which means they are trying to keep these particles are trying to keep their separation. They're not getting stick together, they're not getting too close with each other. And in hair, we have the angular velocity, and what that will do, it will try to get the angle from this line. And if I were to enable the angular velocity, and let's hit play and hers can see at this, we have banking, and all these particles will follow the same banking as we have onto this line. And I think it might be better visualized if I were to just go back and inhere let's play around with the orientation of the circle. And in here, I'm going to just change its orientation. Right now, we are orienting at the XY plane. I'm going to just change this to zx plane, and right now we have this link flat onto the ground, and maybe let's play around with its center value, and I'm moving this inhere onto this axis. I'm going to adjust the Z axis as well. So we are right now far away from our line. And now let's go into the top net and Heirs can C. If I were to hit play and Hescc as they are following the line, they are also these particles are also adopting its curvature, its angle, and it might be better if I were to just increase the angular velocity scale to exaggerate the value and in here, I'm going to just lower down its following velocity scale, and I'm increasing this angular velocity. Let's play again, and hers can see because we have a very high value, and they are just getting this angle and or the simulation is getting this we are getting this organic looking particle movement, and maybe let's lower down. It's angular velocity scale because I think that value was too high, and to maybe better compensate this, I need to go into the velocity. First, we need to go back at the very first frame and let's increase the velocity scale and hit play again. And Heroes can see, we have the following animation. And in here, Heroes can see, we have this bending. And if you take a look at these particles, we have this ribbon type animation. And in here, let's maybe convert these particles into mesh. And right now, we have these particles, and to actually convert all these particles into mesh, we can say particle fluid surface. Let's add in here and we have the particle fluid surface known. Let's add this. And that node is used to mesh the particles, and that is used with the flip simulation. We simulate the flip particles, and then we will convert all of the flip particles into mesh for rendering, and that node node is used for meshing. And we'll talk about this node later. But right now just connect this into the first input and let's visualize this and that will just convert your input particles into mesh. And Harris can see if I rewind and hit play, and now our particles has been converted into mesh. And by using this node and Heirs can see, we can create these organic splashes, and we can ict our splashes, or we can create any growth system, organic growth system with this pop curve force. Dive inside the top net, and right now, it is a slow operation because this particle fluid surface needs to compute the mesh on every frame, and that's why this animation was getting slow, but that is an expected behavior. Let's go back onto the top net and dive inside and onto the pop incompressible, this nod. Let's take a look at some other parameters that we have inhale, we have the velocity along length, which means we can play around with this ramp to control the force behavior with the ramp, and we have the angular velocity and inhale, same thing. We have this ramp to control all of these forces scale along the length of our line. And onto the shaping, we have this resample. The default resample is fine and onto the treat as win, we can enable this to treat as wind right now. Or this force is acting as an acceleration force. Let's maybe enable this treat as win. Let's view. And right now, by enabling this treat as wind, it's not working. Maybe let's increase lower down the air resistance. And I think that this will work when we are using this with the flip and with this pop net, this treat ASVNd is not working and only it's working only as an F force. But that is an APOP incompressible flow node. 42. 42 POP Custom Velocity Field: Now let's see how we can create our own custom particle forces. And in here, right now, we are using this pop curve incompressible to make this particle move along this line. And in here, we have this curve force. And if I let me find this and here we have it. And both of these forces while do have their uses, they are not actually working properly. They're not actually following our line accurately. And to fix this, you can create your own hoses and to actually create them, we are going to use the volumes for that. Let's see how we can do that. First, I'm going to just remove this pop curve force and also this incompressible force. And let's go back onto the sp level. And in here, we are going to build an A volume and velocity volume, and we will going to import this velocity volume back into this dopnet and make these particles to follow this velocity volume. So let's go into the geometry level in here and in here, I'm going to just create a simple box in here. First, let's set a box at the origin, and I'm going to just make its uniform scale a bit bigger, and maybe let's go into the circle node, and let's play around with its center and maybe zero this out so that we have our circle inside of this box. And I'm going to make this size even more bigger I think that value is good. And let me view the geometry. Okay, here we have our box geometry. And now we need to convert this into volume. And you know that there are several ways we can convert this into volume. First, we can add an AVDB from polygon node. And if I were to create this and connect this, and it will create the surface or fog VDB, and it will be sparse, which means that all of these values on the inside of our box, if we zoom in into the inside, keep zooming in. And here as can see in the inside, we have this hollow, this fox geometry, which means that this VDB from polygon's node will going to be hollow as well. And we are discarding all of these values on the inside. But want to fill this box with the velocity vectors and to actually make them fill. I'm going to use an a pyrosurce node. And in here onto the pyrosurce, you know that we can fill our box with particles. So let's go into the pyrosurce and onto the mode, I'm going to say volume scatter, and it will fill our particles, fill our box with particles. And right now we are dealing with a lot more particles. I'm going to just lower down sorry, increase the particle separation to lower down the number of particles. We do not need that many particles. And now let's convert these particles into volume. And right now, we are just dealing with particles. We only have these points and to actually convert them into volume, first, we need the attribute that we are going to rasterize them. And in here, attributes are zero, we do not have any attribute. So let's add this. And in here, we can type our own name. I'm going to just pick this velocity, and it will just create an AV attribute if I were to middle mouse button, and here as can see we have the V. And its value is going to be one by one on all axis because of this default, which is fine. And now let's convert this velocity attribute into volume, and we can do that by using the volume size attributes node. Sorry, not this one, volume rasterize attribute. Let me add this and connect this in here. And in here, I'm going to just pick up my V attribute. And in here, we have this box filled with this fog type visualization, and we have this velocity volume, and its value is one by one in all axes. And what I like to do, I like to fill the velocity volume with noise. I want to create my noise of velocities, and to actually add the noise, we have a node called volume noise. Add a volume noise, and in here, we have the volume noise fog if we are dealing with floating point fog volume, or if we want to add the noise onto SDF volume, but V is a vector. It is a velocity. It has three components. So let's use the volume noise vector node. Let's add this and connect this in here. And let me bring up its parameter, and heres can see we have the same noise option in here. But by using this volume noise vector, we are adding our velocity onto volume name V. And we are using this noise to actually add an A noise in here. And I can actually visualize my velocity vectors. Right now, we are visualizing these ads and a fog and to actually visualize your velocity, fog type visualization is usually not the better option because we do not know how are these velocities actually look like. And to actually visualize the velocities, we have a node called volume trail node. Let's add a volume trail node, and it has two inputs. It needs the points to trail and the velocity volume. And we know that that is our velocity volume. Let's connect this. And now we just need the points. And for the points, I'm going to use these points. And what it will do, it will use these points, all of these points and make these points move along the velocity and create an align. And it would be better if I just show you. So let's connect this in here points to trail. And now if we visualize the volume trail node, and here is can see this volume trail node is actually trailing these points. It's moving these points along the velocities and drawing an line, which means that now we can better visualize how our velocities are look like. And into the velocity volume, I can play around with the amplitude, and here as can see I am creating an noise do velocities. And right now, I think we are dealing with more points. I'm going to just increase the particle separation to create less of these points to have faster feedback. Let's go into the volume vector, and in here, we can adjust the amplitude. I can play around with the element size. And right now the operation onto the noise is set to add, which means that we are taking the values, velocity values, which are the one in all of the axes, and we are adding the noise. And right now, these velocity vectors are not looking good because we are adding them. But what I would like to do, I would like to fill this entire volume with noise do velocities and to actually throw that onto the volume noise vector. I'm not going to just add this. I'm going to say set by using this set, we are using this noise to create the velocity volumes, and in here, now I can play around with the element size, and now we are just completely discarding these values one, and we are using this volume noise vector to add velocities. And in here, I have different types of noises. I can change this to alligator noise, and I can maybe let's change this to parlan noise. And let's change this to fast noise. And we have all of these different types of noises. And let's go into the volume trail node, and in here, we can adjust the visualization. I can play around with the trailing length to control the length of these points trails, and it is just for the visualization purpose. It will visualize these velocity volumes. And now that we have this V, we have these velocities. And here as can see right now we are visualizing this as an fog and it is not a good visualization because we do not know how these velocities are actually look like, and that is why we need the volume trail load. And now let's input these custom velocities that we have just created into dubs. And I'm going to connect this into this third input. Now let's go into the top net node and in here to actually import these custom forces, we have a node called Pop at B volume. Let's set Pop at act. And here we have the Pop at by volume because we want to use our volume velocities. So let's set this and connect this in between. And in here, right now, we have the velocity source. It says swap, which means I can choose the location, or I can just say, please use the third context. And in here, it is looking for an volume that is named Val. But if we go back and inhere, as you can see, we have an A VDB, vector VDB. Sorry, it's saying density, we need to refresh this, and here as can see we have this one VDB volume its name is set to V. It is a vector, which means we need to go into the our Mx, and in here, we need to change this name. And in here, I'm going to just type V, which means that V is the velocity volume that I want to import. And if I were to hit play, and heroes can see we have these particles moving, and I'm going to remove this wind node to actually make my point that we are completely using the velocities that are actually coming from our sobs and hears can see. If I were to view this volume trail node or maybe less tramplt or these volume trails, and there you will see that our particles will follow the path of the nos path, and hares can see. And that way, you can create your own custom forces. Now, let's see how we can use the pop at by volume to make our particles follow the path of this line that we have created in here. And let's see how we can convert this line into volume and import this in here to make these particles follow the path. And we will do that in the next lesson. 43. 43 Custom Curve Force: Now let's see how we can make these particles follow the line. And right now we are using these noised velocity volumes to make this noised up particle movement. So let's go back into the sob and in here, let's build a volume for this line. And right now, we have it just simple box filled with some nos stuff velacties. And I'm going to just slap all of these node and move them aside. And in here, maybe I'm onto the helix node. Let's keep this onto the third input onto the helix I'm going to convert this into an A velocity volumes, and we can do so by first building our own velocity vectors. And right now, if I were to middle mouse button, and here as can see, we do not have an A vector attribute in here, and we only have an AP. And what I can do if I go into my helix node and if you scroll down, we have some output attributes. Let's collapse this menu. Let's scroll down. And in here, we have the transient Z axis. If I were to enable this, and it will create attribute and mean the normals. And if I were to middle mouse button, and here as can see we have the N, it is an A vector. And this tangent Z axis will going to be store the vector that will follow the path of this line, and I can visualize this N if I go into these display normals. You know that we can display our normals by clicking on this button, this will display our point normals. And right now we have the normals because N is A. Normal attribute. So let's enable this and inhere, if I zoom in. And here you will see we have these vectors, and maybe if I were just change my camera angle and inhere, you will see that we have these vectors, and they are storing they are following our line. So we have some vector information. We have the direction information. And now we just need to convert this direction into volume. And in here, first, I'm going to add an thickness to my line because right now we have this infinitely thin line. And to add the thickness, I'm going to use polywire node. So if you type polywire let's add this and connect this in between and what it will do, it will just make this line into an cylindrical shape. It will add the thickness in here and I'm going to go into the plywre and we have some parameter. Let's increase the wire radius, and that will increase this radius, and right now we are using this a square, this four sided, I can change the divisions if I come over here, Hees can see we have the divisions. And if you continue increasing this division, I can make these thickness and a smoother cylindrical shape. So maybe let's increase some of the division's value to have this smooth looking shape. And we also have some Us if I zoom in, and here as you can see we have some UEs. And we have this weird visualization of our viewpoint, and hers can see. And this weird visualization is actually coming from this normal. And as you know, we have the normals. We have these normals vector. And if the normals are present onto our line, this polywre will going to inherit these normals to set the normals, and hers can see we have these normals visualized. And because of the weird angle of these normals, we have these shading problems. And if I were to recompute my normal, let's add a normal nod, and that way we can recompute the normals and let's view this again. And now, if let me hide this, and here us can see or this geometry has been converted or this line has been converted into this thick geometry accurately, and we do not have any problems. And because we are fixing the normals, but we do not need to fix the normals because I like the normal. I'm using this to just add an thickness. And now that we have the thickness, I can convert the V attribute into volume. And to actually convert this, we have a node called volume rasterize attribute. So let's add a volume rasterize attributes. Add this and connect this in between, and in here, I'm going to select the attribute that I want to convert and the attribute is called the N. And now we are creating the N vector volume. And if I were to middle mouse button and it's still saying let's press and hold middle mouse again. And now we have this one VDB volume, it's N and it is an A vector. And I know that that is the direction I want my particles to move. Now let's import this velocty volume into our particle simulation. Let's go into the top net. Let's dive inside, and this time, let's go into the pop at by volume. Right now we are using the third context. We are using this box, but let's import this second context geometry. So let's go into the top net non, pop Vt, and in here, let's change this to second context. And now, if I hit play, and these particles are not moving, let me see if I were to tramplate my poly wire, and hers can see our particles are not moving because we are not in the proximity of this line. And that's just this emitter. And to actually make this work, we must be inside of this proximity. Otherwise, it won't follow because outside of these region, we do not have velocity information. If velocity information is not there, or particles will not move. Let's play around with the center, and maybe let's play around with the orientation. Let's change this to X plane, and also let's move them in here, adjust this. I'm going to make its uniform scale so that we have this source inside. Maybe let's keep adjusting its position. And right now our source is a little bit outside. But that is fine. That is good. Now, if I were to dive inside and hit play, and it is still not moving, and that is not moving because we forgot to actually rename the volume name because right now we are using the V. But if we go back in here, as you can see, our Velocity volume has been renamed to N. So which means I need to go into the top net and inherit, update the name. I can say that now that I want to import the N because that is the volume that stored the velocities, so N. Let's add this. And now we should see and hers can see we have these particles moving, and they should follow the path of our line. And right now we are using the advection type. We are making this to update as an A force. And we are using it as a wind force because treat as wind option is enabled. I can disable this and now we can update this as an A force, and force is a bit more brutal force if I were to hit play. And here can see over time our particles are getting accelerated. I can go into the velocity scale. I can increase the velocity scale, and now our particle will follow them a bit faster and in here, let me go back onto the pop Advec. We have some other advection method. We can change this to update velocities, which means we are going to be updating our own these particle velocities with these velocity volumes. So maybe let's change this to update velocity, and let's hit play, and now here can see by changing this to update velocity, our particles are adhering to this line pattern. And after that, maybe let's add an apoptrag because pop drag always help. Let's add an Apop drag node in here and add this after the pop advect and let's hit play. Here you will see that these particle will guarantee to follow the path that we have just built right now it's speed slow. Let's go into the Pop EDV and maybe let's increase the update scale and in here, now we have a faster movement and they are following the path. And in here, I can add noise on top because right now we have a very smooth movement. So what I can do, I can use the pop wind node in here and let me check and here we have some noise. Let's hit play. And here you will see that we have some noise introduced. And I'm going to let's increase the amplitude to add a bit more breakups. And here we have the noise, and now this movement is looking good. And right now the visualization is a bit weird. So let's go into the pop color node. And in here, we are using the range. Right now, we are using the range in zero to one range. And because we have a faster movement of particles and if I go into the pop at by volume, and here you can see we are using the velocity scale of 5.9. So as you know that this velocity are not in zero to one range, but we have higher values. So let's go into the pop color, and let's adjust the range accordingly. I'm going to just press and hold the middle mouse button and just keep increasing this range. And here you will see that the color is adjusting, and I'm going to maybe let's change this to a value of 5.9. And we have this visualization back, and now we have this accurate this good visualization. And we have some noise. And let's go into the pop at wec and here as can see we have this velocity blend option. It means that we are blending the velocity from this top net. We have this pop in. So we are using 0.5 as an A blending amount. Can change this to one, which means we are fully blending both of our velocity volumes. We are going to be utilizing the pop atact and pop wind fully. And if I were to hit play, and here as you can see, both of these forces will have an equal effect, and we are following this path better. Let's go back and in here, I can introduce the noise onto these velocity volumes, and right now we are using the pop wind node to add an A noise. What I can do, I can add an A noise onto these vectors because right now we have this very smooth information. And I can actually visualize this by creating my own this trill node. And first, we need the points. And for that, I'm going to fill this polywre geometry with points because right now it is hollow piece of polygonal geometry. And to make this fill, I'm going to add points from volume node that will just fill our polygonal geometry with points. Let's add this and view this and here can see. We have these particles inside. Now let's add volume trail node, in here, volume trail node, and it needs the velocity volume, that is the velocity volume and the points to trail. And we have these points. Let's view this. Sorry, let me connect this again and view this in here. And here you will see these are the velocity volume visualized in red, and in here, let's introduce some noise, and I can do so by adding an A noise node, so let's add volume noise vector. And let's connect this after we have converted this into volume. And right now it is using the vector volume name, V, but inhere, as you know, that we have the attribute and it is set to N. So what I can do maybe to fix this, let's go into the helix and inhere. Let's not export this as NAN. Maybe let's change this to V. In here, we should have an A attribute name V. So which means that this polywire node will inherit an V attribute, and here can see we have the V, and we have this proper visualization of normals because we are not creating the normals and polywire will creating the normals itself, and we have this good visualization. Let's go into the volume rasterize, and inhere, let's not pick the N because N no longer exist, but we have the V. And now we have this velocity volume name V, and that is good. Now let's go into the volume trail node and all of these nodes, as you know, they are designed to work with by T fall. Let me remove this P. Let's go into the volume trail node and in here. Now here as can see we have the noise introduced in here. Because we are adding the noise on top of these velocity vectors. If I were to zero out the amplitude, and heroes can see we do not have any noise. And if I were to start adding the amplitude, hers can see we are distorting these velocities with the noise. And I can play around with the element size to create a more high frequency or low frequency noise. And if I were to load this value down, and here as you can see, I'm adding lot more smaller breakups. We have these smaller swirls. And same thing. If I were to increase the element size, we have these bigger soles. So let's change this to an A maybe value of 0.7. And now I want to connect this into the second input because that is our new velocities. Let's go into the top net. And in here, we need to update this pop at work by volume. And now let's change this back to V because we have created the V. Let's hit play. And here as you can see, we have the noised up movement, and I can confirm. Let's go into the pop in and just shake this note off. So which means that we only have pop at by volume node. And let's play. And here you will see we have the noised of velasties. And in here, as you can see, we have these particles. Some of the particles are sticking. We have this sticking effect. And that is because all of the particles that will try to leave the bounds if I were to visualize this poly wire, and heres can see we have these bounds. Let me enable my particles and let me tramplate my this plywire and if I were to hit play, and hers can see, all of these that will try to leave the bounds will going to be stick because it's outside of these bounds, we do not have velocities information. And to actually fix this, what I can do I can just remove the particles that will try to leave these bounds, this bounding box geometry. And I can do so by maybe let's remove this volume trail load because that is for the visualization or maybe let's just keep them in here and place it inside onto the side. And let's go into the Dp net. In here, I can add an Apop collision node. So let's add an Pop collision, and in here, I'm going to say Pop collision detect. So let's add this and connect this in between somewhere. And in here, we can define the sap path that will look for the collision. Or I can just connect this into this lost input, and here can see how this node graph is getting very messy. And by the way, you can change your wiring style if you press Shift SK, and that will change your wiring style to smoother looking wires. And in here, I can just pick this polywire node. So let's go into the top net and onto the pop collision, I can change this tone to this contest, or I can just go and pick my own this polywire let me find we are in the geometry, and we should see the polywire and here we have it and it accept. And here we are visualizing this as we have the guides. We are visualizing this, which means that we are importing it. Now onto the behavior tab, right now we are coloring our particles, which means all of the particles that will try to leave will get an a color value of red. And right now this red color is going to be overwritten by this color node. That is why we cannot see the red color. So I'm going to just shake this color node. And now if I were to hit play, and here you will see that all of the particles that will leave the pounds will get an red color. So what I can do I can go into the pop at by volume. Sorry, into the pop collision. In here, right now, response is set to none. So I can say, make all of these particles die. So which means that all of the particles that will try to leave the bounds will going to get deleted. And if I were to hit play, and here you will see particles will live only inside of the bounds. And right now it is actually not following correctly. So we need to go into the pop at and play around with the parameter. And in here, right now, we have the advection method. We are using the single step. Maybe let's change these two trace and trace will create a good looking result. So whenever you are working with volume, make sure to change these two trace, and it will trace these velocities better. And in here, I can play around with the update velocity scale. So maybe let's lower this value down and let's go back and inhale all of these actually coming from this volume noise. So maybe let's lower down the amplitude to not create that much of the noised up. And now here you'll see that these particles are falling the line. And if they try to leave, they will get deleted. So in here, you can use the pop wind node. I'm going to add pop wind to add the noise. Let's tree wine and hit play. And here you will see that we have some noise introduced in here. Maybe let's go into the pop collision detect and let's uncheck this guide to hide the guide. And let's go on to the pop color. Let's add pop color node in here so that we have our visualization back. And in here, I'm going to adjust the range. Let's play around with it. Range value, lower this down, and we have all this good visualization. And let's go back and inhere, let's view this with this particle fluid surface. And here can see we are creating this splash. We are directing this splash like effect, and you actually do not need to add this. We have these particles. They are following the line. So that's how you can create your own custom forces with the volume. 44. 44 Particles Advection: Now let's see how we can use the smoke simulation or pyro simulation to make the particle drive the animation or to drive this particle simulation. And you know that if we go back in here, if we were to create an A velocity volumes and in here, hers can see we are working with these volumes. We are building these volume velocities, and we're importing them inside of the Dp net to make these particles move. So in here, I can build an A pyro simulation or smoke simulation, and pyro and smoke simulation, they will to have an A velocity volume, which means we can import the velocity volume in here, and that way, we can drive these particle simulation with the smoke simulation. So let's go back and in here, I'm going to just remove all of these noises, all of these nodes that we had just created. Let me remove this visualization. And in here, first, let's see that before that, we were using this helix node and onto the helix. And here you can see we have this option to export the trangent. And in here, let's say, if you want to create your own line, let's say I'm going to add enter my own curve. So in here, I'm going to type curve node. So let's set this and view this. And when the node is selected, hover over to the viewpoint and press Enter. And that way we have this curve tool manipulator. And in here, I can just start drying my own line. And right now we are using this as an A polyline, and I can confirm if I bring up the parameter, and here can see we have the primitive set to polygon. So in here, I'm going to just undo all of my operation, and in here, I'm going to just draw an APC curve, which means I can just press and hold and that we have this BC handle to make the line smooth. And in here, I'm going to just my own random curve and press Enter to complete your operation. In here, let's say we have this hand drawn curve, and this curve, if you might have imported from other software, and you want to create attribute. And because of the curve, I think we have the output attribute, and in here, we have this option to enable the Z axis, and we are creating this tangent attribute. If I were to middle mouse button, we have this tangent. For visualization, I'm going to just change this to N, which means that I'm creating the normals and if I were to middle mouse button, and here you will see we have these normals, but because of the weird points, let me make this height and enable the points. And here you can see, because of the basic curve, we have these weird points, and that is why we have this weird visualization. And to fix this, I can add an A resample node and resample node will going to resample our line. So let's go into the resample and here as you can see we are resampling this line into an even distribution of points. And I can adjust this by changing the length to create more or less. And in here, you will see that we are adjusting the length. So in here, if I were to enable the point normals, and here you will see that this is actually inheriting these normals because we have onto this output curve. But if you do not have this option, let's say that you have imported this line from other software. And so you can create this in here. You can either add an A resample node, and here can C, we are resampling the line. And onto the resample we have this attribute to export. So let's enable the tangent attribute, and here can see, we are exporting this as an A tangent U. I can make this to an A N and if I visualize, and here you will see that we have these normals back, and I can change this to V and same thing, convert all of these into volume and import them in here. Or we also have an node called orientation along curve. So if you add an orientation along curve, and let's add this and we actually do need to resample this because you know that we are using this Bs curve and so we have these weird points. So let's add resample, and we are just resampling the points. I'm not adding any attribute if I were to middle mouse button and here's see we do not have any attribute. So let's add this and onto the orientation along curve, we have the option to output the attributes. And same thing in here, we have the tangents. So right now we are exporting our tangents as an A N, which means I can visualize my point normal, and here you will see if I zoom in, and we have the normal or these normal vector. So there are a lot of ways that you can export your tangent attribute, and I'm going to just remove this node graph in here and maybe let's remove all of these node graph from there as well. And now let's build our very basic pyro simulation. And for this one, maybe I'm not going to use the circle node. Let's also delete the particle fluid surface. We have this basic sphere. So let's connect this in here and we have the top net is throwing an error. Let's dive inside. Let's see. We have this pop collision. It's actually referencing to this polywire that we do not have. So let's remove the pop collision. We do not need that, and all of the errors are gone, and these particles have some movement. Let's go into the fare, and let's build a very basic pyro simulation. And I'm going to create an a source node first to convert to create an a source. Let's connect this in between. And in here, I'm going to say volume scatter and onto the initialize, let's initialize this to source mode, and it will create these two attribute. And now we need to convert this into volume. So let's add an A volume rests, attributes node, and connect this. And let's rasturize our density and temperature, sorry, not the P scale, but the temperature attribute. And down here, we just need to create an solver no pyroslver connect this in here and let's hit play. And here we have the basic pyro solver. Let's go into the pyroslver and let's go into the fields tab, solium into the shape tab, let's introduce some of the noises. I'm going to add an turbulence noise, and let's collapse this and let's hit play. I'm going to adjust this amplitude of this scale. And heroes can see right now, we do not have much of effect, let's add an eight turbulence noise to the density field, right now, we are adding the turbulence to the temperature, and it will get an effect if I were to continue increasing this because we have the temperature volume, Heros can see, which mean we need to just increase this value and we should start to see some noise and here we have it. And let's say that that is the simulation that I like. And you know that if we go onto the output tab, here we have the Val. We have the velocity volume. And if I were to middle mouse button, and here is you can see, we have the six grid volume, we have the velocity X, Y, and Z. Right now, they are hootin volume, so let's convert them into VDB, and maybe also enable the 16 bit floor. And now if I were to middle mouse button, now we have an A vector volume al let's use the velocity volume. All of these velocities that you know that these velocities are moving out this smoke. We can also use this velocity to move our particle as well. So after the pyro solver, I'm going to just connect the pyro solver into the second input of the top net. Let's go into the top net and dive inside onto the pop at. We have the second context, and right now we are looking for the field volume n V. But you know that the dub will export as an A val. If I were to middle mouse button, it says. So which means we need to go back and rename this pop ad back to the well so that it will looking for the appropriate volume. And now, if I were to hit play, and here you will see that these particles are following the path of horse smoke. And in here, I can play around with my velocity scale. Let's lower this value down, and in here, let's shake off this pop wind node. Maybe I can just completely delete this node. And that way we will have all of these noised up information from this smoke simulation, and Hears can see. I can tramplate these particles, and here you will see that all of the particle movement, all of the particle forces are being controlled without this pyro simulation, which means I can just continue massaging my spyroslver Inhe I can, let's say, adjust this scale of the turbulence to create a very chaotic movement. Let's it play, and heres can see we have very chaotic movement. And now if I were to visualize my top net of the particles, and here you will see we have the same behavior in here because now we are controlling our movement from the spyroslver. Let's maybe lower this value down. I think this value is too high, so let's lower this down and inhere, let's adjust the sole size. By increasing the sol size, I can create these bigger soles, and here you will see that we have this bigger movement and same thing. I can lower down the salt size, and that we will create high frequency noise. So we have some smaller breakups, and I can view my smoke simulation, and here we have the smoke and this top net will have same effect. So that's how you can use your own create your own custom forces and make your particle simulation drive with your own forces. And right now we are actually live using live this Pyro solver. And in here, what you can do if you are going to create an A, you are going to use the Pyro solver first, you might need to add an file cache node to write out your caches. So it's a good idea to add an a file cache node, and after that, you just need to write out your ash, and in here, let's go into the pyroslver. If you are going to drive your particle simulation from the pyro solver, we are actually going to need the velocity volume. This well. All of these volumes, here can see, we have the four VDB volumes, we do not need them. We have the density volume, we have flame volume, we do not need them, so we only need the velocity. So what I can do, I can go into the pyro solver and onto the output, and I can just disable all of these. I do not want to export. So in here, I'm only exporting the velocity, and right now here, I cannot see the velocity volume because it's set to invisible. I can actually make visualize by the smoke, and right now, I can only see the bounding box, but I cannot see this as an A. G, but that's fine. Velocity volumes are there. You can keep this at invisible. And if you middle mouse button and Harris can see, we have the velocity information. And if you go onto the top net, and here you will see that we have the same behavior because velocity volume is the only volume that we are interested if you are going to drive your particle simulation. And maybe you want to export the density volume four as an A visualization as an A guide. And here you can see we are visualizing this our smoke if you want to export this, but you are not needed to export this density because we are not using this field anyway. It's up to you if you want to export both of these fields onto your hard drive. So after that, lay down file cache node and write down your caches, and then you can just use the file cache node to reference this top net or this particle net, and that will create all of these velocity volumes accurately. So that's how you can use the smoke simulation to drive your particles. 45. 45 Rendering Particles: Now let's take a look at particle rendering, how we can render our particle simulation. So first, I'm going to create a very basic particle simulation. So in here, I'm going to create an A geometry node, and in here, I'm going to add an a spare node, and this sphere will going to act as an a emitter. And now let's add an a pop network in here. I'm going to just connect into this pop net first input and let's dive inside. And in here, I'm going to just go into this pop source node, and let's increase the number of particles to emit more particles. And now, if I were to hit play and here is CC we have these particles accumulated. Let me enable my play bar. And in here, let's also enable this real time option so that we have this real time playback. To make this particle move, let's add an A wind force in here. I'm going to add my wind node, and let's connect this in here and I'm going to just add an A noise. So onto the amplitude, I'm going to just increase its value all the way up to one, and now we should see the wind and here we have it. And right now, I think the sole size is too low. It is fine, but I'm going to just increase the sole size. Let's increase the sole size to create these bigger soles if I were to hit play, and here you can see, we have these bigger souls, these bigger shapes. And after that, I'm going to add another wind node. So let's add another wind and connect this in between. And for this one, I'm going to just keep the soil size to one and let's increase the amplitude, and let's hit play. And we are adding multiple layer of noises that will create a more interesting looking shapes in our particles and in here for visualization, let's also add our pop color node, and in here, let's add this. And I'm going to connect this in between and I'm going to use the ramp and in here, I'm going to click on this. This our wax expression, and I'm going to use the speed ramp and to use the speed to set our color for the particles. And right now we are using this gray scale ramp. What I can do, I can just click on this knob and I can adjust the color. Going to choose a very light yellow color. And for the first knob, let's keep it at black for now. And here we have the very nice color visualized. And right now, our particles life is too high, so let's go into the pop source node, and I'm going to just lower down this life value. Let's lower this value down to one. Let's hit remind, and let's hit play again, and here can see. We have particles and they are dying at the same time. So maybe let's add a variance. So let's change the variance to one, and now we should have the random life of all of these particles. And there you go. Here we have the random life, and I cannot see the smaller scale noise. So let's go into the pop wind. And for this one, I'm going to just increase its amplitude value to something higher value until I see some breakups. And I think now it's just breaking up a lot. So I'm going to just keep this to 1.5 and let it play. I think that value is looking fine. And now, let's say that we are happy with this or simulation. Let's import this into Solaris for rendering. Let's go back. And in here, you can now add an A file cache node because let me add an a file cache, and you can connect this and you can write out your particle simulation onto hard drive because you might be working with millions and millions of particles, and it is a good idea to write out your simulation before rendering. But if I were to middle mouse button, and here as can see we are not working with a lot of particles, so I'm not going to write out my simulation. I'm going to just create an null at the end for referencing. So let's add this, and I'm going to rename these two out. And in here, I'm going to create an lop net. So let's create an A lop network, and let's dive inside. And in here, let's import our particles. So for importing, let's add an ASAP Import node, and I'm going to pick up the sub path. Let's click on this and let's let out this out null. And here we have our particles. And now we need to assign the materials because right now this color has been visualized because we have the CD attribute. But because we are in the lob and we are going to render the particles, we must need to create the material. So in here, let's add a material library node, and I'm going to connect this after that and let's dive inside. And in here, I'm going to go into the kerma and let's add an Akerma material builder, and let's dive inside to have access to the actual material. And here we have the standard surface. And if we were to enable its parameter here, I can define the color of my particles. Let's go back and let's go into the material library and click on this auto film to fill out these slots. And now we just need to assign this. I'm going to just enable this assigned to geometry option, and let's track this in here. And with that, our material has been assigned. And now let's add an kerma render node. Let's add this and let's connect this in here and let's view this. Onto the Kerma render setting, I'm going to use the XPU render engine, so onto the engine, let's change this to XPU. And now to actually render this, let's go into this and click on Perspective and change this to Kerma XPU. And with that, we are rendering our particles, and Heirs can see our particles are looking white because this CD attribute, if I were to change this to Houdini Vk or this CD attribute is not being used inside of our material. I know that the CD attribute is hair because I can see the color inside of lobs, but the material itself is not using this CD to set the color. If I were to dive inside and let's go into the material itself, and heres can see this standard surface material is just using its own color. So which means we can just pick any color that we like. I can change this to let's say blue. And now if I were to change this to Kerma XPU and heres can see this material is using its color to set the color to actually import our CD attribute this color inside of this material. We can import this by adding an Geometry color node. So if you type Geometry color, and here we have this node, material X geometry color. Let's add this and this node will import the CD attribute from sobs into this wax builder into this material context. And it is out a vector, and here is can see if I hover over to this out, and here we have the out and it is an A vector type, which means I can connect this in here and if I zoom in onto this material itself, and here we have some collapsible menus and we know that we want to set our base color, that is the base, which means we need to collapse the space, and here we have some other parameter, the first base, and that is referring to its value. I'm going to just change the color. Here you can see the base color, it is an a vector. So let's connect this in here. And now this material is using the CD to set the color, which means if I were to render this, we should see this color applied, and there you go. Here we have the color imported from our sobs into this material. And now I can go into the specular. I can play around with the specular value. And right now it has no effect. It has effect, but I cannot see them, and that is because we need to create an lighting in here. So let's go into the lop net and in here, I'm going to create dome light to add simple HDRI light. So let's add dome light and connect this in between. And in here, right now, this dom light is using this basic solid white color. But I can define my DRI in here. So let's pick our HDRI. And I'm going to pick this tall or sign Houdini, pick HDRI. These are the HDRI default. Let's pick this kilodGarage and hit Accept and here we have the HDRI. Now if I were to change this to Kerma XPU and here can see we have the shadow information and we have the lighting information. And in here, let maybe adjust this background and to adjust this, let's click on this eye button. And let's go into the background tab, and in here, I'm going to uncheck this display environmental ys background. I don't want to see the HDRI in my background, and let's also change the color scheme to dark gray. And there you go. Here we have our viewpod visualization. And by the way, it's not the visualization. We are rendering our particles. That is how our render looks like. And here as you can see, we are also setting our P scale in here. We have some scaling information. And if we let me change this to Houdini Vk, and let's go back and in here, if you middle mouse button, and here as you can see we have quite a lot of attribute, but in here, we do not have P scale. And if you go through, here you will see that we do not have P scale to set the scaling. So if I go into the lob net, and if the input geometry, if you input, right now, these particles are also our geometry. So if the input mesh or geometry does not have an AP scale attribute, this sbiport node will set the P scale attribute for us. And we can find this if we go into the geometry handling of the sue sub input node itself. Let's collapse this geometry handling, and here we see this parameter that says set missing width. Says set missing width, but if you hover over to that, here you will see that it says that if the input mesh do not have an width or P scale attribute, we are going to assign an AP scale value by using this parameter. And right now we are using the P scale value of 0.01, which means if I were to change this to kerma PU to render or particles, and if I were to increase this value, and here can see our particle scale has been increased, and same thing, I can just lower this value down and I am lowering down my particle scale. And I can explicitly say, let's go into the geometry node. I can set my P scale attribute in here. And as you know, we can create this by creating an attribute create node. Let's set an attribute create, and let's connect this in between, and in here, I want to create an AP scale attribute. So let's type the attribute name and onto the value. Going to give a value of 0.1. And now, if we dive inside, and now because we have the P scale attribute, we will be going to be using our 0.1 value, which means now this parameter will have no effect. And here you can see if I were to adjust these settings, this parameter now has no effect. That is because our P scale attribute has been present, and now this solaris is using P scale attribute from sobs to set the scaling. And this set missing width is there if we do not have the P scale attribute. And let's go into the first, let me stop the rendering by changing this to Houdini. Volcan we put? Let's go back. And right now we are creating an uniform P scale value. We are creating this 0.1 value to set the scaling for all of our particles. Let's customize that. And I want to set the P scale based on the age of our particles. And we can create this by creating an A attribute Vbn, so I can go in here. And create an A attribute b node. And let me remove this attribute, create, and let's connect this. And in here, let's dive inside. And as you know, that we have the edge if I middle mouse button, and here you see, we have the edge. We have the edge information of our particles. Let's use this edge to set the scale of our particles. So let's go into the attribute b and in here, first, I'm going to import the age attribute, and we can import this by adding the pine node, and in here, we need to just type the attribute name that we want to import. I want to import the edge. And now I can just export this as an AP scale. Let's add bin export node, and I want to create an AP scale attribute. And now I can just connect this in here, which means that we are using the edge to set the P scale. So whatever the edge is, we will get the P scale value. But that will not create a good looking P scale. If I go into my lob net, and if I were to render this with Kerma XP, and here you see we have this scaling. We have this quite a lot of particle big scale. And to adjust this, let's go back. And in here, as you know, we are using the pop source or this life is set to one, which means that we will have a value of H value in zero and one range. If I go into my pop net and let's say, can select any node, you can select null or this top net, and you can go into the geometry spreadsheet and Heres can see if you have the top net selected. Dynamics has a different type of geometry spreadsheet, which means I just need to select out this sp node, and now we are in the p and the hop context has this geometry spreadsheet like this. And in here, if I were to check, and here you can see our age is now set to 1.9, and that is because we also have an A variance, which means some of the particles will get an a scale of one and some of them will get an age value of 1.9. We know that the age, so let's remap these values. So let's go into the attribute Wop node. And to remap this, let's add an fit range node in here. Fit range, and let's connect this. And onto the fit range, I note that the minimum value is zero and the maximum value is two. And that is because we have an A variance of one, which means that we will get an A max value of H value to two. And now we are remapping this to zero and one range. Which means that when our particles will get borne, they will get an scale of zero. And they have as they get older, their scale will also grow, and we are growing it at the value of one. And right now, the value of one is still too high, so maybe let's lower this value down to 0.1. So now we are remapping these values. Let's go back into the lop net and let's render this again. And heroes can see if I go at the very start value, and heroes can see at the very start, we do not have an scale as the particles bond, and as they age, their scale will get bigger and bigger. And I think the value of 0.1 is still too high. So maybe let's go back into the attribute b and in here, let's lower this value down to 0.01 maybe. And we can also promote this parameter. So onto the destination Min and Max, I'm going to just middle mouse button and let's promote this parameter so that we can just adjust this parameter onto this attribute wb node and from here. Let's go into the lop net. Let's change this to Kerma XPU, and let's see. And I think that scale is much more manageable. And I can reverse the scale. For example, I can say as the particle get older, as they are about to die, their scale should get thin and thin. So let's go back. And in here, let's reverse these values. So at the start, they will get a value of 0.01 as they bone, and as they are about to die, their scale should be reaches to zero, which means that at the start, we should see some scale, and as they are about to die before they are about to die, their scale will get thinner into nothing. And that way, we can create this fading effect. And here as you can see, at the start, we have scale, and as they age, their scale will also get thin. And that's how you can create your P scale to control the scaling of your particles. And let me go back. And in here, we are creating the attribute Wab node to create the fit range node. And in here, we also have a node called remap attribute. So if I type attribute, remap and here we have it, and this node is actually pre built to do all of these same thing, which means I can just delete this attribute wb or maybe I can just place this in here, connect this and connect this into there, and I'm going to just place this at the side into the attribute remap. We have all of the same functionality built in, and that way we can just remap our values very quickly, but just by using this attribute remap node, and in here, we need to define the name and the original name, I'm going to use the edge because I want to remap our P scale by the edge and onto the new name, I can create a new attribute, and the new attribute that I want to create is the P scale. Let's type the attribute name. Now we are creating the P scale based on the age, and in here, we have the min and max, and we know that our minimum is zero and max is the true. And now I can just remap them, and in here, I can just say the same thing that at the start, we have the scale of 0.01, and as our particles get older, their scale should reach to zero. Now we have additional option to play around with the RAM. That is an additional functionality also built in, which means I can just adjust and play around with this RAM value to further refine my P scale. Let's go into the lop Nt and let's render this again. And here can see if we have the same effect. But now we also have some additional functionality. Let me pin this viewport. This rendering, let's go back. And onto the attribute remap, I can just play around with this ramp to further refine my scaling. And that's how you can very quickly remap your values and you can set your P scale. And let me change this to FodeniVK and to set the color, let's time inside the pop net. And onto the pop color, I can just add another knob, and in here, you can just create customize your own colors like SO. And they should let's go into the Kerma XPU and Heres can see our changes has been reflected. I can change some other preset. Let's change this to infrared and Heres can see we have these colors, and that is the basics of how you can render your particles. 46. 46 POP Grains Introduction: Let's talk about pop grains. We use pop grains for creating sand simulation or snow simulation. So let's see how we can set up the Pop grain simulation. And in here, first, I'm going to create an A Geometry node. As always, let's dive inside, and in here, I'm going to add an A sphere. And you know that we need the source. For emitting the sand or the snow, we must have an A source. So I'm going to use an a simple sphere. And right now, here can see we have this sphere, and it has this regular arrangement of these primitives, and I can go into the sphere. And in here, we have the primitive type. Let's change these two polygons, and it will just triangulate our mesh. And here as you can see, I can see some nice triangles, and I can increase the number of triangles by increasing the frequency. Let's keep increasing this and let's add more of these triangles into our sphere. And I'm using this triangulated mesh because I'm going to displace this sphere with the noise, and having the good triangulated mesh will create a nice looking transformation. And after that, let's add noise onto our geometry. I'm going to use this mountain node. So let's add this and let's connect this and let's view this. And it will just add noise displacement onto our sphere geometry. And let's go into the mountain node. Let me make this parameter window a bit bigger. And in here, same thing, we have the noise. I can play around with the amplitude to adjust the amplitude of our noise, and I can increase the element size to create an high frequency or low frequency noise. And in here, we have some of the noise. I'm going to let's change this to worldly cellular, and right now this noise is not looking good. So let's go into the range value. Right now, they are using the zero centered. Let's change this too. Positive. And if I zoom out and here can see we have an rock looking like deformation. Now our sphere looks like as we have the rock, and in here, we can play around with this element size, and we can increase the amplitude. And I'm just keeping the value, and I think this deformation is looking good. And now to create an grainm granular simulation, we have an node called grain source. So in here, if you type grain, here we have the grain source node. Let's add this and connect this and let's view the grain source. What this grand source node will do, it will just scatter a bunch of points onto the inside, and heres can see we have some points and this grain source node is also adding some attribute if I were to middle mouse button, and here can see we have an AP scale attribute. Let's go into the grain source, and in here, I can play around with the point separation to create more or less of our particles. And same thing if you were to low down the separation value, let's say, I'm going to lot this down to 0.05, and here is can see I am creating more particles, and that will be our source for the sand. These will be our sand particles. And you know that onto the grain source, we have the P scale value. And if you have the P scale on your points or particles, I can visualize them by changing this viewport visualization. As you know, if you right click and in here, we have the particle visualization. So all of the points are also said to be the particles. We can say them that these are particles. And in here, right now, we are visualizing them as points. I can change this visualization to pixel, and it will just change the visualization onto this viewport to pixels. And in here, we also have the visualization to change these two lit sphere. Let's add this and do it will just visualize our points as an A sphere and heroes can see. And because of the P scale, we can control the spare scaling by the P scale. And if I were to, let's say, increase the point separation and heroes can see when I am creating less of my points, I have an bigger P scale value and here as you can see all of these particles, all of these they are not intersecting. And that's what this grain source is designed to do. It will add points and all of these points have an AP scale that will not intersect, and I can inhere, create an A. After that, maybe let's lower down the point separation. Let's lower this down to 0.1, and some of the particles, these will be our sand particles. And now let's create an A grain simulation. Gran simulation is an a particle simulation, which means we need to create an a pop net. Let's add this and let's connect this onto the first input. And now let's dive inside and inhere Herosknc onto the PAP source, we use the first context geometry, and if we go back Heros canc we are using the first context, but I cannot see inhere my particles, and that is because the emission type, it says scatter onto surface. And if we go back and Heres can see, we do not have any surface. We only have these points. So let's go into this Dp net. And in here, let's change the emission type. Let's change these two points because we are working with points. So let's enable these two points and heres can see. And right now this visualization gone Hey wire. So maybe let's right click on it, and let's change these two points and let's click again and change these two. Let's fare again. And right now it's not visualizing correctly. Let me enable my play bar and let's play again. Here as can see we have our particles and in here to actually create the granular simulation, we have a node called pop grain. So in here, let's add an A POP gran node. Let's add this pop grain and let's connect this in between. This pop grain is an A solver itself. If I were to enable the parameter of this node, let me first remove this merge node and let's bring this down and let me rearrange this node graph. And this pop grain node, actually is the solver. So in here, we have the option for solving, so these are the advanced settings that we are not going to talk about. The default values are just fine. But so you know that it is an a solver, pop grain. And in here to create the granular simulation, we use this node, pop grain. And in here, we have the particle separation, which means we need to link this particle separation onto this grain source node. And here as you can see, we have the point separation. So to control this, I'm going to just copy this parameter. Let's right click and copy this parameter, and let's go into the grain source and inhere, let's space these two as an A relative reference, which means I can go back and inhere, if I want to create more particles, I just need to lower down this particle separation and both of these values will going to be adjusted accordingly, which is always a good idea. So let's sit play again, and here is can see our particles are being imported from sobs into Dubs, and we have the Sand simulation. Right now, it's not looking like a sand. So maybe after that, let's add an gravity force in here. So for creating the gravity, I can add an AP force node. And let's connect this in between and in here, let's change this to -9.8, which is an physically accurate value. And I think we need to add an M -9.81, and that is most accurate value. So let's go back and hit play. And here we are emitting our sand particles, and they are colliding with each other. If you look closely and here you will see that all of our particles will have collision, and that's collision what makes the particle look like sand. And before that, if we do not have an APOpcran, let me shake this node off and hit play. And here you will see that particles do not behave as if they have collision. They will just move. And after the plop gran we will see some collision happening. And right now we are emitting the sand particles. Let's go into the pop source node because we are using the point method, which means I can control the number of my sand particle by going onto the first step, and in here, I can adjust the number of particles that how many particles I want to emit. And whenever working with sand, we just want this we have the sand source. Right now, we have this sphere. Want the sand source to be imported only one frame into this dub net. And this dub net will take care of all of this shape, and we will going to simulate this as an sand as if we have a ball of sand or we have an sand clumps. For that, let's go into the pop net and onto the pop source. And in here, let's change this to all points. And when we will change this to all points, which means that if we go onto the first step, and here you will see all of these option has been disabled, which means we cannot add any more particles in here. So this pop source node will not create particles. It will just import all of the particles that we have onto the source. And if I were to middle mouse button and hers can see, we have an 2,600 points, and all of these points will going to be imported in here every frame. And impulse activation is on, you know that impulse activation means that we will going to be importing particles on every frame, which means if I were to hit play, and here you will see if I were to middle mouse button, and right now, here you can see we have a lot more particles, and that is because we are adding that many points, fibre to middle mouse button, that many points every frame. And I don't want that either because as you know, our this simulation is exploding. So to fix this, we need to keyframe this impulse activation to only just import this source onto the very first frame. And in here, I can place a key by pressing and holding the old key and click, I can add an a key, and I can just click on this button. These arrow means, we can go frame by frame. I can just click on this button. Now I am on the second frame, and onto the second frame, I can just go there and change this to zero and press and hold the old key and add a key. And now if I were to go back and hit play, and here you will see that because we have this interpolation, the value will go first because we have an between frame in here because we are working in the Dp net. And in the Dp net, we have subframe. So I can enable my subframe if I were to just zoom in. In here, you can click on this slider to zoom in. You know that that is our zooming slider. I'm going to just zoom in in here to this frame. We have a frame number one and we have frame number second. Frame one and second, we also have some between frame, and right now I cannot see them and to actually enable this between frame, I can just click on this button, and here we have this option enable playback at fractional frame, if I were to enable this now here you will see that this frame has been changed to floating point which it says 1.0. Now if you drag this and here you will see we have some between frame. We have frame number 1.1, 1.2, 1.3, 1.6, and all the way up to this second frame. So we have all of these between frame. And whenever we are working with this dynamic simulation when we are in this top context, we will be going to be calculating the subframe. We are also working with the subframe. If I were to go into the pop source and here as you can see, in between frame, we have this increasing value. In this case, the value is going down to zero because at the first frame, we have the key at one end at the second frame, we have setted the key frame to zero, which means that in between, we have the interpolating value and in here, you can see that slider is going down. And that's what confusing this pop source node. And to fix this, we can actually go into the keyframe editor, and by the way, you can go into the keyframe editor. If you have the keyframes in here, you can go into the right click, go into the channels, and the very first option is the isolate in channel list. Click on it, and it will enable these keyframes. And in here, you can adjust your keys and let me find I have the impulse activation and I can see that. Let me zoom in. And here we have here we have the one value, the second value, I can select both of these keys and I can change the interpolation. I can change this to constant, and what that will do, it will just not use the fractional points, sorry, these fractions if I were to go 1.1, and here you will see that at the second frame, we have the zero, and we do not get these in between values. And that is one way you can fix the problem or I can just not use the keyframe. I can add an A expression in here. So I can to remove this keyframe, right click and click on this let channel, and that will remove all of the keys from this parameter. Now let me zoom out to all of this frame range, and in here, I can just say that I can add a simple keyframe. So in here, doll sine F. DolineF mean the current frame number. And in here, we can say doll sine FF. And if you type doll sine FF, which means that we are saying that current frame number and the subframe number, this between frame number. If that frame number is equal to one, I can add the comparison by adding the double equal sine, which means that we are comparing. So I can add in a simple expression, say that if our current frame number, if that is equal to one, that condition is true, we will going to be activating this, which means that parameter value is one and which is only true at the very first frame. And if we go into the next frame and here's can see right now we are at the frame number 1.1, and our value is zero because we are no longer at the frame number one. So that is a very quick expression that you can use to quickly just enable your sources at the very first frame. And in here, I'm going to just disable this fractional part. And now, if I were to hit play, and here you will see that our source has been important at the very first frame, and now the simulation is taking care of all of the simulation. And in here, let's go back and maybe let's go into the sphere node. I'm going to just move my sphere up so that later on we are going to add crown plan for collision. And right now, you can see our sphere is going through this screen. So let's go into this fare, and I'm going to just adjust this its center to move our sphere a bit up. And now let's view this with the mountain node. And here can see by changing this, we are also going through the noise because it is an A three D noise. So which means that if you were to change this, you are also changing your noise sampling position. What I can do, I can just zero this out because I like the noise shape like this. So I can add an A transform. After that, we have calculator our noise. I can add the transform node, and now I can just move this shape up. Now we have an A, we have lifted up our source, and now we are using the grain source node, create our grain source. Let's go into our Dpneet and in here let's hit play and now it's going through. Let's create an A ground plan for creating the collision. And in here to create the ground plan, in here, we have a node called ground plan. Let's add the ground plan, and to actually act as an ecdrTGrowd plan, we need to merge this with this network. So in here, I'm going to add an A merge node and let's merge this with our simulation and connect this in here. And because we are in the dynamics, the order of these merge actually matter in this context. So if I were to enable the parameter of this merge node, and here is can see, we have the affector relationship, and it says left input affect the right inputs and we have the collide relationship between them. So which means that left input should affect the right input. And right now, we have if you take a look at this arrangement, right now, we have that is our left and that is our right. So what I want, I need to just rearrange this and to actually rearrange this wire, just click on this up arrow button and that will just rearrange the order. And now we have the correct order, and now let's play. And here you will see that we have the collision happening. And right now I am facing this weird bug of this viewpoard visualization. Let me see if I can quickly fix this. Let's right click and let's make this two point display. And I think that is coming from this guide visualization. And if we go into the pop source, as you know, we have the guides enable, and I think this guide is what making this viewpod go Hew let's go and uncheck these guides so that we do not have guides, and let's right click and let's change this fact to. Let's fare and let's hit rewind and hit play, and I think we have fixed the problem. And now I cannot see the weird viewpoard visualization. Make sure to uncheck this guide, and that is the very basics of setting up your granular simulation. We have this very basic sand simulation, and heroes can see all of these particles are colliding, and, you know, this collision is what makes them these grains particle. That's what gives them the volume. So in the next lesson, let's explore the pop grain node and understand all of these settings a bit better. Let's explore this pop node in the next lesson. 47. 47 Dry Sand Wet Sand: Now let's take a look at this pop grain node a bit closely, and let's inhere create an dry sand and wet sand looking effect. And right now, if I hit play and here can see we are using these default settings, and by the way, these default settings are fine. And in here, I'm going to just go back at the very first frame. And in here, first, I'm going to create an increase the number of particles, the sand particles. And to adjust this, we need to lower down the particle separation. Let's low down the separation value to 0.05. Let's start with this value. And now we have more sand particles, and let's play. And in here, as can see right now we are using this grayish looking color lit spare visualization and because we have the ground plane and that its color is too gray, so it's a bit harder to see, bit harder to visualize. So what I can do, I can create an Apop color node to set this color of the sand particles to maybe an sand looking particles. So in here, let's create an Apop color node. So let's add this in here and I'm going to just connect this in between, and maybe let's select all of these nodes. Let me press Escape key because I have wrongly selected from these inputs. Let's select all of them and to arrange them to make these nodes align. Let's go into the layout. And in here, let's align these nodes vertically. And now we have even this alignment. And let's go into the pop color node, and right now we are using this basic color. And in here, I'm going to use the ramp and right now we are using this gray scale ramp, and in here, we have some presets. Let's click on it, and from there, let's pick this and preset. And in here, right now, we are setting the color of our particle based on their normalized age. But I want to pick random color from this RAM. I want to pick random color to set the color of these particles. So to make all of these particles pick random color from this RAM, we can use an a random function. And in here, if I were to middle mouse button here can see, we have the number of points, number of particles, and in here, we have an A ID. So ID is an A unique value that has been assigned to each of these particles, and it is unique for all of these points, and ID will not going to be reused. So it's going to be used once for each of the particles. So which means we can use this ID to create our random color. So in here at the ramp we can create an A random function. In here, let's add an RN function. Rand is an A x function. So if you type RN, here's can see, we have this function. Let's click on it, and inside of the brackets to generate the random value, it needs the seed. We need to define the seed to create the random value. And for the seed, I'm going to use the ID because all of these particles have an AID and it is unique to each of these particle. In here, I'm going to say at, which means that we want to use the attribute, and now I want to type the attribute name, and that is the ID. And now let's close this small bracket. And now, this will create a random value, and its range will be in zero and one. It will give an output the zero and one value and assign random value to each of these particles. And which means that based on their random value, they will going to pick their color from this ramp. So some of these particles will get a white color, and here you can see some of them to have white color, and some of them will get this darkish yellow color, and that is a bit more like a sand color. Let's go back and inhere, let's play. So that is our visualization. And right now, hers can see our particles are sliding and they are sliding quite a lot. And that is because whenever we are working with the grains, whenever you are creating this pop grain node, we need to increase the number of substeps. We need to increase the number of substeps because this pop grain node has to calculate the collision. And if I were to play and maybe let's enable this real time playback option as well. And in here, hers can see we have this collision. All of these particles are colliding with each other. And that collision is what making the particle looks like sand. That's what giving them volume because they are colliding. And to actually make this simulation accurate, we need to increase the number of substeps. And right now, by default, this pop solver, if I enable the parameter, uses the one substeps. And one substeps is enough for creating your normal particle simulation. But whenever we are working with grains, we are creating collisions inside of these particles, particles are colliding with themselves. We need to increase the substeps. And whenever working with grain, you should always start with the substeps value of ten. So let's change the min and max substeps to tren. So let's start with that value, and now if I were to hit play and here you will see our simulation do get slow, but we will get an accurate representation of our simulation. And in here, here you can see our particles are still sliding, and that is because we have this dry sand and dry sand particles to the sand particle to slide. And inhere, let's go into the pop grain node. And inhere, at the very first, we have the friction and we have the friction with the collider and with the particles themselves. And its range is in zero and one. And if I were to lower down the friction value, let's change the friction with collider to zero. And here you will see that our particle will slide quite a lot because we do not have friction. And in here, here you can see now all particles are sliding too much. So the default value of one is fine and we have the friction with particles, and it is set to one, so that default value is fine also. And down here, we have the static threshold, and that is the value that it says that if the particles has an speed of 0.5, make these particles static. Do not make this particle move. So if I were to increase this threshold value, and here you will see that more and more particles will come to rest. And here you will see they collide and because they have an initial kinetic energy, and after that, they are becoming to rest. And heroes can see we do not have an A sliding effect because all of these particles has come to rest. So the default value of 0.5. And down here we have the scale kinetic, and the scale kinetic is the value that how much of their kinetic energy should be removed from the simulation. And if I were to increase the scale kinetic and if I were to increase this, which means that I am removing more and more energy from these particles. And right now, if I were to hit play, and here you will see that our particles will still get come to rest. So both of these parameter has the same effect. It's just that both of these parameter control different values. So it is a scale kinetic is an energy subtraction, how much energy we want to remove from our simulation. As always, the default are fine, make them to 0.1. And down here, we have the internal collision, and that is the collision that actually making these particles to collide with themselves. And if I were to zero this out, and it means that all of these pop grain, all of these will have no effect, we are still calculating slow because this has to calculate but because we do not have collision, our simulation just look the same as if we do not have the pop gran node. And if I were to shake this node off and if I were to hit play, and here you will see that, yes, we do get some pounciness. But here you will see we do not have any collision. And onto the pop grain, as you know, collision is what makes this particle special. So onto the popcran we have the internal collision. So we need to keep all the way up to one because we do want the collision, and that's what's giving them the volume. And in here, we have the stiffness and the lower stiffness value cause particles to bounce more. If I were to lower down the value, and here you will see that our particles will bounce quite a lot. And if we were to hit play, and here you will see that we have quite a big bounce. And this lower stiffness value cause these particles to bounce. And same thing if you were to increase the stiffness, our particles will bounce less. And if we were to hit play, and now we do not see that much of bounciness and here as can see and same thing, the default is fine. Just keep this at its default value. And down here, that is the most interesting setting, and that is the clumping. And this clumping is what create our dry sand and wet sand effect. And in here, we have the weight, which means that its range is in 0-1. One means that we are going to creating the clumping, and we are going to use this stiffness. And if I were to change this to one, and right now we have the stiffness and right now it's a very low value, but if I were to hit play, And same thing, here you will see that our particles are now sticking together and they are sticking together as they should be. And if I were to increase the stiffness, which means that I am creating more wet particles, more wet sand. And if I were to maybe, let's keep increasing this value and let's play and here you will see that all of the particles now try to stick together. And here you will see as you can see, the particles are not even breaking their shape as if we have an A mud. So that's maybe if you want to create an A mud simulation, you can just increase the stiffness value. And same thing, let's lower down the stiffness, and we can keep playing around with the stiffness value until we see an a wet sand looking effect. Maybe let's lower this value down to 25 and inhale as can see we have wet sand looking effect. Maybe let's keep lowering this value down and let's play again, and there you go. Ihe onto this clumping, we have this weight and this attribute is called the attraction weight, which means we can create this attraction weight attribute beforehand. And if we go into this soap level onto this grain source, and inhe as you know, right now, we are creating these points, these particles. And we are only creating an AP scale attribute. If I were to middle mouse button and here can see, we only have the P scale, and that's what's setting the scale of this particle. And in here, I can create an A attraction weight attribute to say that these are the particles that are wet and these are the particles that are dry. So I can set these beforehand into this soap level geometry level into the soap and when they will be going to be imported in here, this pop grain node will read the attraction weight attribute to set the clumping. So in here, maybe let's create an A attraction weight attribute, and I want to create an noise based attraction attribute. I want some of the particles to be wet and some of the particles to be dry to create an interesting sand effect. So in here, I'm going to use the noise. So let's add an A attribute, noise to create our noise base attribute. Let's add this, and as you know, the by default this attributes noise up our CD to create a random color. And in here, I want to create an A attraction weight attribute, and that is an A float. Let's change this to float. And in here, let's type the attribute name that you want to create, and I want to create attraction weight attribute. And now the attraction weight attribute has been created, and in here to actually visualize this attraction weight attribute, we need to just click on this button, and I think that visualizer we're on by clicking on this, we can enable or disable let's click on it, and here can see we are visualizing it. And if we click this one more time, that will just disable the visualization. But right now we are not visualizing this noise space attraction wight and that is because of the lit spare visualization. And to actually make this visualize, we need to change this visualization. Let's go into our display option, right click and onto the particles, let's change the visualization two points. And in here, heres can see we have our visualization. So this visualization actually does not work on the lid sphere. If I were to change this and here you will see our visualization is gone. So for now, let's change these two points, and in here, I can play around with the amplitude, and in here, I can play around with the element size to create more to create a high frequency, low frequency noise at just the amplitude. And in here, make sure that our values in zero to one range because, you know, this pop net, our attraction weight, its value is in zero to one. So we need to make sure that this noise is outputting zero to one. And we can actually adjust this by going on to the post process. Let's collapse this menu, and in here, I'm going to just enable minimum and maximum. And it will just clamp the value to zero to one range, and now this noise will work fine. And in here, now let's increase this amplitude and so that we have some bigger patches. And now let's go into the pop net and in here, let's see. And let's change our visualization back to it spare. Right click, let's change this to it spare. And now we should see some of the particles are dry and some of the particles will get an wet sand effect. And here you will see here as you can see, we have the partitioning effect. And I can control my overall this dry and wet sand effect by going on to the attraction weight in here, if the pop net has been visualized, heres can see we have this weird grid visualization because we are actually importing this ground plane as well. To fix this, let's go into the Wop net and enable its parameter and here we have the option two objects and it says that which objects that you want to import. And in here, let's only import the pop object because we know that the pop object store these particles. So let's go back onto the pop net. I'm going to just remove this wildcard. It says that import all of the objects, let's remove this, and in here, let's pick our pop object, and let's add this. And now, here you will see we are only importing these particles and we are not importing this crowd plane geometry. And we have this good visualization. And in here, let's go into the attraction weight. I'm going to increase the values. Let's go into the visualization mode. Let's change this to back two points. And onto the range, I'm going to change this to zero centered. So we have an A zero centered values. And now, all of these red particles will get an a wet sand and all of these, that has an purple color that will be our dry sand. So let's go into the Pop net and in here, let me change this back our visualization to let spare, and let's play again. And in here, we should clearly see the different partitioning. And here you can see, let me dive inside. And in here, you can clearly see that we have the effect. So we have the clumpiness. We have these wet sand, so wet sand are sticking together. We have the dry sand and they are sliding too much, and to actually make them not slide that much, maybe let's go into the pop grain node, and in here, I'm going to just remove out some of their kinetic energy. Let's increase the scale kinetic. I'm going to just change this to 0.67 and let's see how this result this value is looking. I think that this 0.67 is fine, and we still have some of these particles sliding let me go and let's increase the scale kinetic 0.8, and let's hit play again once more. And let's see. Now they are not sliding that much, and I think that value is fine. And remember that right now we are using a lot less particles, and Hees can see we have these bigger chunks. We have these bigger sphere. That is because our particles amount is not enough, and we will pick more detail when we have more particles. So maybe let's increase the particles, and in here, I'm going to change the particle separation to 0.01, and by doing so, and here we are creating lot more particles. And now if I were to hit play and simulate, and it will take longer to simulate, but we will get a much higher version of our simulation. And let me simulate few frame, and I will come back with a result. I had to stop the simulation because it was taking quite a lot of time to simulate because we are working with a lot more particles, and here can see I have very few case frame. Because of these sand particles, they are taking quite a lot of system RAM, and I do not have that much RAM. That is why all of these previous frame do not get cached. So maybe let's go back and I'm going to just increase the particle separation to not create that many particles. And you can create that many particle if you are going to render this because, you know, after that, we are going to create a file cache node. We are going to add a file cache, and we are going to writing out all of our caches. So in that case, this particle separation value is fine because right now we are working. We are just checking out the simulation setting. The value of 0.01 is just too slow. So I'm going to just increase this to 0.03. And let's play again, and here you can see the value of 0.03 is much more manageable, and we still have quite a lot of resolution in our particles. And in here, you will see some of the particles will have an A wet and some of them will have a dry sand effect. And here you can clearly see. So that's how you can create the wet sand and dry sand effect. 48. 48 Activating Grains: Now let's see how we can activate our grain simulation. And in here, right now, Hearers can see we are importing our source from sob let me go into my pop grain node, and let's lower down increase its value to 0.05 to create a much lower resolution, and that will create a faster flayback let's play and Hears can see right now we are just importing the sand source or these grain particles into this top net and we are simulating them. And in here, let's see how we can activate these grains particles to create an crumbling sand effect. So in here, let's see how we can do that. And in here, if I were to go back heres can see, I always get this weird visualization, and that is actually coming from this attribute noise, and here can see how this visualizer has been turned on. Let's click on it, and that will just turn off the visualization. And here you will see that we have the correct visualization that we had set into this pop color node. So in here, I'm going to create another source in here. So first, maybe I'm going to just duplicate all of these node, just click and drag in here to duplicate all of the node graph. And in here, right now we are using the fare. As a source, maybe let's create an squabGeometry in here. That is an interesting geometry. Let me view this and in here, I'm going to just adjust its rotation and let's rotate this. So I want to move these points a bit up, and onto the translation, let's also lift this squab up so that it's not going through the ground. And I think that is fine. And in here, I'm going to just remove the mountain node and let's also remove the attribute noise. We do not need this. Let's only just keep this grain source, and also let's keep the transform. We will need this transform. And in here, let me rearrange this. In here, let's first create an A activation attribute that will cause all these grain particles to activate. And in here, first, maybe let's connect this into the grain source because that will be our sourcing particles. And in here, let's create the activation attribute. And the way that I can do that, I can create an A attribute transfer node. And in here to explain this, let's create an a color node. And in here, as you know that we can set a color, I'm going to create a black color. Let me view this. And I'm going to just duplicate this node in here and I'm going to set change this to a value of green or red color. And onto this sphere, I'm using the polygons to create this dense, this high resolution mesh, and for transferring the attribute, we do not need that many points. And to create an A lightweight geometry, let's change this to primitive and that will just create an A one point with the radius. And now let's create an A attribute transfer node to transfer the attributes. Let's add attribute transfer, and that is the geometry that I want to transfer to and I want to transfer from or this sphere. And in here, let's view this. And here is can see all of our color value has been transferred. But what I can do, I can go into the attribute transfer, and right now we are transferring all of the primitive and points attribute, but we only want to transfer the points, so let's uncheck this primitive. And let's go into the condition tab, and in here, I can play around with this distance value. Let's lower this value down. And here you can see that we are creating this growing attribute, and here we have the growth. So we can just animate this parameter, and that will cause all of these propagation effect, and that will cause these particles to crumble. So in here, I can just go into the transform node when the node is selected, however to the viewpoint, and I can just use this handle and in here, I can define where I want my the sand particles to start collapsing. I can start them from here, and onto the attribute transfer, I just need to animate this parameter, and in here, maybe let's add an a key frame. So at the very first frame, let's change the 20, present hold the old key, let's add an a key. And let's go few frame, maybe frame number, let's say 48, that will be the 2 seconds. And after 2 seconds, let's continue adjusting this until I see all of these red values, and I think I have changed all of these particles to red. So in here, let's press and hold the old key and click on this parameter to add another key. And now if I were to hit play and here you will see we have the growth animation effect. So right now we are transferring this color, which is fine. We can use this CD to activate. But what I can do, I can create an a special active attribute. So in here, we can create an A attribute, create node in here. And I'm going to just create this onto this side. I'm going to remove the color from both of them. I don't want to transfer the color. And in here, we can say that I want to create an active attribute. So in here, I'm going to say active and its default value should be zero. And let's track this duplicate this attribute, create node, and connect this onto this side, and in here, I'm going to give a value of one, which means that we are transferring this active one value to this zero. So let's go into the attribute transfer. Onto the attributes, right now, we are transferring all of the attribute which is fine, which means that we will get this active attribute transferred over time. And let's go into this pop net. And in here, let's drive inside the pop net. And if I were to hit play, and here you will see we have the same effect. And maybe let's go into the pop grain node, and I'm going to just zero out the clumping to create an dry sand effect. And let's play, and heres can see we have this same effect, and that is because the active attribute that we have just created, this active attribute, it has no meaning into this simulation. So the POW solver does not know what to do with the active attribute. We do have active attribute, if I were to middle mouse button, let me move this aside, and here you can see, we do have active attribute, but it's just there. It's not doing anything because all of the pop grain node and the pop solver, all of these solver, they do not know what the active attribute is. But there is an attribute that this solver can understand, and that is the mass, which means we can set the mass. And if I were to go back and let's go into the attribute, create node, and in here, let's change this to mass. So mass is the attribute that the solver use to set the mass of these particles. So if the particles has no mass, if the mass is zero, which means the gravity will not affect the gravity will have no effect if the particles do not have mass. So which means that all of the particles will not be active because they do not have mass. I can do, I can create an mass. I'm initializing this to zero, and inhere, we need to do the same thing. We need to create an A mass attribute, and we are setting these 21 and inhere now if I dive inside and hit play, and now hairs can see our particles are not moving. O this gravity has no effect because we do not have an mass and inhere, this animated mass attribute that we just use the distance threshold to animate. This animated attribute will not going to be imported inside of our dynamic because onto the pop source, as you know, we are only importing our source at the very first frame, and after that, the simulation is just taking care of all of these particles and simulating them, which means that after the second frame, when we have the animation, we have updated the mass. All of these updated will not going to be imported inside of the Dp net. And to actually import them over time, import update this mass attribute at each frame inside of the top. In here, we can create an ab network. So inside of the Dub we do have an APP b. Let's add this. Here we have the pop b let's add this. Pop web is an ASM attribute door and it is designed to work with particle simulation. And it will going to be calculated every frame because it now is a part of the simulation. If the simulation is going to be calculated every frame, or this pop b is also going to be calculated every frame. So now let's dive inside and inhale. Let's import this mass attribute or this mass attribute inside of this pop b. To actually import this attribute, we have an A node called import point attribute because we are creating the point attribute. We need to add the import point attribute. We also have the detail primitive, all of these options. But because we are working with points, let's add an import point attribute. And in here, we need to define the PT num. We need to set the point number as well. And you know that because we are working with same source and in here we have the number of particles, so all of these point number are the same inside of top net as well, which means I can dive inside and in here, I can use the PTN of our simulation point because simulation point and the source point are the same, so we can use this PTN. And onto the file, we need to define the file. I can just use the up input one, which means I'm referring to this first input. We have this first input. So in here, I'm saying that import the attribute from the first input and let's bring up the parameter of the import point. And in here, right now we are importing the P, which means the position. But I want to import the mass attribute. So in here, I can say mass, and that is an float attribute so on to the signature, we need to change this to float. And now our mass attribute has been imported. Now we just need to export this as an A mass as well because we are importing, but we are not setting this to set this, we need to create an A pin export node, and that will export out the attribute. In here, same thing, I want to set my mass. Let's change this to mass, and let's connect the result into here. Now we should see the crumbling effect. Let's hit play, and here you can see our particles are still not moving, and there is one thing that we need to do, and that is, let's go into the pop parameter of this node itself and in here, we have the option to the inputs. Let's go in here. And here we have the inputs, these four inputs. So these inputs are referring to these inputs. So in here, I'm going to say that the input first. So if we were to dive inside, actually, these inputs that we have these inputs were actually referring to these inputs that we have in here, these op input one, two, three, four. So we are referring to these. So we are saying that this op input one this one, it will be referred to. We can say soap. We can define in here our own swap node, or I can just say first context geometry, which means that please import this first context geometry. So which means that this input one, this will refer to the first context. And we are importing this first context, this mass, and we are setting this. And now we should see the crumbling effect. Let's play again, and there you go. Here can see our particles are now activated over time because we are importing our mass attribute. And in here, let's go into the pop grain node and maybe let's lower down the particle separation. Let's lower this down to 0.03 so that we have much more detail. And let's it play again and here can see. We have the grain activation, and right now our particles are not sliding too much because we are removing most of their kinetic energy. So I'm going to just default out the scale kinetic to their default value and let's it play again. And now we should see that our particles will retain most of their energy. And we should see some of the sliding, and there you go. And here we have it. So that's how you can activate your grain over time. You can import your attributes inside of the top net using the boop boop node. And that way, we can achieve an activating this crumbling sand effect. 49. 49 Collision Based Activation: Now let's see how we can activate our grain simulation based on collision. And right now, here can see we are activating our grain particles with these attributes to create an a crumbling effect. And in here, let's see how we can activate the collision. And for that, I'm going to just create another simulation network, and for that, I'm going to just select all of these nodes and duplicate them by pressing and holding the old key and dragging them onto the side. And in here, this time, I'm going to just remove the attribute transfer and maybe let's remove the square node in here. Let's also not use this our squabGeometry. And in here, I want to create a pile of sand, and for that, I'm going to create an A box. So let's view the box. And onto the box node, I'm going to just increase its size. Maybe I want to increase its Z size. And let's keep increasing this and also let's increase its width. And in here maybe let's lower down its height and to actually make this sand or this box it onto the floor. Let's add a size node in here, mesh size, let's add this and connect this. And to the mesh size, we just need to change the justification why to minimum. And now let's connect this in here. And let's view this. And here you can see we have the sand. We have the sheet of sand. And we can control this. Let's go into the pop net, and right now we are creating a lot more sand particles, and they will be slow. Let's go into the pop. First, let me move this bop node. We do not need this. Let's go into the pop grain and let's increase its value to 0.05 so that we have manageable number of particles. Let me go back and let's also decrease its height so that we are not creating that much particle, and I think that value is fine. And in here, let's say that we have an A vehicle that is driving through the sand and we want to activate the sand only where we have an A. We have the collision between our wheels of the vehicle and the sand. And because if I were to play this as is, if I go into my dynamic simulation and hit play, and here you will see this simulation, this pop gray node is simulating these sand particles, and all of the edges, all of these particles are now crumbling, and I don't want that. I want them to keep their initial shape, this shape, and they are only get activated through the collision. And in here, maybe first let's create an ellision geometry and I'm going to create a rubber toy in here. Let me add the rubber toy and let's template or this rubbery geometry. And in here, I'm going to add an transform node, and let me template this transform node, and I'm going to select the node and press Centrinm if you put. I'm going to place my this rubber toy in here. Let's go into the transform enable its parameter. And let's animate this. Let's press and hold the old key and add a key. And right now, if I try to move this because I am visualizing the pop net, all of our dynamic simulation is going to be simulated also and to actually not make this solver simulate. You come over here, Hears can see we have this brain icon, and if you click on it, and Hers can see we have this top, which means that we are no longer simulating. And if I were to keep playing this and Hears can see, we are not simulating this. And even though we have set the display flag onto this top net, and if I were to dive inside and hit play and here you will see we are still not simulating. And onto the view pod, it's saying that dynamic simulation disable because we are disabling the simulation. And you also disable this simulation whenever you are working with the animation because right now I had to adjust this slider and if I were to not adjust this and if I were to keep adjusting scrubbing my playbr and here can see I am calculating my simulation. And to avoid this, just disable the simulation and now I can clearly scrub my playbar let's go into our playbr and in here, I'm going to just let me press and hold the old key and let's adjust my camera angle. And onto this frame, I'm going to just move my rubbery through and in here, press and hold the old key and left mouse button to add another key. And now let's hit Play. And here we have our rubber toy going through, and that is the animation that I like. I'm going to just connect this onto the second input. And now let's enable our dynamic simulation. In here, let's import this as an cider because right now we have just connected this onto second input, but we are not actually importing anywhere in our dynamics, which means Ahers can see if we do not have our robot way geometry. And to actually import this, we need to import this as an attic object because we want to act this as an edr only. So in here, let's add an attic object, and here we have it. Let's add this. And onto the static object, we need to define the saw path. And in here, Hers can see we do not have option to use these inputs, these first second inputs. We just need to manually go in and pick up our saw path. So I'm going to just pick up this maybe let me find the transform and heres can see we have multiple transform. So to find this pattern, I'm going to create an null node in here and I'm going to connect this, and I'm going to rename this to our collider is our collider. So let's dive inside. And onto the static object, let me pick up my collider null and let me find it. It should be at the top. And here we have the collider. Let's hit Accept. And we are importing our collider into the static object, but we are still not adding into our network because here can see this wire is not connected. So in here, let's connect this onto the merge. And as you know, that the order is important inside of the tops. And if I were to hit play, and here you will see that this will not has effect. And right now it's not animated also and to actually make this collider move because we have the animation, let's go into the static object and let's enable the use deforming geometry, which means that we have an animation. Let's enable this and let's hit play again. And now we should see movement. And here we have the movement. But here you will see that or this rubber toy is actually not colliding with our particles. It's just going through. And that is because of the order and onto the merge, here you can see, we have the left input affect the right inputs, which means that we need to move this onto the left side. So let's go into the merge and I can just click on this static object to rearrange my node graph, and here I have rearranged them. Now, these are left and these are our right, and now we should see the collision between them. Let's it play. And as it will go through, it will interact with these particles and here as you can see, or this rubber to moving or these particles. We have the collision. And now let's make the sand particles to only active when we have the collision. And to actually activate this with collision, we need to go into the pop solver, and in here, we have the sleeping option. Let's go into the sleeping tab, and here's can see onto the pop solver, we have the tab for sleeping. Let's click on it, and in here, I can just enable the auto sleep option. And let's also enable the start asleep, which means that at the very start, we will going to be starting our particle with sleep. Right now, they are in this simulation, but they are sleeping, which means that they will have no effect. And if I were to hit play, and here you will see because the particles are sleeping, they do not know what's happening in the simulation. They are not interacting with our colder because we are starting them asleep. Now let's awake this particle with the collision and we can awake them by adding an a pop awaken node. So if you type pop awaken and here as you can see we have the node pop awaken. Let's connect this in between and in here, we can say awaken by volume. So it needs the volume to awaken or the particle simulation. Which means we need to convert this simulation or sorry, this collider into volume. So let's go back and inhale. After we are using the transform, maybe let's convert this into volume. Let's add an VDB from polygon node. We can convert this by using the VDB from polygon node and connect this inhere, and now we have an a surface volume. And I think this resolution is just fine. And now, if I were to connect this, I'm going to just connect the transform node in here and here, as you can see, we have the collider moving or this volume moving, and now I'm going to just connect this volume into my third input. And now I can go into the boop net and onto the pop awaken, I can enable the awaken by volume. And right now it says SOP, which means we can define our sob path. Or I can use the context, and I have connected the volume onto my third context. So let's add the third context in here. And now we should see that whenever we have this collision, our particles will get awakened, and hers can see this rubber toy is awakening our particles, and all of the particles that are not has come into contact with the collision, they will stay asleep. And that's how you can dynamically activate with maybe you have a vehicle and you want the vehicle wheels to activate your sand. And that's how you can do that. And right now, Harris can see we do not have propagation effect. If I zoom in, only the particles that has came in contact with the collider get activated and not all of them get activated. But we want to also propagate this collision because you know that it's not going to be realistic if we are going to just leave it like that. So in here, I can also awaken by nearby particles, and let's enable this and it will look at this velocity threshold. So it says that if the particles will have velocity of one, they will going to be activated. So if I were to hit play, and here you will see that these particles has came in contact with the collider, first, they get activated and then they will hit the nearby particles, and they will also get activated. And in here, we can basically propagate these activation. And if I were to hit play and here can see the propagation has been visualized as an A fog volume. And in here, I can control the propagation by increasing this velocity threshold and if I were to increase this value, and here you will see that less and less particle will get activated because of the high velocity threshold value. And in here, I can see some fog in here, but in here, as you will see that not much particle will going to be activated. In here, basically, you can control the propagation by using this velocity threshold. And let me go back and rewind. And that's how basically you can awake your grain particles and let me go back and inhere, right now, hers can see we have this regular arrangement of these particles, and to actually break these regular arrangement, that's going to the grain source node. Onto the grain source, let me view this. In here, we have the option to enable the JiterScale. Let's enable the iter scale option, and it will take time to calculate, but here can see now we have the random distribution. And iter scale one means that we are adding the iter value of one. And if you still see the regular arrangement, you can also make the iter scale value higher. Let's increase this value to five. Sorry, the range is in zero to one range. Forgot it's an A zero to one range. One means that we are using a full iter scale. And in here, we have the breakups, and let's go into the pop net again and let's play. And right now, I cannot see my collider because, you know, we are only importing the pop object. Let's dive inside and let's play. And in here, we will see the same effect. We have the collider and it activating the particles, and we also have the irregular arrangement or the grain source. That's how you can activate your grain particles with collider. 50. 50 Rendering Grains: Now let's take a look at rendering these sand particles. And as you know that because all of these sands, they are just an A particle simulation. So the rendering is the same as you can render your regular particle simulation. Let's create an A lop net and import these grain particles and let's render them. So in here, as you know, you can add an file cache node, and first, you can write down your simulation cache. And after you have written out your caches, then you can import them into lobs. So I'm going to just add an op network in here. Let's add this and maybe let's create an a null at the end for referencing. And in here, I'm going to say out for render, rename this and let's go into the lop Net and in here, let me. I was just adding adjusting its viewpoint. And in here, let's add an Asap import node. And in here, I want to import my out render node, at accept, and here we have our sand particles imported. And in here, let's create an A material library. Let's create this material, and let's connect this and let's dive inside. And in here, let's go into the kerma and Kerma material builder. And I'm going to rename this material to our sand. That is our sand material. Let's dive inside. Let me remove this input. We do not need this. And in here to set the color, as you know that we have this random color, and I think that color is looking good for creating the sand particles. So in here, we can import this with the material X geometry, color node. Let's add material X geometry color, and let's connect this into the base color, which means we want to use the CD to set the color. And in here, let's go into the specular and in here, we just need to increase the roughness because the send should have an rougher value. Let's keep maybe just this 20.5. Let's go back and inhere, click on this autofil assigned to geometry and assign this in here. And down here, we need to create an light. So let's set dome light in here, connect this, and I'm going to use skylight garage, HDRI, let's pick our HDRI skyltGarage. Let me activate my Vetool again. And in here, let's create an Kermand connect this in here, view this and change this to XPU because we want to render this with XP. Let's change the render engine to Kerma XP, and in here, hers can see we are now rendering our particles, and here we are importing our P scale, and we also have our color information in here. And right now, these sand particles are too big because we have a lot less particles. And in here, you can create a more high resolution version of your simulation that will have very much smaller scale of the sand particle, and they will look like sand. But right now, they do not look as much sand because of the scale. Maybe let's also add an ground plan because right now, we do not have any ground plan. So for that, let's go back. I'm going to create an just simple grid in here. Let's add this. Maybe instead of creating the grid in here and we can go into the lob net and import this inside of the solas, we do have the option to create the grid. So let's add a grid in here and let's add merge node to merge both of them together. And here we have the ground or the ground added. Let's go into the grid, and in here, I'm going to just increase the uniform scale, and now we just need to create the material for our ground. So let's go into the material library. I'm going to go into the Kerma material builder and I'm going to call this one ground. Ground, let's dive inside and onto this surface material, I'm going to just create a very darkish grayish color. And onto the specular, I'm going to just increase its roughness value because I don't want the ground to be shiny. And you can import your own ground materials and you can just plug them in hair to create a ground. But I'm just using this simple grin. Let's go back. And in here to import this second material, this ground material, let's go into the material library and click on this autofill and that will fill out the ground material, and we just need to track this node in here. I'm going to just track the grade into this to assign it. In here to render this, let's change this to Kerma xPU Hers can see our ground has been added. And right now because this scene has been changed, Optex has to reinitialize. Hers can see it has been initialized and we are accelerated. Our rendering has been accelerated. And there we have it our sand particles with the grain. So rendering the grain particles is just as the same as you would render your normal particles. 51. 51 Grains Soft Body: Now let's take a look at the grain soft paddy simulation. Yes, grains can also be used to create soft paddy simulation. Let's see how we can do that. In here, let's create an geometry node, and let's time inside. And in here, I'm going to just create an rubbery geometry, and in here, I'm going to just convert these two as an A grain source. First, I'm going to just move this rubber toy up so that we have some distance between our ground plane and inhere, I need to convert this into grain source. So let's inhere type the grain source, and let's add this. Let's visualize this into the grand source to actually create the soft party simulation, we also have the option to create the constraint geometry, and we can create the constraint if you come over here onto the grain source. And down here, we have the option to the explicit constraint, and if you enable the create option, and it will just create this line. It will create these poly lines. And if we were to enable my point display, and here as can see we still have particles. We still have these points. But we also have these lines. These lines are connecting these particles. These lines we also called the constraint. So we are creating the constraint. These lines are the constraint. And in here, I can play around with the search radius. And if you were to lower down the search radius, it will just remove these lines. If I were to increase the search radius, I can continue creating more and more of these line geometry. And I think the default value is fine. Let's see how we can now import the constraint into our solver. And I'm going to just disable this point display. And that was just to let you know that we do have these points. Let's create an Pop net. Side this and collect this into the first input and let's tap inside. We just need to go into the pop source and let's choose these two points and uncheck the guide. Hers can see our particle has been imported. Let's go into the birth tab and same thing. Let's only import them onto the very first frame. I'm going to use the dollar sign FF. And for the comparison, let's add our current frame number is equal to one, which is only true at the very first frame. We are only importing our particle at the very first frame. And to make this simulation as an granular simulation, let's add an APOp gran node. Pop grain, let's add this. We also need the gravity. So let's add an pop force none. Let's add this, and I'm going to just add an gravity value to -9.81. And we also need the ground plane for the collision because if I were to hit play, animals can see these grain particles falling forever. Add a ground plan in between so that we have something to collide with. Let's add an merge node, and I'm going to merge the ground plan with my simulation, and we need to reorganize this network because this organization matter in here, and in here, let's play, and we have our basic standard particle simulation or gran simulation. Right now, Hears can see we are only importing these points if I were to change these two it spare, right click and let's change our visualization to it sphere. And Hears can see we only importing our grains, and we are not importing our constraint geometry. If I go back, let's take a look at the grand source. If I zoom in right now, it is harder to see. Let's go in here and change the visualization to points. Hers can see we have these lines. These are the constraint, and right now we are not importing them. And to actually import these lines, these are what called the geometry. And let's go into the pop net. And as you know, to actually import these poly lines, all of these primitives, they are what called the geometry. So let's go into these sources, and right now we are using the all points method, which means that we are only importing the points, and we are removing any kind of geometry that we have on our input and to actually import the constraint let's go into the Pop net and change this to all geometry. And now we do have points. If I were to enable points, I'm calling these points, calling these particles to points. We have the particles, but we now do have the constraint geometry into our simulation. And now let's play again, and Heres can see we have these lines, they are connected to these sand particles. And right now, these constraints are not doing anything. That is because we need to go into the pop grain. We can enable the constraint option. And we can do so if we go into the pop grain and here's can see, we have the option to enable the explicit constraint. And right now weight is set to zero, which means we do have constraint geometry, but we are actually not using them to actually put them into use. We need to just increase the weight value all the way up to one. Now this pop grain node will use this constraint, and now if I were to hit play and Hears can see we have this simulation, and now this simulation looks completely differently. Now let me change this visualization of this particle, right click and let's change this tool sphere so that we have the visualization and let's play. Hears can see these lines and I can now clearly see and these lines are now keeping all of these particles together. They are not breaking. So these particles are not going far because they are connected together with this constraint. And I can control the stiffness. And right now we are using the constraint, and in here we have the option to adjust the stiffness. And if I were to increase the stiffness, we will see a much more stiffer connection. Has can see if we have this weird simulation, if I were to hit play and Heirs can see we have this chigly animation. And that is because as you know, by default, we are working with very low substeps and let's increase the min and max. Substeps I'm going to increase them to create a better simulation because we are adding more substeps. Let's play again, and now has can see, we have the simulation and now it's simulation looks completely different. Going into the pop grain and inhere, that is the stiffness that is making these stiff constraints. If I were to lower down the stiffness value and let it play again, and herres can see. To actually right now we are using the more substeps, but we also have the constraint iteration. Let's go into the pop grain. And if I were to move this up, below the particle separation, we have the constraint iteration. So these are the iteration that will go through to solve the constraint. And we also need to increase the constraint iteration as well because now we are working with constraints. So in here, I'm going to start this with 100 and that will create an accurate simulation. And now, if I were to hit play, and here you will see that all these constraints will going to be solved accurately. And we have this soft party looking animation. And let's go back. Right now, we are also importing the ground plan. Let's go into the pop net. And I'm going to just move this wildcard, and I'm going to explicitly say that please import only the pop object. So now we only have this geometry to actually deform this original geometry because as you know, right now, we are only working with these points. While it looks like a soft body, we can actually deform this original mesh with these points as well. And the way that we can do that is by adding an A point form node. So if you type an A point form node, let me type point form, and here we have it. And the point deform node has three inputs, and the first one is the mesh to deform. And I want to deform my rubber to a geometry. That is the mesh. Let's connect this. And the second is the rest point lattice. It needs the rest point, and I know that these are my rest point. So after the pop need, I can add an a time shift node in here. Let's add an at shift node and connect this. And this time shift node by default, it does not do anything. It's just have the animation in here. But what I can do onto the frame right now we are using this Dlo sign F expression to adjust the frame. I can just right click and delete the channel we have the delete channel, so let's click on it, and that will just delete the expression that we had. And now onto the time shift, I can say that, please give me the frame number. And right now we are at the very first frame. If I want the frame number, let's say, 40, I can go into the Timeshift node and I can say that, please give me the frame number 40. Now if I type the frame number 40 and here can see how this geometry will stay at the frame number 40. So in here, I'm going to just type the frame number one because we only need the very first frame. And that is the static geometry, and that should be our rest point lattice. I'm going to organize this and plug this in here. That is the rest point lattice, and now it needs the deforming point lattice, the last one. And the last one, we are going to just plug this sb net or this top network because it has this animation. Let's connect this onto the third. Now if we view the point form node, and let's play and heres can see, we have our animation back, and right now this animation is breaking, and I can go into the point form node, and I can just play around with the radius to smooth out all of our breakiness let's hit play again, and here we have our animation applied onto our original hiras mesh. And in here, I can go into the grain source and maybe let's link the point separation to create high res version because as you know right now it is an A very coarse simulation. Let's go into the Pop need and maybe let's copy the particle separation parameter, copy parameter. Let's go back to the grain source, paste these two as an A relative reference. And now let's dive inside and I can inhere, create a higher version of our simulation by lowering down the particle separation. Let's change this 20.05, and now we'll get a much better representation of our geometry, and Hears can see our simulation looks different. Let's go back and inhale. Let's view this with the point form load, and Hears can see. And we can continue increasing this our resolution to add more of these particles. Onto the pop grains, we have the explicit constraint. And if you scroll down, we also have the option to break this constraint. And right now, as you can see, our constraints are not breaking, and I can enable the break constraint. And what that will do, it will look at this threshold if the constraints are deforming that amount. This pop grain node will just delete this constraint if I were to hit play and Harry will see that we will see the constraint breaking. And right now, all of the constraint has been broken. And now, Hears can see we only have a few constraints left, but most of them are broken. So maybe let's increase the braking threshold so that I don't want that much braking to be happening. And in here, you will see that only the constraint that has more stress, they will going to be broken. Let me go back. Let's see rewine and play, and hers can see. We have some of these parts. We have some of these clumping back. So all of these constraints are now broken. And by doing this constraint, you can also create your mud type simulation. I'm going to just after the pop net, maybe I can create this as an particle fluid surface because I want to convert this into mud. So let's at a particle fluid surface node, and let's connect this in here, and that will just convert our points into mesh. And right now the particle separation value is too high, so let's slow this down to 0.05 or maybe 0.01. Errors can see I can see some of these particles and not all of them. And that is because this node requires a lot more particles, and right now we do not have that many particles. We have var spars. Errors can see if we were to change these two points, as you can see, we have these very sparse particles, and this node is designed to work with millions and millions of particles, but we only have few thousand, and that is why we have this issue. Let's go into the particle fluid surface. I can keep lowering this value down, particle separation. Let's lower this value down to even further, maybe 0.05. We might need to increase the radius, so attribute radius. This value is for the outputting and to actually create this, we need to adjust the p scale value in here or maybe I can just simply say VDB from particles, and I can convert these particles to mesh by using our own VDB from particles node. So let's connect this in here, and I need to lower this value dom, 0.01, and there you go. We have right now this mesh because of the course resolution can clearly see my these sphere. And after that, maybe let's smooth out this mesh. So I can say VTB smooth SDF because that is the SDF representation. So let's add VDB smooth SDF node to smooth out these particles. Right now, I'm using the mean value. I can change this to causium. I can pick any of these algorithm that will work good. I think the main value is fine. I suggest the filter radius to smooth out. Now we have this VDB or this surface VDB. And right now, Hearers can see we have this mud looking this mesh. Right now, we do not have mesh. Sorry, it is an surface VDB. And to actually convert this into mesh, we can say VDB, convert VDB. So let's add and convert VDB in hair. Let me add this and I'm going to convert this into mesh. Right now I set to volume. Let's change these two polygons. And now we have actual polygonal mesh, which means now you can write out this cache, and it is ready to render. That's how you can actually deform or create your own mud simulation. Let's go into the pop net. Let's go into the pop gran. We have the stiffness and we have the breaking threshold. If I were to let's continue increasing this and maybe let's also increase the stiffness value, and that will create an A, maybe let's adjust the visualization because right now I can only see the constraint. So let's right click and change the two lets fare again so I can see my grain particles. And now let's play. We have the breaking threshold high, but we also have the stiffness high. And I think that breaking threshold is too high because no constraint has been broken. Maybe, let's change this to 0.1 and let's play. We should see some of the broken constraint. Or the head piece of geometry has been broken. Our head has been broken. Much of the geometry is staying as whole. I can continue lowering this value down even further and lets it play again, and we should see some more breakups in our constraint, and there you go. We have the constraint breakup. That's how you can create your pop grain constraint. You can create the grains to create the clumping, to create the mud, or if you want to achieve a soft body simulation. So you can create them using these constraints. 52. 52 RBD Dynamics Introduction: Now let's take a look at the RBD dynamics, the Rigid Body simulation. Let's see how we can create that inside of IH Dini. In here, let's create an Geometry node, and in here, let's create an A geometry that we want to simulate. And I'm going to just create an rubber geometry in here, and here we have it. And now let's make this an ARBD object, and let's simulate this. And first, I'm going to just move this up the translation so that we have some tristance between the ground. And now let's create top net, our dynamic network because, you know, rigid bodies and a dynamic simulation, which means we must be inside of the top net. And now let's type inside the top net. First, we need the object. And because we are working with rigid body, we have the RPD object node, and here we have it. Let's set an RPD object, and we also need the rigid body solver. So in here, let's type the rigid body solver, and here we have it. And the first input of the solvers are for the object, so let's connect this, and I'm going to connect this onto the out. And right now, here is can see we have the sphere. And that is because onto the RBD object, if I enable its parameter, and here as can see, we have a default geometry onto the sob path. And right now we are not importing our own rubber to a geometry. So in here onto the sob path, let's import our rubber to a geometry. In here, I'm going to just select my geometry and hit Accept and there you go. Here we have the geometry imported in two tops. Now with that, this simulation network is done. We have the solver and we have the object, and now if I were to hit play, and Hers can see nothing is happening, and as you know, we do not have any forces in here, so let's create an A gravity force. I'm going to type an A gravity, and here we have the gravity force, and we just need to connect this in here, and now if I were to hit play and hers can see our object is falling due to the gravity, and I'm going to enable this real time playback. Now let's add an A ground plan in here for the collision. Right now it's going through because there is nothing to collide with. So in here, I'm going to create an a ground plan. Let's type this and let's merge this with our simulation, connect this into the merge node and we need to organize this because order of the merge matter. Let's click on it, and now we have onto the left side. Now this ground plan should work as an ecldr. Now, let's it play and heres can see. We have our very first RPD simulation. Right now, errors can see we are using this RPD object, and it is computationally heavy to calculate this rigid body simulation because we are now right now simulating all of these points. I can see my simulation geometry if I go into the RBD object. Let's enable the parameter. Let's go to the collision tab. We can see what this solver is actually using for the collision. Can enable the collision guide. Down here onto the collision, we have the RBD solver, and right now we are using the volume based collision. Let's enable this collision guide, and here it is visualized in this blue. And right now our collision geometry is cutting off because of the simulation geometry. So I'm going to just inhere click on this display geometry to uncheck this option, and there we have our collision geometry. So that is basically the geometry that we are simulating. And right now, Hears can see we have this volume based collision, and I can increase the resolution. And same thing we have this uniform or this auxel size because we are working with volume. And now let's increase this and Hears can see as I am continue to increase this right now, I think I accidentally create a lot more axels, and that is why my Houdini session has been freeze. So I'm going to just lower this value down to maybe 100 to an manageable axel size. And right now, here is can see we have a very high as mesh. And if I were to hit play, and here is can see our simulation is very slow because we are simulating all of these points. I'm going to just default out the settings, press and hold the Control key and middle mouse button to default it out. So let's make this onto the default. Let me also disable the collision guide and let's enable the display geometry. Let's go back and if I were to middle mouse button onto this Dp net, and here you can see right now we are using the two megabyte of our system RAM just to simulate this single object. And it will get slow if we are going to create multiple of these object, and I can create in here by adding an a copy and transform node. Because as you know, when we are working with RBD simulation, we might be creating the restruction simulation. And in the destruction, we have a lot more smaller pieces of geometry. We have chunks of different pieces of fractured geometry, rubbles. It it's not going to be just a single piece of object like this. We will have many, many pieces that we want to simulate. I'm going to just create a copy do transform and let's translate this a bit up maybe let's add an AC onto the translation and in here, I'm going to just create multiple copies. Now if I were to import this inhere, right now, hers can see this connection does not matter because inside of the top net, we are actually defining our subpath inhere, which means that if you connect this or not, it will still going to be work because we are not using these inputs. We are not referencing them. Onto the top net, let's import this copy node and onto the RBD object. Let me pick my this copy, and here we have the copy one and hit Accept. And here we have all of our geometry important. And now, if I were to hit play, and here is can see now the solver sees all of the geometry as we have this NA one geometry. So the orbity object, this rigid body solver, does not know that we have multiple geometries that we want to simulate. And which means we need to create we need to actually extract all of our geometry. Copy and transform node, we have some attributes. So let's go in here. We can enable the copy number attribute, and let's enable this, and that will create a copy num primitive attribute. And if I were to middle mouse button, and here you can see we have the copy num. And it will just store the number of copies. And for the very first copy, it will just store the copy number, which will be the zero, one, two, and three, four. It will start with the zero. Right now we are using the five copies, so we will get the number at this 0-4. I can confirm. Let's click on this copy and transform, going to the geometry spreadsheet, and it is an primitive attribute, so let's go into the primitive. And here we have the copy number. Let's click on it and maybe click on this again to organize this change, this order ascending. Here you can see we have the copy number four, and we are starting with zero. It will just storing this copy num. And now I can just make an a selection based on this attribute because let me enable my selection tool. Right now, my selection constraint has been enabled. As you know, if I were to change this to three D connected geometry, we have this rubber to a geometry that is actually made out of multiple pieces of connected geometry. We have that is connected, that is connected, and we have multiple pieces. So this connectivity will not work. And instead, I'm going to use my own attribute. So in here, just click on this name attribute. This selection is looking for the attribute that is called name. We do not have name attribute, but I want to select based on my copyum attribute. And to actually change this, let's click on this gear button. We can say attributes, and here we have the list of attributes that are present onto the geometry, and I'm going to change this to copyum. It will take a look at the unique values, and right now here it finds that all of the geometries has unique. We have zero, one, two, three, and four. And now I can just select my this first copy, and in here, I'm going to just blast this out. Type blast and enter. And it will just blast this copy only, and we have all of our geometry. What I can do, I can just isolate this. So let's go into the Blast node, and right now we are using the copy nu zero, and let's click on this let non selected. That way we can just isolate this copy. And I'm going to just duplicate this plus node. And for this one, I'm going to just change this value. And here you can see we are using the copy numb for the primitive deletion. And in here, I'm going to just change this to one and that we can isolate this, and I'm going to duplicate this again, and I'm going to change this to two. Let's duplicate this again and I'm going to change this three. And we have these four copies. Let's go into the Db net to actually import all of them. We need to create separate Obd objects. Let's inhere onto the saw path. Let me pick the copy number zero. That is our first orbit object, and I'm going to just duplicate this orbit object. I'm going to select my second copy, duplicate this again. I'm going to pick our third copy, duplicate this one more time, and now we have the last one. And now to actually add this into our simulation, let's add an A merge node. And let's merge all of our objects and use them into the solver. And I think we accidentally we are importing this multiple time if I were to delete this, and I think that that is plus two, and that is plus three. So why was looking the same. Let me check first. Let me connect this in here, and here we have it. Let me connect this in between. Okay. I think it was just showing me that but it's fine. Now let's hit play, and here you will see now we have multiple objects. Here's can see it's actually slow. It's actually also slow to import because, you know, we need to separate all of our object if we want to simulate them separately. And it is also computationally slow as well. And right now we are only working with four copies. We are only just creating ORBD these four objects. If I were to go back and present hold the middle mouse button, and here is can see only these four objects, these four copies, they are taking 14 megabyte of system RAM. Well, right now, it's not quite a lot, but, you know, as the number of copies will get increased, this will going to be increased exponentially also. So to fix this, there is a better way to simulating the RBD object, and that is the RBD fact object. Here to create the RBD packed object. First, we need to pack our geometry. Right now, hers can see if I were to middle mouse button, we are working with regular geometry, which means we have these points. If I were to enable my selection, let's disable this selection constraint. Hers can see we have all of the individual polygons and we also have individual points. We are working with actual geometry, actual all of these points. And what we can do, we can pack our geometry into single point. So in here, I can do this by adding an pack node. Let's add this in here, let's connect this. And as you know, that pack node will pack our geometry into single point. If I were to middle mouse button, Hers can see we are working with one point only. And Houdini is drawing our geometry. Houdini knows how to draw the actual geometry, but geometry itself is not there. We only have one point. If I were to try to select, and here is can see, I'm only able to select one point because we only have one point that is storing the location where this three D object is placed in the three D space, and it is also storing the orientation. How the object is oriented in the three D space, which means that we are only going to simulate one point, and it will be very fast to simulate. Because these are the rigid bodies, they do not deform. We do not need the actual deformation onto our mesh. We are actually going to be simulating its position and orientation because in the rigid body dynamics, only the position and orientations matter. Let's see how we can use the pack primitive to simulate. And I'm going to this time connect this onto my first input. Let's dive inside the top net and let's rewind to clear out, to go back at the very first frame. I'm not going to use the RBD object. I'm going to just remove this wire and maybe let's select all of them, and let's put them aside. I'm going to just remove the wire in here. And to actually import this R packed geometry, we also have an node called RBD packed object. If you type RBD packed object, and here we have it. Let's add this, and that is also an object. We need to connect this onto this object slot. Onto the RBD packed object. In here, we can specify our geometry source and we can pick our saw path. Or in here, we also have the option to reference these inputs. So I'm going to use the first Context geometry so that I can use these inputs for referencing. Now if I were to hit play and here's can see, we still have this RBD simulation, and now it is a very fast simulation because we are not simulating all of these points. And it is also creating an ellision mesh because we need the mesh for collision information, and we can visualize our simulation geometry, like we have visualize onto the RBD object. We also have the visualization onto the RBD packed object as well. So let's enable its parameter, and we can view this into the pullet data because we are going to we are right now using the pullet solver, and here as you can see the solar engine is Bullet. Bullet solver will use the pact primitive to simulate your geometry. I can enable the show guide geometry, and heres can see that is the geometry that this solver is actually simulating, if I were to Zimon and heres can see it is a basic representation of our geometry. It's wrapping convex hull of geometry to represent the original geometry. And I can change this collision shape. Right now, heres can see we are using the convex hull. Can change this to concave. And right now I cannot see this. Maybe let's go into the display geometry onto the simulation geometry. Let's uncheck this to actually visualize. And now we are going to simulate this C cave. Now, it will be expensive to simulate, but we will get better collision. And if I were to hit play, and it will be slow because now we are working with a lot more points. Let's change this to convex hurdle and we also have some other option. We can change the two box. It will just orient box around it and it will simulate only box and it will be very fast. And I'm going to use the convex hull, and you should always keep these two convex hull. I'm going to uncheck this it geometry and enable display geometry. Now, I can import multiple of these object. Let's go back onto this copy and transform. Let's maybe add this in here and I'm going to fewer just to connect this onto the pack. Right now, if I were to middle mouse button, and heroes can see this pack object is now packing all of our geometry because now this pack node thinks that all of this geometry is an A one piece of geometry. So, into the pack, all of this is one single piece of geometry. And if I were to go into the top net and simulate, and hers can see we are simulating this as if we have a one piece of geometry. And to fix this, we need to create an individual packed primitive. And because we are working with copy node, you know, I can go into the copy and transform, and in here, we have the option to enable pack and instance. And let's enable this, and what it will do, it will just pack all of our copies and then it will instance them. Now if I were to middle mouse button, and heres can see now we are creating five primitive, we are working with five copies, and now the solar should work fine because now it knows that there is a five separate pieces of geometry because we have five separate packed primitive. Now if we go into the top net, now it will create convex hull for all of these objects separately. I can confirm. Let's go into the RPD packed object, and let's enable the show guide geometry. And Hears can see now we have convex el for each of them separately. And now if I were to hit simulate and Hers can see this simulation is working, and now we are only using the single object to import all of them. Before that, we need to create the RPD object separately for each of the object. Let's go back. I can just keep adding more and more of our geometry. Let's say, I'm going to create an grid node in here and I'm going to just let me move this up, and I'm going to create an copy transform node, copy and transform and sorry not copy and transform. Copy to points because I want to copy this geometry onto my grid points. Sorry, why I'm keep using this copy transform. Copy to points, copy to points. Let's set this, and that is the Jome tree, and that is our points. And let's view this copy to points. And right now, these copy to points is not packing our geometry. Hers can see. Can pack this. Let's go into the Covid bone and enable pack an instance. Now if I were to middle mouse button, now we are creating 100 packed fragments. And right now the alignment is not correct, but that's fine. Let's go into the grid, and I'm going to change the center to move this up so that we have some Tristans between the ground. I'm going to just first, I think they are now intersecting. We need to go into the grid and let's increase the overall size until they are not intersecting. And I think that value is fine. Let's connect this onto this Dp net, and let's visualize this and hers can see. We are simulating all of our object, and right now our simulation is very fast. It's very responsive. I can keep adding multiple copies, and after that, maybe let's connect this copy and transform node. I'm going to not use the pack and instance because we are already working with pack geometries. So let's go into the copy, and it will just create these pack prim tips. And right now we have a lot more of our geometries. And now let's connect this in here and let's simulate. And here as you can see, we are simulating just fine. We are working with lots of lots of objects. And if you take a look, it's very responsive. If I were to press and hold the middle mouse button, and here's can see even though we are working with a lot more of our packed primitive, we are only still using 400 kilobytes of system RAM. These packed primitives, these RBD packed objects are very efficient to simulate. We are going to be using these pack geometry in the RBD simulation. We also have the RBD solver available onto the soup if you type the RBD solver, and here we have the bullet solver, RBD bullet solver, and let's add this, and that is an AM top net with the basic node that we have just created or this rigid body solver gravity, and all of these things pre attached, which mean we can just connect this in here onto this bullet solver and hit play and all of our simulation will work fine. I'm going to just not create that many copies. So let's lower down the number of copies, and here you'll see and can go into the bullet solver and we have some parameter can go into the collision tab, and in here, we also have the option to add the ground plan. So let's add the ground plan, and let's hit play, and here is can see. We have this simulation top net preconfigured for us, which means we do not have to every time create this top net ourself. So let's take a look at this RBD bullet solver in the next lesson. 53. 53 RBD Bullet Sop Solver: Now let's take a look at fracturing the geometry, and also let's take a look at the RBD bullet solver that is also available in the sob. So in here, I'm going to create an A geometry node, and let's add this. I'm going to create an a simple box. I want to create an A fracture wall onto the box, I'm going to just play around with its size to lower down the thickness, and I'm going to increase its size and also let's maybe increase its height a little bit more make this sit onto the ground, let's add an match size node, and let's add this and connect this, and we need to view the match size. And in here, justification while let's change this to minimum. Now it's sitting onto our ground. Now let's fracture this because right now we have this single piece of geometry. We have this one single solid box. And to actually fracture this, we have several method to fracture this. And first, I'm going to take a look at the Vern fracture. So if you type the Vern fracture node, and at this here we have the Vern fracture. Let's add this and it has two inputs, geometry to fracture, and that is the geometry I want to fracture, and it requires the points. And we need to scatter the points. First, maybe let's add scatter node. And as you know that this scatter will just scatter a bunch of points onto our input mesh, we are scattering these points, and now this Vern node will use these points to fracture our geometry. And right now we are using 1,000 point, which means that this fractured will going to be fracturing this wall into 1,000 pieces. And I'm going to connect this in here. Right now, it's throwing an error because we haven't yet attached the points. So now if I were to display this now the error should have been gone, and here as can see we have this geometry added. And right now, we are fracturing this onto all of these many pieces. And I can if I enable my selection tool, and maybe let's change this to primitive, and Heres can see, we have the travisions going on, but all of them are actually separate connected pieces of geometry. Let's go into the selection constraint, and let's enable this with the three D connected geometry. And in here, Hers can see, we have all of these separate connected pieces. If I were to select this and let me enable the move tool and let's move them. I'm going to change the camera angle and use these handles. And Heroes can see we have this separate piece. I can keep selecting this and let's move them. And heres can see we have fractured our wall into all of these different pieces. Let me go into the edit node and I can define how many pieces I want to create of these fractured pieces of our original mesh by going on to the scatter node and in her playing around with this scatter amount. And if I were to create less point and Hees can see, we are fracturing our geometry into bigger pieces because we have less points. If I were to enable my selection and these connected pieces has been turned on, we need to actually highlight this Verni fracture to have the effect on the selection. And now I can pick any pieces and I can move. And Heres can see now we are creating these bigger pieces. And now let's simulate them. I'm going to just delete the added node. And if you were to middle mouse button, and heres can see we are fracturing this. And this V fracture node is also creating an name attribute, and it is assigning an unique name to each of these fractured pieces of geometry. And right now, if I were to middle mouse button, we have 51 unique name because we are creating 51 points, and hers can see we have 51 points, which means that we have 51 separate individual, all of these fractured pieces. If I were to increase this value, if you were to view this, I can press and hold the middle mouse button onto this output. Here's can see now we have 117 name unique name, which means we have 117 these individual pieces. And now let's simulate them. And as you know, we need to pack our geometry. After that, I can add an pack node. Let's add an a pack, and let's connect this onto this one. And if I were to view my this note and press and hold the middle mouse button, and heroes can see this pack node is actually packing all of our fractured geometry into one single points. It thinks that it is a one single piece of geometry. But in here, as you know, we have multiple pieces of connected geometry, and to actually make this pack object to recognize all of these connected pieces of geometry, we can enable the parameter of the pack. And here, we can enable the name attribute. And in here, as you know, we have the name attribute onto these primitives, 117. And we can say that onto the pack node, if I were to enable this and it will look at the name attribute, and if it finds the unique name, it will pack them separately. Now if I were to middle mouse button and now heres can see we are creating 117 packed primitive. Because now this pack node knows that there is an 117 different connected pieces of geometry because of the name attribute. Let's enable this, and now we should see I can enable my selection tool. Let me highlight this pack node. And in here, hers can see now I can able to select all of these pieces separately. And if I were to move and I can move my piece, and right now it is just one single point. We do not have access to its individual polygons. And because it's a packed primitive Nu, which means now it is ready for simulation. And after that, I can add an richard body solver that is available in here. RPD bullet solver, that is the name of this solver, RPD bullet solver. Let's add this and connect this. That is our geometry. Let's go into the RBD bullet solver and let's play. And here you can see how this wall is falling due to gravity. Let me enable the real time playback. And in here, let's add the ground plan for collision. Let's go on to the bullet solver and go into the collision tab onto the collision. Down here, we have the option to enable the ground plan. Ground type is set to none, we can change this to ground plan. And here we have the visualization. And this ground plane is an infinite ground plane, which means that you are not restricted to this visualization. Your geometry can be anywhere in your three D scene and you will have a ground plan. This ground plane is an infinite ground plane. And now let's hit play and here can see. We have our wall that is made out of many pieces, and now these pieces are fracturing. I can dive inside this bullet solver because you know that we have this that is an wrapper of the dynamic node. So which means I can dive inside this, and now Hers can see we are in the dynamic context. We can add our own dynamic nodes to customize this dynamic simulation. Hers can see we have this option to wire our pop forces onto pre solve. And here we have the pre solve and we also have the post solve. And we can actually use the particle forces to control the simulation of these RPDs because you know that we are working with points. All of these simulation, all of these geometry, they are still points. I can if I were to extract all of these points, here, let's add an A, extract all points, and I can connect this. And here is can see we are removing the geometry but keeping the points. Hers can see, we are just simulating these points. These points have the position information and the orientation information, and this bullet solver is actually creating the convex hull for the collision, but basically, we're just simulating these points. To the bullet solver, I can here we have the output. If I were to connect the extract point onto this output and visualize and Hers can see, we still have these points. If I were to hit play and Hers can see, we still have these points, which means that we can use the particle forces with the bullet solver as well. So let's dive inside. Going to add a force node to maybe add wind in here. So let's add the PP force and we need to connect this onto the presol and here is the sticky node that says we need to connect this onto the presolOto the PP force, I'm going to just increase the amplitude and let's play. And here you will see that we will have the movement, and I think right now, it's a bit harder to see. So I'm going to just increase this amplitude value and has can see. And you can create this wind force effect with these pow forces, you can create this if you want to create a leaf simulation. Maybe there is a bunch of leaf on the ground and wind is blowing these leaves and that you can create them with these pop forces. I'm going to just remove this pop force node and let's go back. Here you can see this simulation geometry is crumbling at the very start. Let's make this wall, make this hole. I don't want this to crumble right away. This RBD bullet solver, it understand bunch of attributes. And if the attributes are present onto the input geometry, it will use this attribute to configure your simulation. And right now, Harris can see fab to middle mouse button, we do not have any attribute. We only using these packed primitive and the RBD bullet solver simulating the packed primitive. You can add an ARPD configured node. Let's add an RBD configure. Let's add this. It is very good helper node, and it will create some attributes for us. You are actually not needed to create the RBD configure. You can create all of these attributes on your own, but here you can see onto this bullet information, here we can enable the attributes. We have the active animated we have all of these attributes, and these are the attribute that this bullet solver understand. And if these attributes are present, the bullet solver will use this attribute to set up simulation. This RBDcfgure node, it will also pack our geometry for us, which means that we do not need this pack geometry also. We to just delete this done and onto the one fracture, and Hers can see I'm not using any pack geometry. We are working with original points and primitive. We are working with his geometry, and I can just connect this RB decon figure onto the first input. And if I were to view this and Hears can see, or this RBDconfgure node is packing our geometry, and I can confirm. Let's go into this output that is the geometry output. And if I were to middle mouse button, and hers can see, we are creating 117 packed fragments, and it is also creating these point attributes. And these are the attributes that we have just enabled. Let's go into the RPD configure. And if we were to just remove all of the attribute but only keep the active and if I were to middle mouse button, and Hears can see, we have the active, we have the bounds, and we have all of these attribute. I can go into the parameter. Let's scroll down and Hes can see it is also setting some physical attribute. It is assigning, for example, the transty value and the bounce value. And right now, I'm using the concrete preset, and we also have some other preset. I can say that O, this current geometry is an a piece of glass. I can change this to glass, and what that will do, it will just create the density and bounce all of these attributes that will better simulate the glass effect, and I can also change this to wood. You want to create your own density, just click on this user option and that way you can create your own density value and same thing onto the bounds, I can just enable the user bounds, and that way I can define my own bounces value, or I can just completely disable all of these attributes, and now we shouldn't see them if I were to Middle Mouse button, and heres CC we only keeping the active attribute. It is also transferring the name attribute that was actually this worn fracture node is creating. If I were to middle mouse button, here's can see, we have the name, and it is just passing through the name attribute. Are only creating the active. If I were to disable the active and now you should see that node, this node is actually not doing anything. It's just packing our geometry for us. And if I were to connect this, which means that we are just using this node to pack our geometry. And if I were to play, we still see the same effect. But I can say onto the RBDcNFgure I can enable the active. The active one mean that this simulation geometry is active, which means that all of the forces, our bullet solv forces will affect this geometry. And here's can see active if the value is one, nothing has changed. But if I were to change the active value to zero, that means that the bullet solver, all of the forces, the gravity forces and other forces, they will have no effect on these inactive RBD objects. They will still be in this simulation. They will still collide if you have another collider. But they will not be active. And if I were to hit play and Hearers can see all of them, they are not active. Maybe I can say that I want to activate my jomtree with the collision. Let's create an collision object, and I'm going to use an a simple sphere node. Let's add an a primitive sphere. I want to create this just basic primitive sphere. And I'm going to visualize my sphere and template visualize my wall and template my sphere. I'm going to add an A transform nod. I'm going to template my transform. Maybe let's go into the sphere, and let's lower down the uniform scale value. Let's select the transform, press Enter. I'm going to move this. Let's animate this sphere. So onto the transform, I want to animate along the X axis. So at the very first frame, let's add an A key let's go few frame forward. And let's make this sphere move along X and pres, hold the old key. Let's add another key, and now we should see the movement. And now let's add an A RBDcNFgure node to configure this. I'm going to add an RBDconFgure node and onto the RPDconfgure that will just pack our geometry we were to meddle mouse button, and here as can see we have the pack geometry, and we also have some attribute bounds and density and all of them. And now let's merge both of them. I'm going to just move the extract all points. Let's add and emerge to merge both of our geometrees. Let's add and merge both of them. So now we have the all and we also have the sphere. And now our sphere will be simulated as well. And here is can see our animation has not been imported. Gravity is affecting the sphere. It's falling down due to the gravity, but the animation are not being imported. And that is because we need to set the attribute onto this input geomete. We can do so by using the RPDcanFgure. Let's enable the parameter. I can say that enable the animated and this mesh or this geometry is animated. I can change this to one. And if I were to hit play and Hears can see our animation, sorry, I was just visualizing the RB DicanFgure. Let's go into the bullet solver and let's play again. Heres can see our animation is still in our solver is not importing the animation, even though we have the animated enable, and that is because we also need to disable the activation. And right now because we have the active geometry, which means that gravity and all of the forces will affect this RBD object, and that is why this animation has not been important. To actually import your animation, you must not use the active. So let's change this active to zero. Our animation should be imported in the bullet solver, and all of the forces will have no effect. And if I were to play and I cannot I still cannot see them active animated is one I need to check, go into the bullet solver. Let's go into the properties. We can say that we are overriding our active and animated, but why it is still not there. Let me go into the RBD configure. Maybe let's enable the deforming as well. Let's change this to one and let's play. I think because we are adding the animation, we are actually deforming the points, and that is why we need to enable the deforming option. And now we have our or animation. But right now because both of them are inactive, right now, we go into the RPD Configure, heroes can see it is right now inactive. That is why our collider has no effect on it. So I'm going to just change this to one. And now we should see the collision, and I still cannot see the collision let me see why is that. Let's go into the RBD figure. Maybe I think I need to create an name attribute because, you know, on this side, we have the name. Here as you can see, we have the name, but on this side, we do not have the name. So maybe let's create an A attribute, create node to assign an name because name is essential. So I'm going to create an attribute that is called name, and it is an A string. So I'm going to change this to string, and I'm going to just name this as an Sphere. And let me connect this and we have the name as an a string, and RPD configure. We'll use this name attribute, and here we have the name and spare, and now it should work. Let's play. It's still not interacting. That is very interesting. Let me go back onto this RBD configured node. I think we do not need to enable the deforming. It was actually not importing our animation because we do not have the name attribute, but now we do have the name. So I'm going to just not use the deforming option. So let's uncheck this deforming. And now let's view this again with the bullet solver, and there you go. Now we have the collision. And it is now colliding. And now I can go into the rbidecan figure, and Hers can see we have the collision. The collision is now working, but our all is also falling before the collision. So I can go into the rbidecan figure node. I can say start with inactive, which means that right now this all has not been active. It is an inactive. And I can go into the collision. We have the minimum activation impulse. So if we were to enable this, which means that if we have the collision, if something is collide, we have an collision impulse. We can define the threshold. In here, we say if the collision threshold is above 0.15, make all of these things active. All of the object that has come into contact with collider, make them active. So now if we go into the bullet solver, let's twine and hit play, and heroes can see. All of these geometries that has been with contact this sphere, they are now active. And when they are not getting hit, they get back to their inactive state. And that's how you can control your activation with the collision. So in the next lesson, let's explore some other fracturing techniques because fracturing is important when you are going to be working with the Richard party simulation. Right now we are using the one way fracture and we also have some other fracturing techniques. Let's take a look at them in the next lesson. 54. 54 Animated Vs Deforming: Let me clear out the confusion that I made in the previous lecture about the active and deforming. If we go into our RPD configure and here is can see previously we have these two options. We have the animated and we have the deforming. So let's see what the difference between the animated and the deforming. And let's also see you know that when we are going to, let's say, not create an attribute name, right now, we have created an in name and we are using the sphere. But let's say if I'm not going to connect the name, and right now we are not creating the name. If I were to middle mouse button, and heroes can see, we do not have the name. But if we go into the arbitican figure, and if I were to middle mouse button, and heroes can see we have our one pack geometry, also have the name attribute. So if the name attribute is not present in your input geometry, this arbitican figure node will create a name attribute for us if we in here and Heres can see, we have the attributes and name prefix, and it's using the piece, which means that if the name is not there, it will just create the name and with the prefix of piece. Right now, we have the one piece. We have the single connected piece of geometry. We should see the piece zero. I can confirm, go into the RPDconfgure. And in here, we have the name onto the point attribute. So let's go into the geometry spreadsheet and let me enable my point attribute and heres can see. We have the name attribute, and it says piece zero. We have the name attribute present in here. And we were using the V fracture to fracture our geometry, and if I enable the parameter, and here is can see this V fracture node, it is to creating an apiece prefix. It is also creating the name attribute if you were to middle mouse button, and heres can see, we do have the name attribute. And it is also using the piece prefix, which mean that if I enable the primitive attribute because it is creating a primitive attribute, hers can see we have the name and it start with piece zero. And it is starting with piece, and it will assign zero, one, two, three, all of these pieces and a unique number in front of them. And after the RBDcfgure it will transfer our name attribute onto the point, and now we can see the on our point level, let's go into the points. I can see our name attribute. We have the P zero, one, two, three, all of the name attribute. Because of that, because we were using the same name, here as can see onto this piece attribute, here we have the name. It is set to piece zero. And we also have the piece zero in here as well. So we are using the same name on both of these our stream, and that is what causing the confusion onto this bullet solver, and I forgot to actually rename this. We can fix this by either creating our own name attribute that we just did previously. Going to just connect this in here now that we are creating the name and we are adding the name in here sphere. And now this arbiticanfgure node will use the name attribute because the name as attribute is present, and it will use the name to pack our geometry. So I can go into the arbitconfgure, and I can confirm, go into the geometry spreadsheet and here's can see now our name is set to sphere. And if the name is not there, if I shake this off and here's can see it is saying P zero because it is automatically assigning the name with this piece prefix. That is what causing the problem. So the name attribute is present and make sure that do not use the same name in both of your side and multiple times because that will cause the confusion in this solver, because solver recognize all of these pieces with their name. So they must be unique. We have the option that is active and animated. Active means that you know that if I were to disable the animated, now that we have solved the problem of the naming by creating our own name attribute, and by the way, we could have also solved this if I were to shake this node off. Hers can see we are using the same piece prefix that is utilizing the word noi. I can just go in here, either change the piece prefix in here, say, I'm going to say piece underscore. Vole I'm just changing the prefix, which means that we are adding the piece vol and then the number. So if I go into the RBDcfgure and geometry spreadsheet and here is can see, we have the piece and vol and the number zero, one, two, three, we have updated our prefix, which means now this RBD figure is still using its own piece prefix. So now it should have an piece zero. And it is using this piece wall. Now we have unique name attributes. So now we do not need to actually create this attribute create and this automatic attribute creation will work. Now, if I go into the scene view again and let me Nb buy bullet solver and let it play. And as you know, we have disabled the animation option. Activate mean that the forces has no effect, and to actually import our animation, we need to enable the animated and change this to one and play and we have our animation back. The deforming mean that right now hers can see because we are working with one point. This fare is a one point. We are actually animating this one point, and that is why this animated is working. If I were to change the two, let's say, regular mesh, I'm going to change these two polygons, and here you can see, now we have all of these primitive, we have multiple points. And now because we are still using the same transform, but what this transform is actually doing, it's actually moving these points. We are moving all of these points. This transform is moving them, which means that we have our deforming geometry. So now if I were to do the same thing onto the RBD configure, heroes can see we have the animated enable. Now this animation won't be imported. I can go into the RBD bullet solver and hit play and Hes can see. Animation is not there. And that is because now we have the deforming geometry because we are working with actual points or actual geometry, and we are using the transform node and it is deforming them. We need to go into the RB Decanfgure in here, we say that animation is not there. I'm going to just change this to animated, and I'm going to say deforming because right now we are basically deforming these points, and now it will work. Let's go into the RBD bullet solver and hit play and hers can see. Now we have our deformation back. And to actually make this work, this animation work, either we can change this to one point, I can go into the primitive and inhere now because we are working with one point and this transform node is just moving this single point and the Arbiticonfigure node will recognize this as an animation. I can just enable the animated and it will be important in our simulation network. And to actually take the benefit of the animated and later I will explain why the animated is beneficial. But if you are going to pack our geometry, right now, here onto the RBDicanfgure, this node is packing our geometry, and I'm going to do the same thing onto this fare, I'm going to change this to polygons. Now we are working with all of these points. We have our original mesh back. I'm not going to use the transform node to transform all of these points. But instead, I'm going to move my packed geometry because, after we have packed our geometry, and right now we only have one point. We are only working with one point. If I were to middle mouse button and heroes can see we have one point. Now if I were to animate this one point and because right now we have first packed our geometry and then we are transforming this, now this animated will work. So in here same thing animated is enabled, which means now if I go into the bullet solver and hit play and Heroes can see, we have our animation back with the animated even though we have all of these because now this transform node is moving this single point. And that works because onto the rbdicanfgure, when we are going to create our pack geometry, when we are using this pack, this pack will create a single point. As you know, if I create an extract all point, I'm going to say extract all points and connect this in here. And here we have the one single point. And this single point has information. It has the rotation information and orientation and the translation information. And all of these information are stored in what called the intrinsic attribute, and I can view them. If I go into the geometry spreadsheet, hers can see all of these attribute because right now we are in the points. We need to go into the RBDconfgure to actually view this as an a primitive. And here is can see pack, we have the packed primitive. We still have one point, but it is an event packed primitive. And onto the primitive, we have some intrinsic attribute, and I can view them by going onto my primitive attributes, and in here, we have the option to view the intrinsics. And if I view this, and here can see we have our intrinsic attributes. We have the packed full transform. And if I enable this, and here you will see that it is creating this an A four by five transform matrix. And this transform matrix is what storing the position information of our sphere for these points because right now our point is located at the origin, so we have this 01, all of the default full transform matrix. It knows where this original sphere is. It does not have to be sphere. I can create a rubber toy geometry in here, and here we have the rubber toy, and I can connect this in here. Now our rubber toy is an Apack primitive, and now I can go into the geometry spreadsheet and primitive and same thing I'm going to first, we need to click on this RBD Configure to have access. And here you can see, right now we are creating nine pack fragments, as you know, because we have multiple connected pieces of geometry. If I were to enable the selection and three connectivity, you see, we have multiple connected piece of geometry, and this RBD configure will look for the connectivity and create unique pack primitive. And here's can see, we have multiple packed primitive. We have the ten pack primitive. Let's go into the geometry spreadsheet, and that is why we see multiple of these points. All of these points have their own full transform matrix, all of these matrix, and that is what's storing the position information. We are scattering the points. We are adding the points for each of our connected object, and I can view them by extract all points. And here you can see we have these points for these connected pieces of geometry. Here, I am creating one point that is defining this piece and another point that is defining that piece, and we have all of these points. And they are what storing all of our position and orientation information. And Houdini knows how to draw our geometry. And that's how these pack primitives are working. When we are going to pack our geometry right now, we have packed our geometry, and we are going to transform our pack geometry. You know, first, we have packed them, and now we are transforming our pack geometry. And by doing so, we are updating our transform matrix. If I go into the geometry spreadsheet, Heres can see we have some values updating. And if I were to hit Play and Heres can see, all of these values are changing. And that is because we have the animation that this transform node is changing this transform position and because we have updated this transform or this position, and that is why we have this moving animation. And as you know, Houdini knows how to draw your object. And that is why after the RBDcan figure, we have the animated option working because now we are just animating this transform matrix. We need to click on this transform to actually view this heres can see how the transform matrices has been updated. Before that, if you add an A transform in here, as you can see we still have the animation, but right now we are packing our original geometry. Now we shouldn't see this pack transform updates. If I go into the RBD configure, go into the geometry spreadsheet, here can see if I scrub, my pack transform are not updating because we are packing after we have animation, and it will always by default stay onto its default location. And that is why this arbitT animation option is looking for this packed full transform to update because there is no update or this transform matrix is not updating, that's why this animation is not being important. And heroes can see it is not being important because of the odor. And let me disconnect this and connect this after that. Now that we are moving our packed fragments, now we should see the animation. Let's go into the bullet solver, and heroes can see. We have our animation back. And the difference between the deforming is, let me move the rubber to a geometry and right now it is throwing an error. If I were to deform this, right now, if you were to add an A transform node in here, I'm going to just connect this. This transform node, it is actually deforming our points as well. And same thing, I can add noise based transformation by adding the mountain node in here, I'm going to type this and add this. Let's animate these points. I'm going to change the range value to positive and let's increase the amplitude and maybe let's enable the animation option so that we have the animation. And now Heirs can see we have our points and they are deforming, which means if I were to connect this in here and I'm going to visualize my this sphere, and let's template this geometry. I'm going to just displace this in here, and I'm going to place this in somewhere so that we do not have collision at the very start, and now I think we are getting the collision. Okay, that is fine. Now you know that these points are deforming. Onto the rbdicanfgure, to import these animation, this animated won't work because we are packing onto single point and we have all of these deformation onto this level. If I go into the bullet solver and let it play and heroes can see, we do not have animation back. And if I go into the RBDcanfgure, and we need to enable the deforming and we actually do not need to enable the animated because we are writing the deformation. Now the deforming is enabled. Now our solver will look for the deformation. Let's play and Hers can see. We have our deformation back, and we should see some collision. And right now, hers can see. We have the collision. I'm going to just increase the amplitude value so that we have some higher collision. And let's play. And heroes can see how this animation has been important and it is also interacting. You should only use the deforming option when necessary, and that is because it is computationally expensive and why it is computationally expensive, and that is because we are updating our collision shape geometry every frame because the solver saying that this collision shape is changing. In that case, it is changing. And I can also visualize my collision geometry. Let's go into the RBD bullet solver. I can go into the visualization, and in here we have the show collision shape. Let's enable this. We are visualizing this as an wireframe. I can enable this show collision shape. Let me hit rewind and hit play. And heroes can see we have this collision and it is changing. We are updating this collision shape geometry every frame. Our this convex hull is changing. That is why it is computationally expensive because this solver has to recalculate its convex hull culon geometry every frame. In the case of the basic transformation, because in this case, we are actually using the mountain node to add the deformation. In this case, it is essential to use the deforming because there is deformation. But in the case of simple transform animation, if I were to remove the transform or sorry, mountain node, in here in the transform, if we were going to use simple this transform, we actually do not need to create an A animate. I'm going to add an a key Sorry, I need to move this in here because I'm going to just move this in here, add an key, go back at the very first frame, and let's place this somewhere around here, and we have some animation. Now, in the case of this simple transform, we actually do not need to create the deforming, even though this deforming is working. That is not the efficient way because, you know, we are calculating this collision shape every frame. So we can actually save our calculation by not using the animated, sorry, by not using the deforming, but we can use the animated and to actually use the animated, you must need to add the animation when you have packed your geometry. In here, we have the packed geometry, and now I can add the transformation. And now this pack transform will going to be updated. We go in here and here can see how this transform matrix has been updated, which means this solver will recognize this and let's play, and here we have our animated geometry back. So that is the difference between the active and the deforming of this geometry is. Let me go into the RBD configure. That is the difference between the animated and deforming. I hope that have cleared all of your confusion. 55. 55 Fracturing Geometry: Now let's take a look at the different fracturing technique. You know that fracturing is important to creating your destruction, simulation or RBD. In most of the effects, we must need to re fracture our geometry. Let's go into the geometry node. I'm going to create an A geometry, empty container, and let's dive inside. Let's add an A box in here. And I'm going to adjust its parameter of the size. Let's adjust its size and let's slow down its thickness. And also, let's make this box size a bit bigger. We have used the i fracture. You know that we can add the scatter node in here and we can just connect the scatter to also add an one fracture, and that will fracture our geometry based on these points. Right now, hers can see we are scattering our geometry onto the surface. Right now we are creating this box, but let's say if we have a different kind of geometry, I'm going to add an sphere in here. This time, I'm going to add an eolygnal sphere because we want to fracture our geometry, and we must have some geometry in here and I'm going to make its radius uniform scale a bit bigger. Let's use the scatter none. And right now, here as can see we are scattering the points onto our surface of geometry. And now if I were to connect this in here, that is our geometry. I want to fracture, and these are these scatter points. And now if I visualize and Heres can see we are still fracturing our sphere. But let's see how these fractured pieces actually look like. I can either select, I can enable my selection tool and why this three connectivity is on. I can just select any of these. And right now heres can see this scatter node is highlighted and the viewport only affect the highlighted node, which means we need to select this one now and now we can able to select this. And in here, I'm going to just select this piece, and now I'm going to just move this. Hers can see that is how our fracture looks like. And we can also visualize our fracture pieces by using A, we also have a node called exploded view. So let's add an A exploded view node in here. And that will take a look at the connectivity, and right now we have these connected pieces of geometry, and it looks for the connectivity and explode them, move them. So in here onto the exploded view, hers can see we have these pieces pushed apart. I can go into the exploded view. I can increase its uniform scale to adjust our visualization to make all these fractured pieces move. Hers can see we are fracturing from our surface. We are adding fracturing from our surface and it is going deep. We have all of the geometry because we do not have point on the inside of our sphere. Hers can see that is why we do not have fracture on the inside. And to fix this, you should always use the volume. First, you must convert your geometry into volume. And for that, I can add an IO offset because, you know, we are going to fill this whole geometry with volume, so we do not need to create the VTB volume the Houdini native volume IO offset is fine. So let's add the IO offset in here, and I'm going to just increase the sampling to create more of our resolution. Sparsity does not matter because we want to fill our entire geometry with auxel information with fog volume. So we must use the IO offset. Now because we have filled our geometry with axels with this fog. Now if you scatter this onto volume and hers can see, now we are scattering on the inside, and I can go into the scatter node, and maybe let's uncheck this relax iteration. It is just relaxing these points so that they have event distribution. I'm going to uncheck this and let's enable the force count and heres can see. We are filling our sphere with points. Now we have points on the inside as well. I'm going to just lower down the number of points because I don't want to create that many fracture because these points will define the fractured pieces. And now because we have points on the inside. And if I go go into the Vern fracture, and now we should have the fractured pieces on the inside as well, and there you go. Heoesc see we have a very different kind of fracture. And whenever you are working with the bone make sure to first convert these to iso offset so that you have some points inside of a geometry so that you are not creating the weird kind of fractured geometry. And before that, errors can see we have this very weird fractured geometry. That's the one way fracture. I'm going to keep this enable, and let's go into the box node. We also have a node called RPD material fracture. Let's add A RPD material fracture node. And here we have it. Let's add this, and we need to connect this onto a geometry, and let's view the result of the RPD material. And this material fracture node will going to be fracture our geometry to simulate the material type. Right now, we are saying that our material is the concrete, and it is strategically fracturing our geometry based on how the concrete would fracture in real world. And here as you can see, we have a very different kind of fracture, and I can view this by adding an exploded view in here. Let's connect this inhere onto the exploded view. Let me connect this. And here is can see we have that's how this fracture look like I can go into the material fracture and let's go into the primary fracture, and we have different kind of level. Right now, we are using multiple level first level in here, we have these scatter points. So it is still using the scattering method, and right now we are scattering from volume, which means this original mesh is going to be first converted into volume, and then it is scattering the points. And in here, if I were to create more points, we should start to see more and more fracture happening. And here is can see that is our first layer. Sorry, I'm right now the second layer. That is our first layer. Our primary fracture, our first layer, we are using the five. I can keep increasing this. Hers can see our primary has 18 and secondary I'm going to just lower this down, and you can also keep adding multiple layer by clicking on this button. Let's go into the Plus button, and that will just add another layer, and now we should see third layer in here. And right now it is calculating because it has to look at the previous level, and here is can see. We are fracturing into a lot more pieces. And every level uses the previous level. First, we start with the base. So we are creating 18 base pieces, these big pieces, and then these 18 will going to be sub fractured into 15 pieces, and then all of these 15 plus 18 sub pieces will going to be fractured onto this third level and we are further fracturing it down onto five. So we are creating multiple layer of fracture. If I were the exploded view and hers can see. Now we have a lot more fractured geometry. Onto the RBD configure, I'm going to let's not use a third layer. Right now, hers can see we are using this very sparse method, and that is because the cell points, it is also noising up our volume. We are creating this into fog volume, and we are also adding the noise. If you want to create the event distribution of these points, you can just go into the noise type and change this to nun. That will just cancel out the noise and now you will have an even distribution of point. If I were to continue increasing this and hers can see, I am fracturing this evenly. I can say the same thing for the second level and here we still are using the noise, I can change this to nun and hers can see. We do not have a section that was fracturing more. And for real estate fracture, you should keep these two default the sparse convolution. It is fine. I'm going to not use that many fracture points. We have the material type reset. Right now we are choosing the concrete. I can change this to glass. It will fracture our geometry if as the glass would fracture, and here's can see. We have a glass type fracture. I can define the number of these fracture by going on to the scatter point. I can increase this to multiple level. Let's change these two, three, and now hers can see we should see these three level of three points of impact that has happened onto the glass. Let's go into the exploded view and Heirs can see we have some fractured. Let's go into the glass, sorry, material type, and we also have the type wood. Let's change this to wood. And now Hers can see we have these wood planks. Let's go into the exploded view and Hears can see. It is creating these fractured geometry as the wood fracture. I can go into the grain, and in here, I can play around with the grain spacing. If I were to lower down the grain spacing, I'm effectively creating more of these pieces. Let's go into the cut tab, can define the angle, skew angle, let's play around with it. And we have some all of these parameter. Let's change this to concrete again. And right now, Hees can see, we do not have the detail on the inside. If I go into the exploded view and let's increase the scale. And Heres can see, we have these uniform straight cuts. We can also add the noise detail on the inside. So let's go into the RBD material fracture and on to the primary fracture, we know that we can define the primary and secondary. And the next step is the chipping. You can enable the chipping. What that will do, it will fracture your corner. And here you can see at the corner, we do not have a fracture chips. So if I were to enable the chipping, and here you will see that here you see, our corner has been fractured into these smaller chips. And I can increase the chipping by increasing the chipping ratio, and I can create more of these chips, and that will also create a more realistic looking fracture and here is can see because we are adding a lot more smaller pieces and bigger pieces. And I'm going to just disable this. And let's go into this tab detail. And here we have the detail, and that's what adds the detail on the inside. And right now, here you can see we are using these straight cuts. I can say enable the edge detail. And what that will do and Heres can see, it is now distorting the shape and by distorting, we should have the noise detail on the inside as well. If I go into the exploded view, and hers can see. We have some noise up information on the inside, and I can increase the noise. Height, and that is basically the amplitude. It will just further distort the straight edges if I were to increase the noise height and hears can see. We are completely reshaping these fractured these straight lines, and now if I go into the exploded view again, and hears can see. Now it is starting to look more like an A concrete. I can define the element size, and that is basically the frequency of your noise. I can create high frequency noise by lowering down this element size, and that is the basic height. I can also enable the interior detail, and what that will do, it will just further add the noise on the inside. So if I were to enable the interior detail and heroes can see the inside has been further we have further deformation on the inside, and I can play around with the amplitude and our inside geometry is going to be distorted even further. That way, we can very quickly add a lot more detail. I'm going to just lower down this noise amplitude. And now let's remove this exploded view. And now if I were to simulate this, first, I'm going to make this box sit onto our grown by adding the match size none. Let's add a match size and connect this onto the match size changes justification why to minimum. Now we are fracturing it. Now let's add an RPD configure node. And as you know, RPD configure going to pack our geometry for us. And right now, we do not have our packed geometry. We are working with our regular geometry. This RBD material fracture, it is creating the name attribute for us. I can go in here and in here, we have these pieces prefix, and in here, I can add my own prefix. Right now, it's just adding the dash. Let's see, add the ArbiticanFgure, and that will pack our geometry, and I can go into the geometry spreadsheet and let's take a look at the name attribute. And after the Arbitican figure, it should be on the points. Let's go into the point. And here we have a piece, and we have these dashes. And these dashes are coming from these multiple layer because we are using this one layer, second layer, and we have the ID. And this RBD configured node is using the name to pack our geometry. Now that we have our pack geometry, it is ready to be simulated. So let's add an A RPD solver in here, RBD bullet solver. Let's connect this and to the bullet solver, let's also enable the ground plane. So let's go into the collision crown type at the ground plane. And let's hit play, and heroes can see. Now we have our fracture that looks more realistic because we have a lot more detail. And same thing, I can just need to go. I only just need to go into the RBD material fracture, and in here, I can say that now I'm working with wood. Give me the wood fracture. I can change this to wood. And now, if I were to simulate this bullet solver, hers can see we are simulating as if we have a piece of wood. And right now, this mesh is actually intersecting. So to actually fix this, I'm going to just transform this. So after we have fractured this, I'm going to add an transform node, and I'm going to just displace this, adjust the placement, press the enter to have the access to manipulator and rotate this so and now because we have an angle, now we should see the falling effect, I need to contemplate this transform so that I don't know what have this weird visualization, and hers can see how this geometry is falling. Let's go into the material fracture. We are sing the wood. Let's change this to glass again because we want to simulate the glass and let's play. And Harris can see right now or or this glass is too thick, so maybe let's lower down its thickness because glass is not that thick. It will be a thin piece of glass. I think that thickness is fine. Let's go into the bullet solver again and let's it play, and there you go. Now we have our piece of glass that enable the real time playback. And that is the different material fracturing technique, and you should always make your fracture pre fractured geometry as realistic as possible because, you know, these are the pieces that will actually going to be simulated. That's how you can fracture your geometry. 56. 56 RBD Constraints: Now let's talk about constraints. What are constraints and how constraint works. And in here, I'm using this very simple scene. I have just created the box and match size, and I'm using the scatter node to scatter a bunch of points and in here to create the irregular arrangement of these points onto the scatter, I'm just not using the relax iteration, and I'm using the one fracture to fracture out geometry. And in here Heres can C, we have multiple outputs. This far fracture outputs these two outputs. The first one is the geometry. I can create an annual and I can view and by default, we are actually viewing our geometry. And the second output is the constraint geometry. If you connect this and Heres can C, we have all of these edges. We have these polylines and these are what called the constraint. Let's see how these constraints actually work. And I'm going to create an A example in here. I'm going to create an box node, and let's visualize the box and maybe let's move this box up so that we have some offset. Let's add an A sphere nod. I'm going to create the sphere, and let's visualize this. And I'm going to add its center and also let's adjust its exposition as well. Let's merge both of them. And I'm going to merge both of them. I want to create an unique name for both of them, and this time, I'm going to manually create the name. So I'm going to add an attribute create and I'm going to create the name attribute and set the name to name. And that is an string. I'm going to change this to string. And this one, I'm going to say that that is the box. And I'm going to duplicate this node, connect this in here, and I'm going to rename this sphere. And that is our sphere. And now we should see these two unique and here's can see, we have string and we have two unique names. And now we can add the rbi deconfgure and ArbitcanFgure, we look for the name and pack our geometry. And right now we have this weird visualization for the box, and that is because of the normals. So let's go into the box and we need to add the vertex normal. And now because we have normals, we shouldn't see the weird visualization. Let's check and Here's can see. We have our visualization good. Now we are ready to simulate. In here, I'm going to add the RPD bullet solver node, and I'm going to connect this in here. Let's go into the bullet solver. Maybe let's add the ground plan because you know that it will just fall down forever. Let's add the ground plan and let's play. Here can see we have these two objects and they are simulating independently. I can go into the box, maybe let's add an A rotation in here. I'm going to add some Y and some Z rotation. And let's play and here is can see. Both of them are simulating independently. We have these two separate RBD object. Now let's say I want to make a connection between them. I want to constraint these two geometries together. I want the box geometry to be connected with the sphere, and I can connect these two geometry with the constraints to create the constraints, we need to create the polyline between them and let's see how we can do that. And right now we have these two geometries and we are packing them with the rbdcan figon after that, we have these two points and two pack primitive to actually make connect these two points because after we have packed our geometry, we are only working with points. If I were to extract all points, you add this. You know that we are working with just these two points. So to connect these two points, we have a node called Connect Adjacent pieces. So if you type connect and here we have the connect adjacent pieces. Let's add this, and I'm going to connect this because these are the points I want to connect. Let's view this. Nothing is happening, and that is because we need to go into the parameter. We have the search radius. So it is only looking for the radius in the 0.1. And right now, the distance between two is greater than 0.1, so we just need to increase the search radius to look for more and hers can see. After we have reached the threshold, I'm going to just increase these two all the way up to ten. It's not going to hurt us anyway. So let's increase the radius, and here's CC. We are connecting these two points with this polyline. If I enable my point, now we have point out zero and one, we have this primitive. Favre to middle mouse button, this primitive has all of these attributes that we have onto these points. Fare to middle mouse button, we have bounds density and name, and we still have all of these attribute, Ire to middle mouse button, and Here's can C we are still keeping all of these attributes, which means this 0.0 will have an A value of box because 0.0 is a box, and the second point is spare. So the second point should store the name value of sphere. I can check going to the geometry spreadsheet and Here's can see. The first point we have box and the second we have the sphere. We are retaining the name attribute, and we have line between them. I can say that now I can use this line to set the constraint, and I can do so by adding the RBD constraint property one. So let's add an RBD constraint. Property RBD constraint properties, and let's add this. It has three inputs. The first one is for the geometry, but right now we are just working with the constraint. I'm just going to skip this parameter. I'm going to just connect this middle because the middle one is the constraint. Let's view this and here we have the constraint. What this constraint property node will do, it will just create some attributes and it will create constraint name attribute. Constraint name, we are creating the glue constraint. All of these attributes, this RBD constraint name attribute that this node is creating, all of these attributes, they are understandable by this RBD bullet solver. Here's can see we have the input for the constraint. I'm going to just move this onto this side. And here we have the option for the constraint, which means we can connect this in here because that is the output that will output the constraint. We are using the constraint. So we have this attribute. We have the constraint name. If we have the glue, which means the RBD bullet solver will say, Okay, so these two objects are connected with the glue constraint onto the constraint. Sorry, we enable the constraint properties. We also have some other type of constraint. We have the hard constraint, we have the soft constraint to change this to solve. It will just change the name to solve, and this bullet solver will know that, Okay, so now we have the soft constraint relationship. I'm going to change this to glue. We have the strength value. If I were to middle mouse button and Hearers can see, we have the primitive attribute. We have the constraint name and impulse of life and all of these strength attribute that we can define from here. We can play around with these perimeter. This bullet solver will look for these points that are available onto this polyline to actually view this point, we need to add an Null and visualize this middle and Heres can see, we have these two points, and it will look for these two points, and it says, Okay, 0.0 is referring to the box, and Heres can see we have the box. This constraint is referring to box, and the second point, it is referring to sphere, the sphere. And in between them, we have connection, and the connection is the glue connection because we are saying glue, and it is an a primitive attribute. So now we should have relationship in between them. So we need to go back onto the very first frame. Let's go back. Here can see py zomine I can see the constraint on the bullet solver itself. I have the line that is going through, which means that our constraint has been important. Now if I hit play and hears can see, both of these, our geometry has been connected together, and we are gluing them together. It is an glue constraint, and it can also be broken. I can go into the orbity constraint, and I just need to low down the strength value and if I were to load the strength value to one, and hit play Heirs can see because of the impact is harder than strength of one, the constraint has been broken. Right now they are staying together, and now the constraint has been broken. I can change the strength. Maybe, let's change this 25 and it play, and it's still breaking. I'm going to change this to 15, and it play still breaking. Let's keep adjusting this 200. Okay, I think I need to just keep playing around. Okay. Now it's breaking always. Okay, now it's not breaking. I think it's actually hitting pretty hard. That is why we need the more strength value. But you know that these constraints can be broken if the force is greater than their glue strength. We have the other constraint type. I can change this to soft, which means that we have the soft constraint relationship. And right now, heros can see we have this with the soft constraint, they are first colliding together, and that is because of the rest length. If I go into the RBD constraint, and that is our constraint geometry, and if I were to middle mouse button, and here is can see, we do not have our rest length attribute, and to actually make the rest length attribute, we can go into the connected adjacent and we have the length attribute. Let's enable this, and it will create the rest length that will store the length of this line. So the soft constraint needs the rest length to know how far these objects are placed apart. Because we do not have the rest length, let me escape to cancel this because we do not have rest length if I were to disable this. If the rest length is not present, this bullet solver will use the rest length as an a zero. If the rest length is zero, which means that they are trying to pull together and to actually keep their Tristans, I need to go to the connect adjacent and enable the rest length, and it will just to the length. Now we should see these constraints accurately and hers can see. Now we have the soft constraint relationship between them, and I can create my own manual rest length. So after the connect adjacent pieces, maybe let's add an attribute create known and I'm going to connect this in here. And I want to create an A floating, and it should be on the primitive level because, you know, all of these attributes must be on the primitive, not on the point level. So let's go into the attribute create and I'm going to change the class to primitive. I'm going to just copy this name, rest length. Let's copy this, and let's go into the attribute grade and onto the name, I'm going to paste this. I'm not let's not use the length attribute in here because we are creating this ourself with the attribute created. And right now it's value zero, which means we should see the same effect. All of these will try to snap together because the rest length. Let's maybe adjust the strength. We can adjust the strength by playing around with the stiffness value. So let's increase the stiffness so that we do not have this breaking effect, and hers can see now they are trying to match their zero position because of the rest length, and we have the forces fighting together. They both of them are fighting together. I can go into the rest length. I can say, Okay, so you are five units apart. And now they will try to push them apart to keep the five unit length. And if I were to play, and hear us can see. By default, they are too close and when they simulate and it says, Okay, so it should be five unit apart and let's it play and it's doing that. I can go into the rest length and I can lower this value down to one and let it play. Now they are trying to keep their one unit length. That is the basics of how this constraint works. Now let's see of Vn fracture. This one fracture node is creating the constraint for us. If I were to view the constraint geometry, and here's can see because we are working with a lot more points. We are working with a lot more connected pieces of geometry. And heres can see if I just select this, going to the primitive and heres can see we have many, many pieces. And this constraint, we are connecting all of these pieces together. So all of these lines, they are just trying these lines has been drawn, and they're going through all of these pieces. And if I were to low down the number of particles, we should see less lines. And here's can see because we have less connected pieces of scattered geometry or the fractured geometry. We are creating I polyline. These points are connected together. We have the name attribute, if I were to middle mouse button, and Hers can C we have the name. And this name, if I go onto the point, and this name is storing that this point number 1.0, it is referring to piece zero and its second point has been connected to piece one, and piece one is connected to two and three and four, and all of these pieces are now connected together. And that is why we have this connected mesh. And which means I can increase the number of these points to create more fracture. Now that we have constraint, let's import them in our simulation. First, I'm going to create the RPD, bullet solver in here, and connect this. And right now, let's enable the ground plan by going to the collision and let's add the ground plan. And right now it is falling. I can import my glue constraint, and first, we need some properties in here onto the glue constraint because right now, do not have the glue constraint primitive properties. If I were to middle mouse button and rows can see, we do have the rest length, but we do not have any information that is required by the bullet solver. And to actually add this, we need the RBD configured constraint properties node. So let's add an RBD constraint property. Let's add this need to connect the geometry, and it is not required. You can actually use this connect this and connect this, and it will also work. But we can actually connect this in between, and what that will do, it will just pass through our geometry. And that way we can make our network clean. All of these first input, this geometry, it is just going to pass through. And if I were to view this and here you can see, we have our fractured pieces connect this, we have the same geometry. We have the constraint and we have this. It is going to pass through them. But we can define the properties. We are creating the glue constraint and we have the strength. And now we need to pack this. I'm going to add the RBD configured known and it has all of these same inputs which mean I can just connect this and it will also just pass through all of our geometry and constraints. Let's go into the bullet solver, and this configure is going to pack our geometry. And now because we have glue constraint, now our wall is not falling because they are now glued together. I can go into the constraint properties. I can lower down the strength value and let it play. Let's keep lowering the strength value down. I'm going to just maybe increase this to 100 and Hears can C. We have the fracturing happening. I'm going to increase the strength. Maybe let's introduce an e collider. And same thing, I'm going to add an a sphere as an collider. I'm going to use the primitive sphere. Let me template this geometry and let me adjust its center. Sorry, not. We need to adjust its Z. And also, I'm going to lower down the uniform scale. Move this a bit up. We need to create the attribute because, you know, by default, we are choosing this piece prefix. I can either add my own prefix, let's say, add an A wall. And now, which means I can add the RPD configure, and it will pack our geometry and it will work. So I can add an A merge node, and now we need to merge both of our geometry. I want to merge this geometry and this geometry. And now that is our geometry, and we do not have constraints, so that is just empty. Let's go into the bullet solver and hit play right now it is falling down due to gravity. But what I can do, I can add an A initial velocity onto my sphere. And to actually at the initial velocity, we can add the point velocity node in here because all of the point velocity point attributes will going to be used by this bullet solver. So in here, I'm going to use the point velocity. But this point velocity node will do, it will create the V attribute, and here can see we have the V, and that is used for velocity. And if the V is present, this bullet solver will use this as an A initial velocity. Onto the point velocity, I'm going to right now it compute from deformation, I'm going to say set two value. I want this to move onto my Z axis. If I take a look at my origin nomen and Hers C C, I want to add the velocity on the Z onto the minus. I'm going to start with minus one. So we have some initial velocity. Now if we go into the bullet solver and it should move and Hears can see it is moving. And right now, I think my sphere is too big. I'm going to go into the sphere and let's lower down its scale. Let's play again, right now, minus one velocity is too low, so I can go in here and I can increase the two minus three. Now we will have higher velocity. I can change this to minus six and hers can see. Now we have our wall and it is falling. Let me contemplate this let's go into the RPD constraint properties and let's lower down the strength because right now because we have very high strength, all of our pieces are glued together and glue constraints are not being broken. So let's go into the strength and let's lower this value down and let's hit play. And it's still not breaking. I'm going to lower this value down even further. Okay, let's keep loading this value down. I'm going to maybe let's change this to 100 and let's it play. And now hers can see it is breaking. And maybe let's also go into the point velocity. I'm going to also increase the velocity scale. I'm going to let's give a very high initial velocity, and let's play, and there you go. Now, this sphere is breaking this wall. Maybe now we can increase the glue conenstrain this strength, I'm going to increase this to, let's say, value of 300 and let's play. And heroes can see we have a higher strength value. So these are the constraints, and that's how you can create constraints. 57. 57 RBD Activation: Now let's take a look at the RBD activation, how we can animate our RBD activation attribute to create an crumbling effect. And right now, here, if I hit play, and here you will see our wall is falling and I don't want that. Let's fix this falling wall issue. And to fix this, we need to go into the RBD configure and maybe I'm going to just duplicate all of the setup that is our basic setup. I'm going to just duplicate all of the simulation network onto the side and let's play around with these settings. First, let's go into the rbicanFgure node, and we have the option to enable the activate. Let's enable the activate, which means that right now all of our simulation is active. We are saying this activate to one. Nothing will happen. Sorry, nothing has been changed. If I were to hit play, we get the same effect. But onto the Arbitican figure, we also have some other option right now they are cutting off. We need to make this parameter bigger. And here is can see we have the option to enable the use bounds. Let's enable the use bounds option, and right now, I cannot see the bounds. Let's go into the RBD configure and let's view the RBD configure so that we have the guides activation guides. And right now, I still cannot see my guides. Let's scroll up, and in here we have the visualization. And right now, visualization is set to none. Let's change this to active. And now we can see the active. Right now, all of our vol geometry has been inactive, and that is because of the use bounds node. The bounds, we can control the bounds if you come over here. It says bounding type. It is expecting the bounding geometry, which means we need to plug the bonding geometry in here. And if I were to hover over to the inputs, the last input is for the static bound, which means we can create our bonding geometry or we can go into the ArbiticanFgure, and onto the bounding we can change this to bounding box, and it will create an a bounding spark geometry. And in the viewport, the box has been visualized. I can increase the bounding box size, and some of these fractured pieces are turned into green. All of these green means that they are active, and the black means that they are inactive. I'm going to play around with the bounding box. And if I were to hit play, let me activate my camera view again. Let's go into the bullet sol. And here you will see that our wall is not breaking, and that is because let me change the visualization why it's not visualizing, we need to go back at the very first frame, and maybe we need to activate the manipulator, and now we have the visualization back. All of these black mean that they are inactive. When the ball hits the inactive, the ball still collides, but they will not move because they are inactive. But I want the reverse effect and to create the reverse. First onto the bounds, right now, we have the bound. Going to say that all of these are these geometry pieces that are in the bounds, let's not make them active. Onto the activation, I'm going to change this to zero. And now we are creating the reverse effect. Now, all of the geometry that is outside of the bounds, are going to be active and onto the bounding box, we have the black pieces. These blacks mean that now they are not active. They will still act as an ecldr. They will still be in this simulation, but they will not be affected by any forces, which means I can go into the bullet solver, and now this ball will going to break this wall, and heroes can see. Now our wall is not falling because we are basically pinning out this base geometry. And because we have this constraint, and if you do not add the constraint, if I'm going to just, let's say, bypass the constraint node, and right now it is throwing an error. We need to remove this constraint geometry in here. And if I hit play and I'm going to visualize this bidiconfgure node, here as you can see we still have the same active. The greens are active and the blacks are inactive. Which means that all of the green wall will going to be fall apart, and hers can see. Our green pieces has been falling apart, and all of the pieces that are inactive, they are just staying there, and they will just only collide with all of our simulation. When we have created the glue constraint, let's add the glue constraint and connect this onto this constraint geometry. The glue constraint will going to hold all these pieces together. Let's go into the bullet solver again and let's see the result, and here you will see. When the ball hits, if the force is greater than the breaking threshold, if I go into the RBD constraint properties, here we have the strength. If the hitting threshold is higher than their constraint strength, these constraints will going to get broken, and we have this breaking wall effect. And maybe let's animate this activation attribute. Right now, we are using the static activation by using these bounds to better understand this active. Let's not use the constraint, and for that, maybe I'm going to just create another example onto this side. To create this, I'm going to create an squab geometry. Let's set our lovely squab same thing, I'm going to just move my scab geometry a bit up and I'm also going to rotate this so let's fracture this squab geometry and for fracturing, we need to scatter some point. For scattering, first, I'm going to convert this into volume by adding the ISO offset. Let's connect this onto the IO offset. Let's increase the uniform sampling to create a more high resolution of our fog volume. Let's add an Scatter node, now we will going to be scatter points onto the inside of our geometry as well. Onto the scatter maybe let's uncheck this relax iteration option. Now I'm going to use an Everno fracture node. So let's add an Everoi fracture. That is the geometry Me to fracture, and these are our vornoi points. Now we should see the fracturing and right now it's calculating. And once it's done, we should see the fractured, and our squab geometry has been fractured. I can confirm by adding the exploded view node in here. Let's add an exploded view, and let's view this, and here can see we have our fracturing going on. Now let's pack our geometry, and for packing, I'm going to use the RPDcanFgure node because we have the name attribute. If I go into the Vern fracture, we have the piece attribute. You can define your piece prefix, and by default, this Verne fracture will create name attribute. We just need to connect this onto the RBDcanfgure and RPDcanfgure will use the name to pack our geometry and after packing, we are working with points. If I were to middlemuse button, hers can see we only have 1,000 points because now we are packing our geometry. Now let's create our activation attribute, and to maybe better visualize our active attribute, I'm going to say extract all points, which means I want to remove all of the primitive these pack primitive, but I'm just going to keep the points. And here we have our fractured points. And let's create our activation our growth activation attribute. And for that, same thing, I'm going to use this sphere. Let's add an primitive sphere because we actually do not care all of the mesh geom tree. And after that, maybe let's add transform node, and let's template the transform. Let me template this, select the node and press Enter in the view port, and I'm going to place my sphere in here. I want to start the activation from here. Now we need to create the active attribute. We can create this onto the Arbutcanfgure. I'm going to just enable the active and by default, I'm going to change this to zero. We have all of these pieces inactive and onto the side, I'm going to create an active, another active attribute, let's create an attribute. Create node. Let's connect this and onto this one, I'm going to say I want to create an active attribute. Let's type the name of the attribute and it is an A float and I'm going to change its value to one. Now let's transfer this attribute. We can do so by adding the attribute transfer node. Let's add this, and that is the geometry. First, maybe let's use these points only, and let's connect this in here. Let's go into the attribute transfer and check the primitive, but let's only define the active. Let's go into the condition, and now we just need to animate this parameter. And right now, I cannot see my active. So let's add an A visualizer so that we have some visualization. And to create the visualization, let's click on this I button. You can click on any of these attribute, and Heres can see, we have this switch, and that will just create an A visualizer, and I'm going to just visualize my active. Let's click on it and Hes can see. We have the visualizer added, and all of the red points are active and all of these purple points are inactive. Let's go into the attribute, Transfer node, and let's animate this parameter. And first, I'm going to add an A key in here. We will start with the zero. Let's go few frame forward, and I'm going to keep adjusting this until we see all of our point active and we have all of our point active. Let's add another key, press and hold the hold key and left mouse button. Let's scrub our playbr and here we have our animated activation. Let's hide the visualizer and we can do so by clicking on this eye button. Let's click on this button again and that will just not at the visualizer, and now we are not visualizing it. Let me template my transform node, and by the way, because we have all of these animation, we can just go into the transform nodes select this press Enter, and you can place spare anywhere, and it will going to start activating from that location. If I were to enable my active now we should see that our activation will start from here. And same thing, I can just click and I can place it anywhere I want. I can maybe start the activation from there. Let's scrub playbr and here is can see. It is very procedural setup. I'm going to just undo this and place it the way that it was. I want the activation to start right here. Let me hide the visualizer, click on this and uncheck the active. Let's contemplate this. That we have, we know that this visualization work. We don't need the extract all points. I've just added that so that we can visualize because when we have the primitive, the visualization doesn't work correctly. And if I were to add the visualizer now, let's click on it and let's click this and here is can see. Even though we have visualizer added, it's not going to be visualized because of these packed primitive. And that is why I added the extract all points just so that I can visualize. The attribute is there, it's just not visualizing. Let's click on it, and let's uncheck the active to hide the visualizer. Now that we have the animated active, let's create our bullet solver. Here, I'm going to type the RBD bullet solver, and that is the geometry that I want to simulate. And now we do not need to add the constraint because we are not going to use the constraint, but we're going to be activating our geometry with the active. Let's sit play. We need to rewind and let's play. And heroes can see all of our changes this active animated attribute is not going to be imported into the RBD bullet solver. I can go into the properties. Hers can see we have the active attributes, override attributes enable, and here we have it active. Even though it is listed in here, it's not going to be imported every frame, which means all of the animation that we have just did these animation, they will not going to be updated. The bullet solver will going to be initialized, all of these attributes, if I go into the arbiticanfgure. All of these attribute is going to be initialized at the very first frame. Then the simulation will take care of the rest. To make this active attribute resent to update this active attribute, we need to actually import this inside of the bullet solver. Let's tie inside, and now we are in the dynamics and we are in the forces, and now we can add an a geometry p node in here. Let's add an geometry wb and here we have it. Let's add this and we need to connect this in here. Now, this geometry wp node will going to be calculated every frame. Mean we can dive inside, and let's import our active attribute. And we can do so by saying Import point attribute. Let's add an import point attribute. Let's go into the import point and we can define the file if we want. Or I can just use the context. I'm going to use the up input one. I want to import the active attribute, and that is an float attribute. Let's change this to float and let's type the attribute name, and I want to input the active and let's also write this attribute out by adding the bind export nude. Let's a bind export node and connect this. Let me connect this and let's write out this as an active. We have exported this, but this attribute will not going to be important, as you know, because onto the geometry b, because we are in the dynamics, all of these obs, their inputs must be defined. Let's go into the inputs onto the parameter of the geometry b node itself. Let's go into the inputs and onto the input first, which means that because we are using this p input one, we need to define the input in here as well. I'm going to use the sap node. I'm not going to use the first context. Let's go back. Maybe let's see because we are using the first context input one, let's see if this work. And let's go back and hit Play. Here is can see it is working. And now I can go into the bullet solver, and let's go into the collision tab and I'm going to add the ground plan. Lets it play again. And now we are activating our these bullet simulation without this attribute, and all of our fractured pieces of geometry is falling apart. And I can go into the transform node, press Enter, and let's say I want to start this crumbling effect from there. I just need to place this. I'm going to use this handle and place this in here. Now we'll see that they will going to start crumble from here, and here us can see. And I can move this at this into this location and let it play again, and now we have our crumbling effect. That's how you can animate and import your activation attribute inside of the bullet solver that is available on the sop. 58. 58 Vellum Basics: Now let's talk about Valum solver. Valum is used to create the soft paddy simulation. Valum can also be used to create the grain simulation. Valum is basically the continuation of the pop grains pop grains that we talked about. Let's see al how we can configure velum grains to create soft paddy. Going to create an A jom tree node in here empty geometry container, and let's dive inside, first, I'm going to create an A cloth simulation. For creating the cloth, I'm going to add an a simple grid. Let's add this and I'm going to lower down its overall size because right now we have a very big size, and you know that Houdini works in meter, and right now we are working with a very big cloth. I'm going to just change this to some lower value. Inhere, we need to create an A Valum constraints. Because it is an granular simulation, as you know, we have created an a pop grain node if I were to add the pop grain source. Sorry, because we are in the geometry, we have this grain source and not the pop grain. Let's add the grain source onto the grain source, and in here, as you know, right now, all of our source is gone because it is expecting a solid mesh. And if you are working with these thin meshes, I can go into the mode and change these two sheet. And now we are scattering bunch of points, and all of them has scale value if I were to enable change these two lid sphere, and here I can see that we have all of the particles with the scale value. To actually make all of these points connect together, we can create the constraint. If I enable the explicit constraint to better visualize the constraints, I'm going to make the visualization two points. Let's come over here and change the visualization two points. And now you can see that we have these lines. All of these lines are basically they are connecting these grains particle, and right now some of them are not connected. That is because of the search radius. Let's increase the search radius, and as I continue to increase here as you can see, we are creating more and more constraints. And all of the grain particles will going to be connected through these constraints to create the soft body simulation. Valum is work just like that. If I were to create an A valum node, I'm going to hide this point display. In here, I'm going to add an A Valum constraint node. To create the valum, you must start with the valum constraints. Let's add an valum constraint node. Let's set this and connect this. That is the geometry that I want to convert this into Valum geometry. Let's view this. And right now, nothing has happened. We can see some of the mesh. Now our mesh got triangulated, and that is because of the visualization of the constraint. But if you take a look at the geometry, I'm going to create an null in here and attach this and let's view the null. Right now, we are passing through our original geometry. The middle one is creating the constraint. That is what's important. Let's view the constraints, and now we can see the constraint. Now, what the Valum constraint is doing, it's not scattering points as we had with the grain source. If I were to use the grain source, and at this, you know that with the grain source, let me change these two sheet, we are basically scattering bunch of points, and we can control them by lowering down the number of points separation. Scattering points onto the surface. But the velum constraint node, it's using the points from your input mesh. If I enable my points, you know, we have all of these points. Now, the velum constraint using all of these points as grain particles. Now it thinks that these are the grain particle. Let's not scatter more points, but use the original points as grain. And in between them, all of these, we have the geometry, these edges, these lines. It will use these edges as an e constraints. Right now, we are adding more constraint, and that is because if we go into the velum constraint, we have the triangulation. And right now, it says alternating. I can change this tonne. And now you can clearly see that we are not adding triangulation and we are just straight using all of the edges that are actually present on this mesh these edges. Now these will represent as an constraint. I can go into the Valum constraint. Let me enable the parameter. And we have all of these particles. You know, that all of these granular they need the P scale, and this Valum constraint is also setting the P scale, and we can visualize. Right now, we are using the Tristans along edges constraint. And if you type in here, another constraint, I'm going to type an Valum configured cloth. And here we have the Valum configured cloth. If you add this, it is still an ASM Valum constraint node. Here you can see if I enable the parameter, here it says Valum constraint, if I enable its parameter, it still says valum constrained. It's just same node but it's just configured to the cloth preset. I can go into my original constraint that we just created Valum constraint. Let's enable its parameter and the constraint type. Let's go in here and here you can see we have several different types of the constraint. I'm going to change this to cloth. When you change this to cloth, it will just add some attributes to all of these edges. These edges will going to be converted into constraint, and we are going to be simulating solving these constraints over time to create the soft party. Now I want to visualize the thickness of these points because now they will going to be grain points. I can visualize them onto the thickness. Let's change this to set. Uniform value first, we need to add the thickness. Right now we are using the thickness of 0.01. And now we have the visualized thickness option appeared. Let's click on it, and Hears can see. We have the scale visualize, and if I were to increase the thickness, and Hears can see, we are basically increasing the P scale of our original points mesh. I'm going to change this to 0.01 because we have the constraint between them, and these edges, these constraint will going to hold all of these particles together. We are going to simulating these constraints and they will keep apart their tristans. Now, all we need to do is add a valum solver. Let's go into the Valum constraint and I'm going to uncheck this visualized thickness. Let's add A valum solver node. Alum solver, and it has all of these three corresponding. I'm going to just remove the valum cloth. Let's connect the geometry and the constraint, and maybe let's connect this last one that is for the collision. Let's view this, zoom out, and let's hit play. And here you will see our cloth is falling due to the gravity. Let me hide the point display, and I'm going to just move my grid up. Let's change center and move this up, and let's add something so that we have something to collide with. I'm going to add a simple spare nol in here. Let's add an epolygonal sphere, and I'm going to connect this onto the last one. The last one is for the collision geometry. Connect this in here and it will going to be passed through, or you can connect this in here. It's the same thing. Whichever way you want to connect it because the last one is for the collision and it's going to be pass through from all of the nodes. I'm going to just connect this in here for the sake of the arrangement. Let's go into the Valum solver, and let's sit play. And here is can see. We have our cloth simulation, very basic close simulation. Let me enable my real time, playback. Let's sit play again, and there you go. Valum work best when you have the triangulated mesh. Right now we are using these regular grid, if I were to continue increasing its rows and columns because, you know, if we want to pick up more details, if we want more wrinkles in our cloth, we must need the resolution. Let's continue adding more resolution. And if you take a look at the Valums solver right now, it's looking smooth and I cannot see much of the problem by using this regular method. And right now, we have this cloth stretchiness, if you take a look, we have our cloth that is stretching a lot, and I can adjust its property, its stretchiness property by going onto the valum constraint because that is the no responsive for setting all of the physical attributes. Let's go into the Valum constraint, and down here, we have the option stretch. So the cloth constraint is made out of these two constraints. We have the stretch and we have the bend constraint. And stretch onto the stretch, we have the stiffness, and in front of it, we have the multiplier. We are multiplying this value by trend, which means that basically we are creating an infinite stretch stiffness. I were to lower this multiplier down, let's say if I were to lower this value down to 0.1, which means that you know that one is going to be multiplied by 0.1, and it means that the stretched stiffness is going to be 0.1. And now if I were to hit play and hers can see because we have a lot more stretchiness, all of our simulation is breaking. Maybe let's lower this value. Increase this higher value to 100 so that we have somewhat stable simulation and Hers can see. Because of the low stretch stiffness, our cloth is stretching a lot. Let's change this to infinite. Even though we have the infinite, I can still see some stretchiness, and that is because we actually need to increase the number of substeps. As you know, whenever working with grains and this valum solver, it's basically the continuation of the grain. It is also called the PBD, and the pop grains are called PBD. So the PBD is an newer research, and it is a continuation of the pop grains. And basically, it's just an A grain simulation. And to, you know, grains, we need to increase the substeps. In here, we have the constraint iteration, and right now we are using with one substeps. Let's increase these two, five substeps. Let's start with that and let's play. And now we should see somewhat accurate result. And I can still see some stretchiness. And that is because it is now coming from this regular geometry arrangement. Whenever you are working with soft bodies, whenever you are working with Valum, it is best to triangulate your mesh. Valum work best onto the triangulated mesh. And to actually create this triangulated, we have a node called remesh. That's said remash node, let's connect this. And what this remash node will do, it will just convert your input mesh into triangles. Let's bring up the parameter can increase the iteration, and that will just even out the triangles. And I can apply some smoothing in here and to actually add more triangle, we need to lower down this target size. And if you lower this value down, basically, we are creating more and more triangles, more and more smaller triangles. And same way, if you were to increase this size, we are basically creating bigger triangles, and they will going to be less triangulated mesh. Going to lower this value down to create a reasonably high resolution mesh. I think that mesh is looking fine. Let's connect this in here. Let's go into the valum constraint, and let me go back and let's change the triangulation method to default, which was the alternating. Now that we are working with the triangulated mesh, let's go into the Valum solver again and let's see. Let's play, and now it is calculating and hers can see. Now we do not see the stretchiness. Now our cloth is behaving accurately. And it is always recommended to use the triangulated mesh. Let's go into the Valum solver, and now I think we do not need the five substeps. Right now, I'm going to change this to one and let's hit play. Here can see our simulation is still accurate. Let me go into the grid, and maybe let's increase our cloth size bigger. And right now this visualization looks weird, but let's view the Valm constraint and let's view the velum solver again. Let's play it is an triangulated mesh, but right now it's just visualizing as we have our quad plane. Maybe let's refresh our viewport. Let's go into the animation editor, and let's go into the scene view again. And it's still not refreshed. Maybe sad and null in hair. And I'm going to view this with our mesh. It's still not. Let me see. Okay, no, it was visualizing correct, but remesh is creating these smooth triangles. I thought that it was a viewport problem, but that is the our mesh. That's how our mesh looks like. Let's go into the remash because we have changed our size, I'm going to lower down its iteration to the default. Make all of these parameters to the default, and let's lower down this size. And by lowering this down, hers can see we start to getting more triangle. And now we have the good triangulated mesh. Let's go into the Valum solver. Let's go back and hit play. Now because we have added more triangles, now I can see a lot more wrinkles and lot more folds in hair, and we are picking up all of our details in here. Now I can go into the Valum constraint node. Let's come over here onto this stretch. Now if I were to change this stretch, if I want my cloth to be stretchy, can just lower this value down. Let's change this to maybe 1,000, and let's hit play, and hers can see we have reasonable stretchiness. If I were to change this to 100 again to the default values, and I think the 100 value is just too low and our simulation is just breaking. Let's change this to an infinite, and that is the stretch stiffness. And down here, we have the option for the wend stiffness, and that control how much our cloth is allowed to wend. And here you can see our cloth is bending, all of these constraints are bending, and that's creating this cloth like simulation. And if I were to increase the stiffness, right now, we are using the 0.1 value. We were to increase this, here you will see that our cloth will act like as it is made out of metal sheet because it's very hard to bend. Let's play, and hers can see. We are still getting the wendiness even though we have the very high value of stiffness, we are still getting the bandiness and that is because whenever you are working with these very high value must go into the Valum solver and increase the number of substeps. I'm going to increase the number of substeps and let's hit play one more time. And here we will see the difference, and Hears can see. Now we have animation that looks a lot more different. We have the simulation that is much more different. Let's hit play again and heroes can see. I can increase the constraint iteration. Let's maybe increase this iteration to and a very high value, and let's hit play. And the simulation will take longer to simulate, but we will get an accurate simulation, and hers can see. Now this sheet metal sheet is bending and it's acting like we have this metal sheet. And because we are working with very high bend stiffness onto the Valum cloth, bend stiffness, this material is very hard to bend. Same thing if we want to create the cloth, we need to lower this value down. I'm going to lower this down to 0.1 because it is an ecoloth. It should be easier to bend. And because we are working with cloth, let's go into the Valam solver, and we do not need that many substeps. Let's change this to one. And the constraint iteration to 100, both of these values are just fine. And we have our very basic cloth simulation. 59. 59 Vellum Soft Body: Now that we have the basic understanding of valum solver, let's see how we can use the Valum solvers to create the soft parties. And right now we are using the valum to create the cloth, let's take a look at some other parameter that we had. Right now, we are using the simple grid and we are using the remash node to make this triangulated cloth or piece of cloth. In here we also have node called planar patch. If I were to add a planar patch, here we have the planar patch. Let's add this. This planar patch, it is still an a simple grid. If I were to enable the parameter of the planar patch, maybe let's decrease its size and at the very top, we have the orientation. We can orient our piece of cloth onto the right note, it says, XY, I can change this to YZ or Zadax. Let's maybe change this to XY. And it's not something special. We can create this onto the grid as well. We have the grid, and here we have the orientation. I can change this to YZ and XY we have all of the orientation. To our grid as well. And we can also convert this into this triangulated mesh by adding the mesh node. And heres can see we have the triangulated mesh. But what's special about the planar patch node is it will create this grid and triangulate this, but also it will create some of the points group for us. Right now, we do not have any groups if I were to metal mouse button, and here as can see, we do not have any groups. Let's say if I want to pin my these side points. If I were to enable my point display, I can go into my point selection, enable the selection. Let's say I want to pin my this point. I can do so by going onto my grid and onto the remash node. But what I had to do, I will have to just select all of these points that I want to constrain. Let me activate the selection. I need to draw selection and put them in a group and we will going to use these points to pin. But onto the planar patch, we have the option to output all of these side points into group, and we can do so. If I go into the planar patch, we have the option for the left seam. And if we were to enable this, it will create an A group, and it should be toolsineOs and the left. DolineOS means the planar patch, and after that, it will just add an A left prefix if I were to middle mouse button, and here is can see we have a one point group planar patch left. It will store all of these left points, and I can even adjust how many points I want onto the left side. If I were to enable the left points, I can control exactly how many points I want onto this side. And if we zoom in, and here you will see all of my points are adjusting according to this left points slider. Same thing, I can enable my right seam group and that will all of our points into an a separate group, I can enable top, SEM, bottom, SM, all of these. I have access to all of these groups and they are procedural groups, which mean if I were to add more triangles, let's say if I were to add more triangle by lowering down this edge length, these left seam group will still going to output all of the points onto the group. Mean I can use these points to pin my cloth. And right now, I want to pin these drop points. If I were to enable my selection, I want to create a group of these points. I want to create an pin constraint, and all of these pin constraint, I'm going to pin all of these drop points. And for that, we need to uncheck the left sim and let's enable this SIM group. And down here, we can add an A valum configure cloth because I want to configure this two as an a cloth. Let's go into the Valum configure and cloth. Let's add this and connect this. And it will just create the Valum constraint for us. Let me hide this point display we now only just need to add an A Valum solver. Let's add this and connect all of these nodes. Let me view the Valum solver if I were to hit play and here you will see it is falling due to the gravity, let's in all of these points. And we can do so by going on to the Valum cloth. Let me enable the parameter. We have the Pinto animation. Right now, pint points inher we can define our group. Right now, it is empty, which means I can type inhere the number of points that I want to pin. If I enable my point number. Hers can see if I want to pin by this 310 point, I only just need to type the point number. Let's say I want to pin that point, I'm going to just type in here 310, and now only this point will going to be pinned. Let me hide my point number and hit play and hers can see. Our cloth has been pinned to that point. What I want, I want to use my group that we have just created in here by using the planar patch. So let's go into the Vellum cloth. We have this group. Let's select this and let's play. And here as you can see now our cloth has been pinned and our cloth is hanging. Maybe let's go into the planar patch node. Right now we are using the rectangle, and I also have the option to change this to trapezoid and what that will do, we have this option to add an ASQ in here and we can add an A tapering effect. I can keep adjusting the size. I can change this to circular and I have the seam offset, I can control the uniform scale, and I can also change this to ring and it will just create this donut shape. And all of these top seam group, they will going to be procedurally added, if I were to hit play, and here as you can see our top points are now pinned. Same thing if I were to change this to let's say trapezoid and we have some of the taper and skewing going on, and if I were to hit play, all of these top point will still going to be fined because all of these seams group there are procedurally created, and that is the benefit of using the planar patch node. Maybe let's also add some wrinkles to our cloth because right now our cloth is hanging, but we do not get the interesting simulation, and that is because in here we do not have an n. Can create the wind. Let's go into the Valum solver, and if we go into the forces, we have the option to add an A built in wind. I can add an A wind right now. Let me take a look at the orientation. Let's say I want to add the wind onto the Z axis. Onto the Z, I'm going to, let's change this value to three. And if I were to hit play and heroes can see our cloth is blowing due to the wind. I can the wind speed, I can create a lower wind speed. Let's hit play and I can increase the wind speed. Let's play again, and here as can see. We have our wind that is now blowing our cloth, and our top point are now in wind. That is the planar patch node for creating your piece of cloth. Let's create an A Valm soft body, and I'm going to create a rubber toy geometry for that. Let's add an a rubber toy geometry, and I'm going to move this rubber toy geometry up. Let's add a translation in here. As you know, we need to convert this into triangulated mesh because Valm works with the triangle and to convert this into triangle, let's add remesh node. Let's add this and connect this onto the remesh onto the remash, I'm going to just lower down the size, and right now this material is breaking. Let's go into the rubber toy and let's not add the shader because we do not care about the shader. We just want to simulate this rubber toy geometry. Let's go into the remesh and let's keep lowering this value down. And that way, we can create a more high as representation of our geometry, and we have our high as representation. After the remsh, let's convert this into soft body, and I'm going to use an A Valum constraint Node for that, we can configure this to cloth as well. Let's use maybe let's use the Valum configured cloth reset. Let's use this and add this in here and after that, let's add an Valum solver. By the way, when you have selected the node, right now, I am selecting this Valum cloth node. The node is selected. When the node is selected, bring up your node menu and type the Valum solver. And if you type the node and you press Shift Enter, if I press Shift Enter, and what that will do, it will just connect all of these nodes to the selected node and set the display flag as well. And it doesn't have to be Warum solver. You can do so with any node. For example, if I were to add an spare node in here, and now my spare node is highlighted. Right now I'm highlighting the square node. And let's say I want to add transform node in here. Let's type the transform and press Shift Enter. And when you press the Shift Enter, it will connect this node in here, right now, the display flag has not been set it because this primary geometry has not been set it to the display flag, which means we need to set the display flag to this sphere. And now let's try that again. The node is selected. Let's type transform node. Transform and press Shift Enter. And now hers can see the new node has been created and it is connected, and the displayed flag has been switched to this newly created node. And that way, we can very quickly build this network graph. Let's go into the Valam solver, and let's play. And we have this rubber to geometry that is falling. Let's go into the Valum solver and maybe enable the ground plane. Onto the Valum solver onto this solver tab down here we have the option to enable the ground plane. Let's enable the ground position, and that will just add an infinite ground plane and let's set play. Hers can see we have our soft body simulation, and now it is an A cloth because we have set in our preset to cloth and to actually make this geometry preserve its volume to create an actual soft body because right now, Hers can see we have this cloth. In here we have another constraint that is called the Valum strut constraint. That's type velum and strut. Here we have the velum configured strut soft body. If you add this, it will create these two constraints. First is the Valum cloth that we are just using. This velum cloth will going to create this soft body effect, and onto the next one, we are also creating the strut constraint, and I can visualize if I just connect this in here. And maybe let's add an null in here and let's visualize this cloth constraint. Here we have the constraint that our cloth. Harros can see all of the input meshes. And to actually preserve the volume, this plum strut will going to add constraint onto the inside of our geometry. If I zoom in, Harros can see right now, it's actually a bit harder to see. Maybe it will be easier to see if I were to just add an a sphere. I'm going to add lgnal sphere. And onto the sphere, let's change this to primitive, sorry, polygons, you know that by changing the two polygons, we can triangulate our sphere. Let's increase the frequency, and let's connect this. And here is can see the inside we do not have any constraint. And this velum strut will going to be add constraint on the inside. If I were to view the constraint, the output from the strut, let me rearrange the null and connect this. And now hers can see we have some constraint has been added onto the inside. These inside constraint will going to be used to preserve the volume of hot am tree. And onto the velum constraint, here as you can see we are still using the velum constraint, but onto the constraint type, we are adding this strut constraint. First, we configure this to cloth, and then we configure this to strut. Let's connect this rubber to geometry, this re mashed rubber to geometry into this input. And I'm going to remove this fare. And now, here you will see that we have constraint on the inside and they are a bit harder to see, but we have constraint on the inside. And these instead constraint will going to preserve the shape, the volume of the soft body. Let's connect this onto our Valum solver. I'm going to delete this and connect this in between. All of these node, we need to just connect them, move them aside. Or maybe we should have created another Valum solver, but let's add this. We have the Valum solver and let's play. And here as you can see we are preserving the volume and we have the soft pdy effect. And I can control the strength of the strut and right now or the strut or weeks, and I can go into the Valum strut strut. We have the stretch stiffness. And right now we are using the very low stiffness value. We have the one and the multiplier. Let's increase the stiffness multiplier to a higher value, and now this geometry will going to preserve its volume and heroes can see. Now we are preserving its volume quite a lot. And right now, these shapes are breaking because we have all of these connected pieces and to actually fix this onto this remash node, we just need to create a single piece of geometry. And we can create this by creating an A VDB from polygons node. Let's add a VDB, first, we need to convert this to surface VDB, lower this value down 0.05 maybe or 0.0. Let's say I think that value is fine. And now we just need to convert this pack to our polygonal geometry. Let's add and convert VDB node. Let's add this and connect this and change these two polygons. Now we have our polygonal mesh pack. Now we just need to plug this into remash and that will just triangulate our mesh. And now we shouldn't see any of these breaking because now we are working with one single mesh. And we have the soft body. Let's say it's working fine. And right now to actually smooth out its animation, we are working with very low substeps. And right now we are working with one substeps. We need to actually increase the substeps and also increase the constraint iteration to create most accurate simulation. And right now, Harris can see our simulation is getting very slow, but we will get accurate simulation. We will have most accurate simulation. Here as can see now we do not have artifacts in there because we are creating more substeps if I were to play and it is accurate. I'm going to just lower this value down and I'm going to lower this constraint iteration down to actually save out this simulation time. Let's say that we are happy with our animation. We have this working soft pdy. And now we want to render this. And as you know, we always want to render our original high ras mesh. And I can add an shader in here because we are converting this to VDB, and all of the shaded information will going to be gone anyway. So let's add this shader. We want to render this because we have our material, our UVs, our this original mesh, and we are going to render this. Let's transfer this simulation that we have just simulated. Let's transfer this simulation information into this original mesh. And we can do so by adding the point of form node. And I'm going to just rearrange my node graph and let's see rearrange this. And I'm going to put this in here. We need to add an a point deform node. Let's add an a point deform. And as you know, point D form has inboard, the mesh to deform, and I want to deform my original his mesh, and it requires the rest point lattice, and for the rest point, we have the rest point geometry that is coming from here. And to actually make this as an rest frame, let's add a time shift node, connect this. And right now by default, this time shift will do nothing. It will just read our animation. Let's go into the time shift and onto the frame. Let's delete this channel to delete the expression. And now we are keeping only the one frame. So no matter where we are, if I were to play, we will always get the one frame. That is an as point lattice. I'm going to connect this onto the second rest point. And now the deforming and deforming are this original where we have this rubber moving. Let's connect this onto our deforming point and let's view the result. And now Heras can see this simulation has been transferred onto our original hiras mesh. And now this mesh is ready to render. And that is how you can basically create the VLM soft body simulation. 60. 60 Vellum Constraints: Now let's take a look at the different types of Valm constraint. As you know that Valm constraints are the primary driver of the Valum simulation. Valum constraints define the simulation behavior. Let's take a look at some of the different types of Valm constraints that are available for us to use. And I'm going to just copy all of the network that we have just built. First I'm going to just reorganize all of these nodes. And I'm going to put the re mash node in here, and I think we do not need the Valum cloth. Let's remove this. And I'm going to select all of these nodes. Let's not select this point to form. I'm going to just select these valum solver. Let's select and draw them onto the side to duplicate. Let's select all of these three nodes. Maybe let's first, I'm going to arrange this like so and then select all of them. Let's go into the layout and align those nodes vertically. Now let's remove this velum cloth and Valum struts. Right now we are using this cloth to create the soft body and strut is worth keeping its volume. Let me remove all of these constraints, and I'm going to create an a valumressure constraint. Let's type velum, and let's add sorry, the pressure constraint is called the alum configure balloon. Let's add an A Valum configure balloon. Let's add this, and it will create these two constraints. First, we have the Valum cloth constraint. Alum cloth constraint will give the soft paddy behavior. And the next constraint is the pressure constraint. And this pressure constraint is going to fill our geometry with pressure so that our geometry looks it is filled with air, and you can use this constraint to create your balloon type simulation. I'm going to connect this and let's connect. That is the geometry and constraint to constraint, and maybe let's pass through the collation geometry as well. Let's go into the Valam solver. And lets it play. And here as can see we have our simulation, and it looks as if it is filled with water or if we have the air. It will keep its pressure same. If you were to compress its side, it will going to preserve its volume. And to better explain this, let's add an collider in hair. I'm going to create a rigid collider and to create the rigid collider, first, I'm going to create my collision geometry. I'm going to create an cylinder type collision and the cylinder inside of dini is called the tube. Let's add this polygonal tube. Let's go into the geometry and let's change the orientation. I want to orient this onto the X axis. Let's increase its height, and let's increase its center and let's move this geometry up. And to make this geometry as an A rigid type constraint, we have constraint called Valum shape match. Let's add an A Valum shape match. And if you type velum shape, here as you can see, you cannot find the preset of the Valum shape. We can add an A valum constraint node. Let's type Valum constraints. Let's add this, and I'm going to connect this. To the Valum constraint, we have the constraint type. Let's select the shape match constraint from here, and that is here we have at the last shape match. Let's select that. And this constraint will not allow the traformation on our geometry. It will try to keep its original shape, and that will give us the rigid body effect, create the rigid constraint. Now all we need to do is just to merge both of our geometry streams. Right now, that is another source and that all of this is another source, and we need to just plug this into Valum solver. And to add this, we need to create an merge node. And because we are working with the geometry, first, we need to merge the geometry, both of them. I'm going to merge this first, our soft party geometry, and then I'm going to merge this slender geometry, and now that is the geometry. Going to move this down and let's plug this. Now, that is our new geometry, and same thing, now we need to merge the constraints. And for that, let's create another merge node, and let's merge this constraint and this constraint, and let's connect this into here. Now, that will be our new constraint geometry. Go into the Valum solver. Let's hit rewind so that we have the update our Valum solver, and let's hit play. And errors can see this is falling. This cylinder is falling. And here you will see that this geometry will going to preserve its volume. It's not going to lose its volume, and it will create an effect as if we have this geometry filled with water or air, and we can actually animate its parameter right now we are using the pressure constraint, and onto the valum pressure, we have the rest length scale. If we were to increase the rest length scale, that will just inflate our geometry. If I were to increase this value, I'm going to just increase this to 1.7 and let it play. And here as you can see we have our geometry inflation. And when the cylinder fall, here you can clearly see that this geometry is preserving its volume. It's not losing its volume. Let's dynamically animate this wrestling scale and to actually animate this, we cannot animate this parameter. As you know that all of these sources, all of these that we are creating that constraint, all of these properties will going to be initialized first at the very first frame, and then all of the changes will have no effect. Which means if you were to try to add an A key frame, I'm going to, let's say, start with one onto my valmPressure constraint. Let's add an A key, and I want to go few frame forward and I'm going to just increase the pressure value and let's add another key. Let's go back and hit play. Here you will see these animation are not getting imported into our Valum solver that is because all of these parameters they will going to be initialized at the very first frame and then simulation will take care of them. To actually make them animate. Let me delete the animation from here onto the wrestling scale. Let's right click and let's delete the channel to delete all of the keyframes to actually animate all of these constraint properties, we need to dive inside the Valum solver. So let's dive inside. We can add the forces, and we have the sticky nodes. We can also use the particle forces to apply the forces. Or we can wire the Valum constraint properties and all of them into the force as well. We have an node called Valum constraint properties. Let's type that and here we have the Valum constraint properties. Let's set this and connect this. If I enable the parameter, here you will see all of the properties that are available onto these almost all of these constraint. We have the rest length, the stiffness, all of these constraint properties. You can actually adjust them dynamically into the Dub net. We have this Valum constraint property node. And to create the inflating and de inflating, we are going to animate the rest length scale. We have the rest length. Rest length means that we are manually setting our geometry rest length. And right now these edges, these are its rest length. By manually setting the rest length, it will create some problems I like to do, I would like to do the wrest length scale. This rest length scale is a multiplier, which means we can use this slider to multiply our incoming rest length with the scale. Let's use this to animate. First, we need to define which rest length scale we want to animate. If we go into the geometry. You know, we are working with multiple constraints. We have the cloth constraint, and it too has the length alum pressure, and it too has the wrestling scale. Need to define that which constraint we want to animate. And if we go into the valum shape match, and we should see in here, I think the valum shaped match does not have the rest length, but it is another constraint type. Go into the Valum solver and into the valum constraint. We need to define that which constraint that we want to import and to actually define that, we need to go into the valum constraint and we can see that if we go into the stretch, here we are outputting the groups. If I were to middle mouse button onto my constraint geometry, middle mouse button, and here you will see we have these two groups bend and stretch. And these constraint groups are coming from this valum cloth because output group option is on. We can either disable this. Let's not use them and also disable them. Or if you like to, you can just keep enable them. And let's say I want to animate the valum pressure. Let's go into this stretch, and onto this stretch, I want to animate this stretch rest lang scale. That I'm going to enable this output group, and it to sets stretch and previously we do have stretch. We need to set unique name. I'm going to call this one maybe an a pressure. Let's type this one, pressure, which means now we should have an A pressure group, this constraint group. If I were to middle mouse button, here you will see we have three groups. We have the bend stretch and the pressure. Let's import this group to animate this rest length scale. Time inside the Valum solver onto the Valum constraint properties. Let's enable the group option. Right now, it is disabled. Let's enable this. Let's define the group. I'm going to set the fresher group, which means that now all of the changes will going to be applied only onto this group, which is fun, which is exactly what we want. Now we can animate this parameter and it will be going to be updated every frame. If I were to hit play, let me zoom out and hit play. And if I were to interactively adjust, here as can see, I can interactively inflate my soft body, or I can lower this value down, and that way I can just remove out the air to create an deinflation and Heirs can see. Now, all of the changes will going to be imported. And that's how you can create your blown inflation and de inflation effect. That is a very good constraint, this alum pressure to create this sort of pressure type constraint. Let's take a look at another constraint that is also used for creating the soft pdy. I'm going to just select all of these nodes and let's duplicate them onto this side. And for this one, right now, we are using the merge node to actually merge our geometry and the constraints together to actually better organize all of these merging operation, we have an de called valumP Let's type Valum and inhere pack. Let's add this. What it will do, it will going to pack both of our geometry, the geometry, as well as the constraint geometry, and now we are working with only one single output. Let's pack both of them. I'm going to just let merge for now. Let's also pack this geometry stream. But for this one, I'm not going to use the pressure constraint, but we are going to add the tetrahedral soft body if you type Valum and configure tetrahedral soft body. Let's add this. What it will do, it will add these two node. First is this tricon form. And what it will do if I were to connect this and let me arrange this node graph, it will convert our geometry into what called the tratrahedrons. If I were to middle mouse button and heroes can see. Now we are working with tratrahedrons. And what are these? These are the geometry that are inside. Before that, onto the remsh we do not have all. We only have these regular points and pibatives which means that inside of our geometry is hollow. If I were to add an clip node in here and if I were to clip this heroes can see, our geometry is hollow. That's how the polygonal geometry is. It's hollow inside. But this geometry, if I were to add an clip node in here, and here can see we are filling with our geometry. Now this geometry is no longer hollow. If I were to clip this, you will see our geometry has been filled with tetrahedrons, and now that will going to preserve our volume pattern. Me, delete this first we are converting this, and then we have the constraint for that. And if I let me make this span a bit bigger, and here you will see we have the preserve volume option turned on. Let's use this for our simulation, and I'm going to add another pack node. Let's add ValmC Let's pack the geometry and all of constraint geometry. And now we are working with single output. I can continue adding more sources. For example, I want to create, let's say, another collider I'm going to add an a sphere node in here, polygonal sphere. I can add an A valum shape match. Sorry Valum shape match is not there. We need to add the Valum constraint, connect this and let's change this to our shape match constraint. All I need to do is add an A ValmPC node. Let's pack both of our geometry and constraint geometry. And now we can add an A merge node in here. Let's merge all of our sources, and that way, we can stay organized and to actually use this geometry and the constraint geometry, we also have a node called ValumUnpack. That's add and a Valm unpack node. And what that will do, it will use this single input and then give us back our velum geometry as well as our constraint geometry. Let's connect this, go into the Valum solver, and right now our sphere is located down here. I'm going to go into this sphere. Let's suggest its center and move this up and also maybe let's play around with its Z offset. Let's play. And here you will see we have all of our geometry in the simulation, and they are working fine. And here as you can see, we have this type of geometry that is filled with volume, filled with tetrahedrons. And that will create this soft body that actually preserve its volume, and I can control its rigidity. Let me first not use this constraint or this sphere. Or maybe let's use this sphere and let's not use the cylinder. Let's play again. And here you will see now we are preserving our volume, and I can go into this Valum constraint. In here, I can uncheck this preserve volume, and what that will do, it will just not preserve its volume, and here can see we still have an A fill out effect. It does not feel like that it's an empty geometry. We still have volume, but it's not preserving them. As you know, this ball is rolling. It's just compressing it, and we do not have the volume preservation. And all of these artifacts they are coming from because we need to actually increase these substeps. If I go into the Valum solver, we need to increase these substeps and we should get an accurate simulation. It will get slow, but we will get an accurate simulation. And here you will see that we will no longer get these artifacts because we are working with multiple substeps. I'm going to just keep this value to one so that we have an interactive viewport. I can go into this constraint. I can enable the stretch stiffness. Right now we are using the very low stretch stiffness. And if you were to increase this, let's increase this 200,000. And here you will see that our geometry will be an A rigit and here you can clearly see that we have some stiffness back. I can enable the preserved volume option, and that way our geometry will going to preserve its volume, and here as can see. I can also enable the plasticity. If I go into this stretch and in here, we have the option to enable the plastic And what that will do, it will going to keep its deformed shape. Right now, the plastic t is disable, and when this sphere squish it, it will try to preserve its shape. It will going to return its original shape and hers can see. Right now, we have this weird artifact because of the low substeps, but it will going to return to its original shape. If you were to enable the plastic T and in here we have the threshold, and threshold is what going to trigger the plasticity. If the deformation or stress is greater than 0.1, plasticity is going to be triggered, and here you will see that we will have an sum of the deformation that will going to be retained. And right now they are not retaining a lot. We need to increase the rate, and I can continue increasing the rate, and that will just increase the plasticity rate and let's it play again, and here you will see that this shape is going to retain its deform shape, and here is can see or this mesh is not going to return to its shape. Now we are keeping the deformation. And down here we have the hardening and hardening is the parameter that some of the soft geometries, after the deformation, they get harder. So we have the parameter for that. I can enable the hardness and that will just simulate the hardness effect that we get with some of the meshes. And here you will see that they will stay hard. And right now we are preserving the volume. Let's disable the preserved volume option and let's view again. And s can see because we are not preserving the volume, the sphere hits and it will going to retain its shape. And we might need to increase these substeps because I'm getting this weird artifact. Let's increase the number of substeps. Let's see the result again. Now we should see some of the better result. And right now, I'm still getting weird these tents, which mean that we need to continue increasing this, but you get the idea that it is working. And this plastic D is not unique to this Valom constraint type, this tratrahedral. You can also enable these onto any of the soft body. Right now we are working with cloth. And if I were to go into this strut constraint into the original constraint, if I were to hit play, we are creating this cloth that is giving the soft body effect and also we have this strut that is actually what keeps the volume, and I think we do not have an A collider inhere. That is why it's looking like that. What I can do, I can just copy the collider from Let me copy this collider. And I think we need to I'm going to just copy this tube and the shape match. Let's add this inhere, and same thing. We need to first pack this. Let's add an abalmV node. And let's pack our geometry as well as our constrained geometry. I'm going to add another well pack node. Sorry, alum pack. Well um pack at this and put the geometry and constrained geometry. Now we need to just add and merge in between. Let's add and merge and merge both of the geometry stream. After that, after that, let's add and alum unpack to unpack our geometry and constraints. Let's connect this in here. I'm going to reorganize this node graph. Let me select and push this down. That is our new geometry, and that is our new constraint geometry. Let me move this into the side. Now we have our collider back. Let's hit play, and we should see the collider. I can go into my valum strut because as you know, these are the strut that is actually preserving the volume. I can scroll down and I can see the plasticity onto the stretch. Let's enable the plasticity and we have the threshold. I'm going to just increase the rate. And here you will see that this soft body will going to retain its deformed shape. And right now our collider is not heavy. Let's go into this tube and onto the Valum shape match, and I'm going to set the mass on my own. Right now, it says unchanged. Let's change this to set uniform, and I'm going to just increase the mass to one, and that way we are manually creating out this cylinder as heavy geometry. And here you can see it is squishing that, and this cloth will going to retain its shape. It's not going to return back to its original shape. You can see that it is actually retaining that. And right now we are working with very low substeps. That's how you can create the plasticity and I'm going to just not create this messy network. I'm going to just delete all of them, delete Valum and I'm going to connect this in here to make this node graph stay as the way that it was. Let's zoom out. And let's connect this into there. Let's go into the Valum solver. And right now we are at the hundred and 12 frame. Let's go back and hit Play. And that are the different types of velum constraints. That's how you can animate the constraint properties, and that's how you can create this plastic t onto your mesh. 61. 61 Vellum Hair: Let's take a look at the valum hair constraint. We can use the Valumhairstraint c to simulate our valum hair. We can simulate the strings, we can simulate the ropes or wires. Let's see how we can create that. I'm going to create an A geometry node, and let's dive inside. First, we need to create our line you can either draw. You can draw your own line by adding the curve node. Let's add this. And when the node is selected, press Enter and now you can start drawing your own line because, you know, here and where they will just basically start with this line. I'm going to just use an A line node. Let's add an A line, and let's add this, and that will just create a very straight line. Let's go into the line node. I can adjust the length of my line. I can define the number of points if I were to enable the point. Hers can see I am creating more or less points. Maybe it would be better visualized if I enable the point number. Hers can see I am creating more or less of the divisions of the points because we are going to create an soft of the soft simulation. We need the number of points. We must have some divisions because if we do not have enough travisions we're not going to get an a high as bending effect. Let's increase the number of points, and that will just increase the divisions going to realign the line. Right now we are aligned with the Y axis. I'm going to zero it out and let's align this onto the Z axis. Now we are at the Z axis. Let's inhere create an a valum constraint node. Valumhir constraint. We have the valum configured here. Let's add this. It is an valum constraint node that is set to Valumhir. Here's can see the constraint type is set to hair. Now let's add an A solver to actually solve this. I'm going to select the node and type the Valum solver and press shift enter, and that will just connect all of these nodes and set the display flag. Let's hit play, and here you will see that our here is going to fall. Here as you can see it is falling due to the gravity. Let's pin our very first point. If I were to enable the point number, the very first point is always going to be zero. Means I can go into the alum here. And if I find here, we have the pin to animation and pin points. I can define the groups. You can create your group that you want to pin or you can set the point number. In this case, I want to pin my very first point, point number zero. Let's hit play, and now our very first point has been pinned. And right now this pin type is set to permanent, and that is why this second point also has been pinned. Let's change this to soft. Always use the soft. It will just yield better result. Let's it play and here you will see that we will get all of the points moving and this point is only anchored at its location. Maybe let's also anchor the very last point as well. In here onto the zero, I'm going to press space and type another point number. And this time, I want to also pin the last, which is the 21. Let's type 21, and now both of the points should be pinned and hers can see. We have this hanging rope type effect. Let me enable my real time playback and maybe let's hide the point number and hit play. I can go into this vellum constraint, and I can adjust some of the properties of this material. Right now, we have this stretch, and it is set to infinite stretch. If I were to lower down the stretch stiffness, here you will see that this is going to stretch right now, I cannot see. Let's maybe lower this value down to 100. Or maybe even lower value one, let's keep lowering this down 0.01, and heroes can see. It is now simulation is now it's just breaking. Let's change this 20.1, and let's see. And heroes can see we have this springy type motion. And right now, because our pin type is soft, I can change this to stop, and I think it will not going to move and hers can see. And I can lower down this stretch stiffness 20.01, and let's play. And I can go into the Valum solver. Always increase the number of substeps if you're facing problems, and that will just increase the accuracy of your overall simulation. I can increase these to five substeps. Let's play. And now let's try the pin type. Let's change these two soft again. Let's see if that is stretching and it is still stretching. Permanent and lets it play. And that's how you can control the stretch stiffness. I'm going to change this back to soft and let's increase its stretch stiffness. And we have the bend stiffness. And this bend stiffness is what creating this soft behavior. If I were to increase the bend, here you will see how this wire is stiff, which means that it is very hard to bend. And it will be better if we have the collider inhere, and that will visualize it better. Maybe let's create an A collider, and I'm going to create an A sphere in here to create the collider. Polygonal sphere, let's add an A valum constraint. I'm going to create an A valm shape match constraint to create the rigid constraint. Let's change this to shape match. And we need to merge both of them. I'm going to add an velum node or just simply add these two merge node. I'm going to merge this geometry and order is important. And right now heroes can see I am using this reverse order and if you were to add another merge and order your constraint first, this constraint first, and this constraint first, here you will see that our simulation will going to break. And I'm going to go into this spare and let's move the center, and let's also adjust its Z offset so that we have at the center. I'm going to also lower down this size. And if you hit play, here you will see that our simulation is breaking, and that is because of the order. It must be in the same order as you have the geometry. Right now we are using this first geometry and then the Valum constraint, this constraint in that order, we need to go into the merge and let's click on it. And now we have organized the order. Now if I were to hit play, our simulation will work just fine and Hears can see. And right now it is stretching because we have a very heavy object, and let's hit rewind and hit play. Heres can see it is a very stiff looking hair. I can go into the Valumhe and I can go into the bend. Let's lower down its stiffness to 0.01, and here you'll see that it is going to be a very softer. And now it is just stretching a lot, and here as you can see, I can create another example in hair, and for this one, I'm just not going to use all of these or maybe just duplicate all of these setups onto this side, and let's remove that and remove this merge. I'm not going to use the Valum shape match. Let's connect this. Let's copy the hairs onto this sphere. For copying this, I'm not going to use these original points because later on, I'm going to add a copy to points node. If I were to add copy to points, as you know, it required the points and I don't want to use these original points. I'm going to just add an scatter node and I'm going to just scatter bunch of points. Let's go into the scatter and let's lower down the number of points. I don't want that many copies of my hair. Let's organize this node graph. That is the geometry I want to copy, and that is the scattered points. Right now they are not aligned because we do not have normal. Let's add normal inhere by using the normal node. Let's connect this now the copy two point node, we going to align our line to the normals. Let's go into our Valumhe and that is our ValumhirGeometry. Let's go into the Valum solver let's play and hers can see our simulation is falling. And right now the very first point has been pinned because pin to animation is turned on. I'm going to let's remove this. And heres can see all of our hairs are falling due to the gravity. Let's pin our hair to this collider. Right now, we are using this spare. Let's pin this to the collider. First, we need to add this into our simulation as an collider. The last is for the collision. Let's connect this now that we have this sphere as a collider and it will collide. And some of the hairs that are actually inside of the collider, they got trapped, and that is why we have this hinging effect. If I were to, let's say scale down my sphere by adding the transform node, transform this and let's scale this down. We were to lower this uniform scale just slightly. And it's play and heroes can see we have all of our hair falling. And right now, the scaling heroes can see this scaling is not happening at the correct Pivet because the pivt is set to default at the 00 and to actually center out the pivt location of the transformed node, we need to collapse this PV transform option, and we have the option, move pivt to the centroid. Let's click on it, and it will just going to center out the pivt onto this geometry. Mean if I were to transform this, now we are transforming this at the geometry origin at its geometry center, and now we have the scaling happening correctly. Now if I were to hit play, has can see all of our hairs are falling. And that was the point I want to make that they are not actually connected because they are trapped inside. Some of them are trapped inside. That is why they got just trapped and they are not falling. But they are not attached to it. Let's fix that. Let's attach this point. And to actually attach this, we have a constraint Valum attach. Let's type velum attach, attached to geometry. Let's add this in between. And what this Valm attach will do, it will going to look for the collision geometry. And right now, we have the collision geometry present. And if I were to view the valum attach, and heroes can see we have these constraints, visualized, all of these, which means that all of the points are attached to this collision geometry, and I don't want that. I only want to attach this very first point to the collision. And to fix that, let's go into the Valum attach let's enable the max Tristans option. Enable this, which means that we can define the distance. Let's continue increasing this and heres can see. As I continue to increase its value, if I were to maybe add bigger increment, heres can see, I am attaching more and more points to this sphere. But I'm going to just add an a slight maybe let's increase this 20.03 value and heres can see all of my points are now being attached into my collision geometry. Which means if I go into the Valum solver and hit play, and here you will see my hair has been attached, and I can increase the resolution. Let's go into the line. Let's add more points so that we have a better high as mesh, and we can also animate our collider. Right now, we do not have any animation. Let's go into the transform and let's animate this onto maybe Zaxs so. Can add an a key at the very first frame. Let's start with zero. And here can see as I'm scrubbing, we are also simulating, so let's disable this solver. I don't want this simulation to be happening when I'm scrubbing. Let's go a few frame forward's just it's setting, maybe add positive value, add an a key. Let's go a few frame forward, and let's change this to minus some value. Let's add another key. Go a few frame forward, and let's make this to the T four. Add another key. Let's go into the Valum solver again. We are at the Valum solver. Let's enable the alum solver. Enable the simulation network. Let's play, and heroes can see. All of our heir are now following the animation of our collider because they are attached to it. I can even add the rotation. Right now, we do not have an rotation. Let's go into the transform and I can also animate the rotation. Or maybe we can add the expression. I can add Nin F. Dollinge F means the current frame number, which means that we are adding the frame number in here, and we were to click here can see we are actually inserting our current frame number into the rotation. Now we should see the rotation happening. Right now, not quite a lot of rotation is happening. So let's multiply this. Let's click on it so that we have the expression. I'm going to multiply this by five. Let's say I want to create a five time more rotation, and here you will see we should get the rotation. Let's come this into the rest and we will going to be seeing the rotation and heres can see. All of our hair are also rotating and they are attached to our collider. Can now go back, and that is odd geometry. And to add the thickness in here, we can add an polywire node, and that will just add the thickness let's connect this and with the polywire I can go into the polywire and let's lower down the radius and to actually smooth out right now we are creating these square ribbons. I can go into the divisions. Right now we are using four sides. Let's continue increasing this to smooth out these ribbons. And if we hit play and hairs can see, we have the very thick hair back, and that is the basic of Valum hair constraints. 62. 62 Vellum Grains: Let's take a look at the Valum grains and valum fluids. We can use the valums to create the fluid simulation as well. Let's create an A geometry node, and let's dive inside this geometry container, and I'm going to create an a source in here for first, let's take a look at the grains. I'm going to create an A sphere, and I'm going to change the sphere to polygons, and that will just create the triangles, and I'm going to increase the frequency to increase more of these triangles. Now I'm going to convert this. I'm going to first add a mountain node to add the deformation. Right now, it is a very smooth looking sphere. Let's break up its smoothness with the noise. And same thing, I'm going to create a source of sand that we just did with the pop grains, and I'm going to change the noise to positive and the noise type, we are going to use the Worley cellular. That will give us this stone looking noise. I just need to increase the amplitude. Let's play around with the element size, something like that. Now let's add a transform node, and I want to move my source a bit up. Let's add a transform, and to the translation, let's move this a bit up. Let's convert this into grains. Same thing. We have the grain source for the pop grains, and here you can see, you can use the grain source to convert your geometry into these grains. And for working with Valum grains, we have an A its own node, the velum configured grain. If you type velum grain, here we have the velum configured grains. Let's add this, which means we need to connect this into this node. Valum configured by default, it will just do nothing. We need to click on this create points from volume. Let's click on it, and here can see it will add the points. It will fill our source geometry with these points, and these will going to be the grains particles. We can create more of them by going on to the particle size. If we were to lower this value down 0.05, we are creating more of our green particles, and here can see they are displaying them as fare and we have the option. I can just uncheck this and it will just add this sprite material right now, it's missing. That is why we have this blue. I can uncheck this sprite to hide the sprite or we can change this to display as fair and we can visualize these green particles as an it sphere. All we need to do is add an A solver. After that, we can add an A Valum solver. If you tie Valum solver, and the node is highlighted, which means I can press Shift Enter, that will just connect them. This Valum solver is great for creating the soft pdy simulation if you are working with cloth or hair. Valum solver is great. But if you want to create the granular simulation or the fluid, not all of these settings has been exported onto this soap level. We have some basic setting. If I enable the ground position, we can enable that. And here you can see by default, we will have this dry sand effect, and right now, its motion is a bit jiggly. Let me enable the real time playback and let's see again. And to actually create the Valum grain and the Valum fluid, we need to create our Valum solver on our own inside of the Dp net because not all of these settings are there for working whenever you want to create the grain simulation. I'm going to create an Db net, and we actually do not need this Valum solver. And now let's dive inside the Db net. And as always, all of these simulation, we have the object and same thing in here for the Valum you type Valum we will see the Valum object. Let's add this, and we need the Valum solver. Let's add Valum solver we have it. And this very first it goes to object. Let's connect this. I'm going to connect this into the output. We can define the sources at the very last. If you type Valum source, I can type Valum source node and by doing so, we can import the Valum source. We can actually import the source from the Valum object as well. If I were to enable the parameter, here can see we have the option to define the initial geometry. And go into the geometry in here, I'm going to create these separate nulls because I want to import them. I'm going to just connect this and I'm going to rename this Geo, and I'm going to create another null and connect this onto the constraint. And by the way, right now, we are not creating constraints. Their constraints are not there, but we have all of these points. But later let's say if you want to create a soft body or maybe you want to create the constraint on the grains so that we have the null for the constraint as well. I'm going to create an A constraints constraint. And let's import this into our Db net. I can go into the Valum object, and here we have the initial geometry. Let's select. And I'm going to select the geocstraint. And onto the constraints, you can import the constraint. I'm not going to import that since we do not have constraints. I'm going to add a ground plan as an collider. Right now, we do not have the ground. Let's add a merge node to merge this with our simulation network. Let's connect this and same thing, we need to organize the order if I were to hit play, nothing will happen because there is no forces. Let's add a gravity force to make these particles fall down for the gravity. Let's connect this at the very end and I'm going to hit play. And we have the same simulation that we had in our soap level. Now, if we go into the Valum solver, we have all of these options. I can go into the Advanced tab, and heres can see, we have a lot more option that was just not present into the sap level. Right now, because we are working with grains, I can go into the Advanced tab and here we have the option for grains collision. Let's collapse this, and here we have the options that are relevant to the grain. And down here we have the attraction weight, and that is the attraction that will be used to create the dry sand or wet sand effect, and we have the attraction, and this attraction represent the stiffness. These stiffness present that we had on the pop grain, if I add the pop cranes node, and here you can see onto the clumping, we have the weight, and this weight, you know, is the attraction weight, however, can see the parameter is the attraction weight. That is the attraction weight and the stiffness. And the stiffness onto this Valum solver is renamed to attraction, but it's actually the same parameter. I'm going to delete this pop grain. Let's go into the valum solver, and let's increase its value all the way up to one and let's play. And right now, our value, I think one is too high because in the valum the parameter has a much more exaggerated effect. I'm going to lower down the attraction value and a very low value to one. Let's sit play again and heroes can see I need to just increase these two little bit. I'm going to, let's say, increase the 25, and right now they are still sliding. I'm going to continue increasing this value down. At the value of eight. Now the simulation is actually breaking. I can lower down the attraction weight. Yes, I can continue lowering this value down. Let's change this 20.6 and increase the attraction weight. Maybe, let's change this to 100 and it's still going. Here can see it is bit fiddly. These grains, whenever you want to create the grains, I always use the pop grains. At this. These pop grains will give you more stable result than the Valum solver. Valum solver is great whenever you want to create the soft party simulation. Let's go into the Valum solver, and I'm going to just play around with this value. I'm going to change this to ten, lower this value to 0.5 and let's hit play. And we all need to also increase these substeps. That was also breaking because we were working with less substeps. Let's go into the Valum solver, and I can go into the common tab, and in here, we have these substeps. Let's continue increasing these substeps. Let's change these to seven, and now we will get accurate result and hers can see. Now we can clearly see this attraction weight working and all of these particles are sticking together. I can go into this Valom solver and onto the Advanced tab. I'm going to just let's load on the attraction value to one and let's hit play again, and Hears can see. Now we have a much better control result. Same thing. Let's say if I were to change this to one and let's hit play again, and Hears can see. And you can, same thing, create these attribute beforehand onto the sobs. If I go into the geometry level and to the Valum configure grain node. And here we have the physical attribute. If you collapse this menu. Here can see we have the attraction weight in here, if I were to enable this and you can set this manually from the sob if I were to let's say lower this value down to 0.3 and actually I am visualizing this solver to actually get the feedback from the simulation, we need to view the top net and let's play again. And here you will see that we will have an A effect. Go into the Valam configure and if I were to lower down this attraction weight, we will see our dry sand effect. And here you can see, I can continue increasing this and these value go beyond one, and here you will see that now all of the particles are sticking together because of the attraction. Let me disable this attraction weight. You can create an attribute noise node that we had just did and create the attraction way to noise drop to create some of the wet sand and dry sand. You can do so with the velum grain as well. And onto the Valum we can also use this valum to create the fluid simulation as well. If you type Valum configure fluid, can see, we have the option to valum configure fluid. Let's add this, and it is an ASM node. Here you can see it is Valum configure grain. These node and this node are same, but the setting has been changed to fluid. I can go into the valum constraint. Right now we are using the grains. I can change this to fluid. And if you enable the fluid, these options has been enabled. The phase viscasty and surface tension. And if we to change this to grain, here's can C, I cannot enable the settings because these settings are there for the fluids. Going to use this preset that we had just created. Let's connect this, and I'm going to connect this into our geometry and for this one to be grains. And now we should see fluid like effect if I were to hit play and heroes can see. And right now, maybe let's add an color and a wall in here where we will get this blob of fluid. And for that, I'm going to create an sphere node in here. Let me tramplate my sphere and onto this sphere, I'm going to, let's say, move this up by going on to the center. And we also need to move this blob, a bit up. Let's go into the transform and let's move this a bit up. And let's go into this fare, and I want to continue increasing its radius, and to actually make this dynamically sit onto the floor, we can add match size node and let's add the match size connects, and that will make sure that I can go into the justification Y to minimum and that will always be sitting onto the floor. Now I can add the clip node to clip out the upper part. Right now, here as you can see, we have all of the square filled out. I can add the clip to clip out the upper section. Let me tramplate the math size. Right now we are using the X direction. I'm going to change this to Y and zero this out. Let's enable this right now it's going on. The other direction, let's change the direction to minus one to reverse this, and now I'm going to just adjust this value, and now I'm basically clipping off the very top of my sphere. And to add the thickness, let's add poly extrude node. Connect the clip node into this one and onto the polyextrude, I'm going to just increase the Tristance value. And right now Hers can see we are not adding, let me untramplate my clip. Hers can see the inside, we do not have the geometry. So let's fill out this by enabling this output back option onto the poly exxtrude. Let's enable this, and that will just add the thickness properly. Now we can just import this as an A collider. I'm going to create an A null in here and I'm going to call this one to be our collider. And let me template this with my sphere. I'm going to view the grains and template my poly extrude. I think we need to increase the size of the sphere. Let's go into the sphere and let's continue increasing that so that we have a bigger ball. And I think now that this value is fine. Okay, that is fine. Let's go into the top and dive inside. Now let's import this as an estatic object. Let's add an estatic object, and we are going to merge this with this stream. Let's change the order because order is important. Let's go into the static object onto the saw path. Let's select our collider null. Here we have the collateral at accept. Now the collider has been imported. Now we should see that we are going to fill out this and here can see. We are creating this splash. Now we have this fluid like simulation. Can go back. Right now, we are working with very coarse resolution. Let's go into the Valumcfigure fluid. I can lower down the size. Let's change this 0.05 to create more of these particles, and heres can see. We are creating these splashes, these fluid splashes. Let's enable the physical attribute. I can enable the viscosity and viscasty will create an viscous fluid like honey. And if I were to hit play, you will see that we will have an a viscus. Right now, the value is too low, so maybe let's increase this viscosity value, and here you will see that we will get an A viscousness Heirs can see particles are now sticking together. I can continue increasing this to 100 and we should see some of the viscosity happening and Heirs can see maybe let's continue increasing this to even higher value, and heroes can see. We have a very viscous fluid and it's not even splashing. I'm going to disable this viscosity and let's enable the surface tension and the surface tension, what makes these particles to stick together to create the droplets, and you want to increase the surface tension if you want to create the splashes or tendrils of fluid that you might get in these small scale fluids. And if I were to increase this, and here you will see that most of the particles will going to stick together. Here as you can see, right now, it is hard to see because we are still working with very coarse resolution. Let's lower this value down to even further 0102, and let's hit play. The simulation will be slow, but you will see more of these splashes, tendrils because of the surface tension. Let me simulate a few frames, and hopefully we will see some of these bigger splashes and particles will going to be sticking together. And right now, this simulation is just exploding. Let me see why is that. Surface tension is able, let me increase its value to a bit higher value. And I think we might need to increase the substeps as well. Let's see. I'm going to simulate some of the frames. Let's go into our Dup net. That is the Dub net, and let's go into the Valum solver. Right now we are working with the grains, but because we are working with fluids, let's collapse the fluids menu. And in here we have the option to enable the viscosity, and that is a multiplier from the soap. And if we were to change this 21, that means that all of our velocity will going to be multiplied by this, and heroes can see we have the surface tension, and we are using the very low value of surface tension. That is why I'm not seeing the effect. Let's change this to one, and now we should see more of the effect. And right now, our simulation has been broken, which means we need to go back. We are using the very high surface tension value. I'm going to let's change this to one and let's play again. Whenever you see these breaking effect, these are coming from the number of substeps. They will get improved when you increase these substeps. But here you will see the surface tension effect a bit better. Let me simulate few frames, and let's see. Right now, I think our source is not good as well, but I think if I were to, let's simulate few frames, but let me adjust my camera angle, and here can see. We have these splashes, these tendrils. All of these are now sticking together. And that's what controls the surface tension. I'm going to just disable the surface tension. Let's dive go back onto the top net onto the alum solver, and I'm going to just default out the surface tension and the viscosity so that we will not get the breaking of our simulation. And I'm going to also lower down the number of particles because the simulation is not very interactive. I'm going to change this to 0.05. I think that is a better resolution. And right now, heros can see we are initializing our source or fluid source at the very first frame and then simulation is taking care of that. I can go into the top net and onto the Valum object. I can inhale, just remove out the initial geometry. Instead, I'm going to use the Valum source node. Let's connect this onto the last input, and onto the alum source, we have the sob path. Let's add our geometry, and we have the constraint sow path. If you're working with cloth or creating the constraint for grains, might need to add the constraint inhere, and now we can change the emission type. It says only once, which means we still have the same effect. We are initializing it at the very first frame and simulation is just taking care of it. Can change this emission type. I can change this to each frame. I can import my source each frame, or I can import each substep. If you change this to each substep, it will just import more of the particles because the source will also going to be important onto each substeps. I think it's better to just change this to each frame, and that way we will have manageable number of particles. And here you can see we are importing our source from the sub every frame, and now we have this emission effect. Going to maybe let's go back and go into the transform, and I'm going to just transform our sphere, our source a bit up so that we have some of the distance between them. Let's go inside and hit play. And heroes can see we are importing our fluids every frame. Now we are emitting the fluid. That's how you can import your sources every frame. Let's go into the velum solver again and let's go into the common. We are using the seven substeps. Maybe let's lower down the substeps and let's play. And here can see we have a faster playback of our feedback and our bowl has been filled with our fluids. That is the basics of velum grains and velum fluids. 63. 63 Flip Fluids Simulation: Now let's take a look at the flip fluids. We are going to create the water fluid simulation by using the flip fluids. Let's see how we can set it up. I'm going to go into this object level and create an A geometry node empty geometry container. Let's dive inside. First, we need the source of emission. I'm going to create an a sphere geometry, and this sphere will act as our source for water, for our fluids. Let's go into this sphere, and let's move this up. Now we need to create an A top net top network. Let's add this, and I'm going to just connect this on to the very first input. We might need to reference this. Let's dive inside the top net. In here, we need the flip object. Like all solver, we have the flip object. Let's set this and we need the flip solver. Let's set the flip solver, and here we have it. Very first input is the object. Let's connect this. And I'm going to connect this onto the out. And by default, we see some of the particles. Here can see we have some particles, and these are coming from this flip object. If I go into the flip object, here onto the initial data, we have the saw path. And right now it's using this default fluid path importing this cube that actually came with the default directory of the Houdini. I can make my own saw path onto the saw path. Let's click on it, and from here there, I'm going to just select my sphere, hit Accept. And up here, we have the input type. Right now we are using the surface sop. Surface sop means that it is expecting the jump t node. And if we go back here you can see, we have this sphere, and it is an a jump node, which means that if we go into the Dub net, we have our sphere imported and it's now working. If I were to hit play, nothing will happen as you might have guessed. We need the forces. Let's add an A gravity force in here. Let's connect this and it should fall down due to the gravity. Let's add an A ground plan so that we must have something to collide with. Let's add an A merge node. Let's merge this with our solver, and let's organize this and let's play. And here we have our very basic fluid simulation. Right now, we have a very coarse resolution. Let's go into the flip object. I'm going first go to the very first frame. Let's go to the flip object. We have the particle separation, and this particle separation will control the resolution of our simulation. While lowering this valuon, we're going to create more particle. If we were to change the 20.03, and heroes can see. We have a lot more particles. And right now they are a bit hard to visualize. That is because by default, Houdini is using the sprites as visualization to actually change the visualization. Let's go into the guide stab and here can see we have the particles visualization enable and its color is blue, and we have this corresponding option for the visualization. Let's go into the particles, and here can see the visualization is set to sprites. Let's change these two spheres. Now we can see bunch of these small spheres. Or I can also change this to grains or particles. Let's change this to particles because it is very lightweight visualization. Let's change these two particles, and let's sit play. And here, as you can see, we can see the visualization. I'm going to enable the real time playback as well. Let's sit play. Here as you can see, we have the visualize as particle, and we can see all of the particles. If I can increase the particle separation, I'm creating less of the particles. By using the sprites visualization, it will also give us the visualization of the scale, and we can control the scale from this particle radius scale, and it is a multiplier. If I were to lower this value down, herosken see we're adjusting the particle scale, and by default, it is a multiplier of 1.2, and this particle scale will going to be generated for us from this particle separation. I were to increase the number of particles heroes can see our particle size also get increased, same thing, if I were to lower this value down, we will going to be creating more particles and the particle scale will also going to be decreased also. And this particle radius scale will just as an a multiplier. Let's change this to the default. And we actually do not need to visualize this as an Sprite because let's change these two particles. It is an A very heavy in the visualization and particles are very light way to visualize. Let's hit play, and we have our very basic fluid splash. Now we have the blob of this fluid and it is splashing onto the ground. And if you zoom out, here as you can see we have some of these boundaries. These are the bounds in where this fluid simulation will live. It has its domain, and we can control the size of our domain, and the size can be controlled from the flip solver. Let's go into the flip solver and enable the parameter and it should be on the volume motion. Let's go into the volume motion tab, and here you can see the very first is the volume limits. And right now it is visualized. If I were to disable this, the domains are there, but we're just not visualizing it. I can enable the visualization, and I can even make I domain size smaller. Let's continue lowering this size down. Let's continue lower this down to a very low size. And I'm going to also move this box a bit up and now our simulation will only going to be lived inside of this domain, and all of the particles that will try to leave this domain will going to be deleted here as you can see. I can go into the flip object and we have this option closed boundaries if you were to enable this. It means that all of these domain, all of these bounds will now act as an a collider. Instead of cutting off, we are going to colliding them. Which means that I actually do not need this ground plane. I'm just going to remove the wire from here, which means that now these bounds will act as an collider. If I were to hit play, hers can see our particles will not going to be cut off, but they will going to collide with this domain. And before that, if I were to go into the flip object, and if you disable this close option, the particles will going to be just deleted and hers can see. Enable the close boundaries and now the particles will act as an ecder. Sorry, this domain will act as an eclider. Right now, we are importing this blob of particles or this blob of fluid, and simulation is taking care of all of the simulation. I want to continuously emit by particle fluid and to actually continuously import this, we need to go into the flip object and let's go into the initial data. Let's delete out this saw path. We don't want to initialize anything, but let's use the source node to continuously emit our particles. If you type the flip source in here, flip source and Heirs can see we do not have an a flip source. And that is because this flip solver is a combination of volume. If I take a look at the solver, here can see we have the volume, and we also have the particle. So it is a combination of you can say that the smoke solver and the pop solver. We have the volume motion and the particle motion. To actually import the source, we are going to use the source volume, the same volume that we use to import our smoke simulation or pyro simulation. And here we have the volume source. Let's add this. And the very last is the for sourcing. Let's connect this onto the volume source. I'm going to change this to input. Right now, it says sop I'm going to change this to First context because as you remember, we have plugged this into this first input. And here you can see our source is not being imported. Mean if we go into the volume source, first, we need to initialize this. And if I were to try to initialize this, let's say I want to source the flip because we are working with flip simulation. Let's click on this source flip and nothing is happening. And that is because we must need to convert this polygonal geometry into an A flip source. Side of the soap, we have an A flip source node. If I type flip source, and here we have the flip dp source. Let's add this and connect this. And when you convert this into source, what this flip source node will do, it will convert your geometry into volume. Hers can see I can visualize the surface volume. First, it's convert this into surface volume, and then we also have the particles in it as well. If I were to middle mouse button, Hears can see, I can see points. I have 500 particles, and I also have an A one VDB volume, and it is an a surface volume. It's doing these two things. It's creating the particles and volume. I can go into the flip source. And here you can see, I have the auxel size and that defines the auxal size of our volume down here, we have the particles, and we are also creating the particles as well, and we can adjust the particle separation from here to create more or less particles. And to maybe better visualize the particles, I'm going to click on this Output fog, it will just change the visualization to fog. And here you can see this voxel size control the resolution. If I were to increase this, I'm creating very coarse resolution of our volume, I'm going to lower this value down and the particle separation, that will control the number of particles. If I were to lower this value down, Harris can say I'm creating more and more particles, and same thing if you were to increase this, we are creating less and less particles. Let's default out particle separation. Let's default out the auxel size. Now I'm going to connect this onto the first input. Let's go into the top net and dive inside, and Hears can see. We have our source imported. Let's go into the volume source, and Hearers can see when we initialize the two source flip, it imported the surface volume. And if we go back, as you know, we have the surface volume in here. We also have the one particle group and the group name is set to particles where we have all of the particles. Let's go into the Dp net and onto the volume source, and let's go into the particle step. Here you can see, we are importing this particle group and we are killing all of the particles inside of the dub surface and right now it's not doing anything because in the daub, we do not have A right now, any surface, and that why this has no effect, but we are actually importing the particles. That is important. I were to go back and hit play and heres can see. Now we are sourcing our particles and we are importing our particle source every frame. And that's how you can basically configure your flip simulation. I can go back in here onto the flip to create more of the particles. I can play around with the particle separation. And this value should be linked with the value that is available on the Philip object. If I go into the Philip object, here we have the particle separation. Let's copy this parameter. Let's go back and onto the source node. Onto the particle separation, let's paste these two relative reference. Now we are working with the same particle separation. Let's dive inside and let's simulate this again. Now we will have our continuous emission of our flip fluids, and our particles are now colliding with the boundaries of our flip. So that is the very basics of flip simulation. 64. 64 Particle Fluid Tank: Right now we are importing our source from this soap level from the geometry level into the daub, and we are emitting our fluid from the source. In here, we also have an A particle fluid tank, and what will do, it will going to create an A fill out an water inside of domain. And if I were to create an A particle fluid tank none, let's add this and here we have it and if I were to visualize. And basically, what that is, it will just create an A bounding box and it will just fill out with these flip particles. Can go into this particle fluid tank. In here, I can define the water level and I can say how much water I want in this fluid tank. And in here, we have the particle separation. Same thing. If you were to lower down this particle separation, you can create more or less of your particles, and I can also control the size of this overall particle pre filled water tank. I'm going to just default it out right now or maybe let's increase its size, like so so that we have some bigger size, let's maybe increase its size onto the Z as well. We also have the option for enabling the chitter scale. If I were to change this to zero, here you can see, we have the regular arrangement of these particle. And if I were to change this to one, we have this chitter, and it is a very nice distribution of the particles. Now let's see how we can import this pre filled water tank into the dp Nt into the flip fluids. Let's go into the Dp net, and right now we have this continuous emission. And to actually import this particle fluid tank, we're not going to use the volume source node. As you know, this volume source node will going to import all of our particles every frame, and we don't want that. We only want this tank to be only initialized at the very first frame. So let's go into the Dp kt, and we need to define this onto the flip object. Let's go into the flip object, and heroes can see we have the sob path. Let's click on it, and I'm going to move this in here and let's find our particle fluid tank, and here we have it and hit Accept. And right now here can see this fluid tank has not been imported, and that is because the input type is set to surface sob. It is expecting an epolygnal piece of geometry. But we are using the particle fluid tank. We have these particles. We do not have geometry. Let's go into the top net and onto the flip object, and let's change the input from surface to particle field because we are working with particles. Let's click on it, and as soon as you click this Hers can see we have all of our particles imported in here. And right now they are outside of this domain, which means if I were to hit play, they will going to get deleted and hers can see close boundaries is on, which means that all of this will going to be collide as well. And we have this source, it will going to add up into this tank as well, and Hears can see. Let's go into the flip sorry onto the flip solver, and let's adjust its domain. Flip and go into the volume motion, and here we have the box size. And we can also link this domain size with this flip tank. Here's can see onto the particle flip tank, we have the size, which means I can just copy this parameter. Let's go into the Dp net and onto the box size, I'm going to say paste relative reference. Now we are using the same size. Let me rewind, and heroes can see right now it is offsetted. I'm going to change this box center and let's zero this out. And now we are using the same size. I can adjust the particle fluid tank size if I were to increase more of these particles and let's dive inside and heroes can see our domain size will going to be adjusted also because we have created an air link between them. Let's play, and here you'll see these particles has been filled with this tank, and right now our particles are falling due to the gravity and we also need to link the flip object, this particle separation, and here you can see we are using we're not using the same particle separation. So let's go into the Dub net and onto the flip object, let's copy this parameter. Particle separation, let's go back and let's paste this onto this particle separation as well, base relative reference. We are using the same. And right now we are creating a lot more particles and it will be heavy. Let's go into the flip object, and I'm going to change this to 0.1 to import that many not create that, many flip particles. Let's play and heres can see. Now we do not have falling effect because now we are working with the same particle separation. And this source is also filling out this empty trankR now, well, it's not empty, but you know that this domain also has some room for other fluid. So this source will eventually going to fill up all of this. Let's go into the volume source. If you don't want to import this, I'm going to just remove the wire, and we are just initializing this with the flip tank. And right now, we do not have any motion, but we only have this gravity. We can also add the particle forces in here because you know that it is a combination of the volume as well as the particle solver, this flip solver, which means we can use the particle forces in here. As you can see, we have the second input, we have the particle velact, which means we can connect the pop forces in here. Going to add an App wind node in here. Let's add an Apop wind and let's connect this onto this particle force tab, this particle velocity tab. Let's hit rewind. And onto the pop wind, I'm going to add an amplitude of one and let's hit play. And heres can see. We have some of the wind waves into introduced in our particles. Let's add an a collider in here. Right now, we do not have an interesting motion because nothing is colliding into our water. Maybe let's create an rubber toy geometry in here. I'm going to add the rubber toy. And I'm also going to animate this rubber toy as well. For the animation, first, I'm going to visualize this fluid or this water tank, and then let's tramplate this rubber toy. And I'm going to add an transform node, and I'm going to use the transform to add the animation. Let me template my transform, select the node, and press Enter. Now I can just move down here. Let me enable its parameter and let's add an a key and make sure to disable this flip simulation because as you know, if I were to scrub this this will also going to calculate. Let's disable this. Now I can freely go and I can just maybe move this a bit up onto this level and let's add another key. Let's Trevine and hit play. Now, let's import this as an A collider. And maybe I'm going to create an null at the end for referencing, and that is our collider. Let's rename this accordingly collider, and it should be L, I think. Let's go into the Dub net and dive inside. In here to import our collider, we need to create an static object node. Let's set this and let me go back onto the static object. We need to define the saw path. Let's click on it, and let's select our collider. Let's merge this with that merge node. Let's set this and we need to organize this static object. Let's enable our simulation right now. It is calculating. Let me activate my camera view tool and let's hit Play. It is not calculated. Let's go back and so that it's viewport refreshes. Let's dive inside again. Let's try that again. Let's sit play, and heroes can see. Our this animation has not been imported, which means we need to go into the static object and let's enable this use deforming geometry because we have the animation built in. Let's sit play, and now we should see the movement. And now this object will going to create some splashes in here and heroes can see how this collider is working. Maybe I can introduce another collider in here. I'm going to also let's adjust this and add an A crag geometry in here. Test geometry, crag. Let's view this. It has animation built into it. This geometry, let me view this and translate out this crag so that I can see where my crag is. I'm going to translate this to add the offset onto the Z. Let me maybe place this in here. Right now, I think this fluid level is below the ground. So let's fix this. Let's go into the particle fluid surface, and I'm going to just increase its center. I'm going to increase this center to maybe value of I think the value of 2.2 is looking fine. And we also need to go into the top net and onto the Flip solver. Let's change the box center as well, 2.2 so that we have at the same location. Let me hit rewind and hit play. Right now, I cannot see my particles, and that is because of the particle fluid, we need to adjust the water level. Let me find onto the particle fluid surface, we have the water level, and it is in minus. Let's increase this we can adjust the water level. I'm going to fill it, like, so let's go back onto the top net. And let's hit play. Okay, we have the rubber toy, but we haven't yet imported this crag geometry. So I'm going to go back. We have the crag, okay. Let's add an attic object in here. Let's a static object and into the saw path, let's select our crag geometry. Let me find. Here we have the test geometry crag hit Accept and make sure to enable the use deforming because we have the animation built in. Let's merge this and also organize this node graph so that we have all of the coldrono the left side. Now we have them. Let's play. And here you will see that our crag will going to create some splashes in here. Right now, I cannot see them. What I can do, I can go into the merged node and into the collide relationship. Let's change this to mutual. Sorry, the affected relationship, let's change this to mutual, which means everything will collide with each other. Let's sit accept and heroes can see or this crack geometry is still not interacting with our fluids, and that is because if I go back and visualize my this crag geometry, and if you press and hold the middle mouse button, and heroes can see by default, this crag geometry is an APAC geometry. And this static object that we have just created is not designed to work with PAC geometry. Means we need to unpack this first. Let's add an unpacked node, and I'm going to connect this. And now it should create an irregular polygonal piece of geometry. And now we can reference this into there. I'm going to go into the Dp net and to the static object. Let's use this unpacked node. And now this collider will work. Let's hit accept, and here you will see that collision will going to be happening. And let's give him some few frame to simulate. Let me zoom out a bit. Let's it play again. And right now, there is not quite a lot happening. What I can do, I can go back and maybe let's increase the scale. Let's increase the uniform scale very big value so that I want to really see some of these slashes that it is creating. Let's it play and heroes can see. Our collider is working. Both of our colliders are working because we had the crag very small and it was just not creating these velocities, it was not adjusting, but now it is working. Collisions are happening and hers can clearly see. It's hammer, it's actually interacting with the particles, and we will pick up more detail when we are going to create a more high resolution of this flip simulation, we go into the flip object and lower down the separation, let's lower this down to maybe 0.05. And here we will see that we will pick up a lot more detail with the lower particle separation because we have a lot more resolution. But our colldr is working and hears can see or this crag is moving out these particles. Right now, the simulation is slow. I'm not going to use that many particle separation. Let's lower this down to 0.1, and maybe let's not import this crag in here as well. And down here, we are using right now pop win. We can add some other forces. Let's say I can add an APOp excess force. Let's set this and to use both of them, we can just connect this. So going to the pop axis, and I'm going to increase its radius, and let's also increase its height. And onto the speed, I'm going to increase its orbital speed to create this SRLY type, this Virpo type animation. Let's it play and here can see we have an Avirpool at the very center. I can continue increasing this orbit speed. And here you will see our particle will going to be accelerated. And I can also enable the lift speed if I were to change these 21, our particles will going to be lifted up onto these Y axis. Right now, they are not lifting. Maybe let's continue increasing this line let's play, and here is can see. We have this lifting effect. And I think I can add the minus four if I were to change this to minus five. Now this particle will going to be sync down, and I think we need to create the minus because Whirlpool just sol our particles and the particles will going to be going down. And we also have some other options. We have the suction speed, and that will just suck out our particles at the center of the sphere. Can go back onto the shape, change this to another shape, and here we see some interesting motion and hers can see. You can use any of the particle forces to control the fluid particle motion, and that is the particle fluid trank. 65. 65 Flip SOP Solver: Now let's take a look at the Flip sop workflow. We have all of the flip fluid flip simulation available onto the soap level as well. Let's see how we can configure there. As always, let's create an A geometry node and in here first, we need the source, and I'm going to use an A spare for the emission. I'm going to lift my this sphere a bit up. And to create this, we have an flip solver. If you type flip solver, here we have it. Let's add this, and it requires the domain. We need the container. And for that, I'm going to create an flip container node, and here we have it. Let's add this and we need to connect all of these onto the required container and onto the collision as well. And if I were to visualize my flip solver, here as can see, I can define the container size onto this flip container. Let's enable its parameter. And here we can define the particle separation, and I can define the size of my overall container. And right now, it's not updating. We need to actually play this to have the updates or we can just visualize the flip container. Let's visualize and inhere, if I were to adjust here can see, we have the flip container domain size, and we also have the gravity force built in onto this flip container itself and we have the gravity and it is going onto the minus of the Y. We also have the option for enabling the surface tension. Let's enable this. Here we can define the surface tension, and same thing, we also have the viscosity to create an viscous fluid like the honey or chocolate. Let's disable this and to actually import the sources. We need to connect the source onto this last input. Let's add this and visualize the flip source. And here you can see our sphere has been imported as an a source, and let's play. And here's can see after the bounds or the source is cutting off. Let's go into the flip solver, and maybe let's add an a collider. Let's add a ground plan. Let's go into the flip and onto the ellison we have the option to enable the ground plane. And right now, ground is set to none. I can add the ground plane, and that will just create this for us and let's play and heres can see we have the ellison. Same thing, we are visualizing our particle as surprise. So onto the flip solver, let's go into the visualization. We have the option to enable this point as fair. Let's uncheck this, and now we are visualizing these simulation particles as particles. Let's enable the real time playback as well, and let's hit play. And right now, heres can see we are not continuously importing our source. We have this blob of fluid. It's going to be initialized at the very first frame and then simulation is just taking care of all of the simulation. And to actually continuously import this spare or this source, we have a node called flip boundary. Let's add flip boundary node. Let's set this, and I'm going to connect this in between. And that will going to be used as an a source and the very last is for the sourcing, which means I do not need to connect this inhere and I'm going to connect this at the very last right now has can see this flip boundary node is actually converting this polygonal piece of geometry into our source. Notice, we do not need to create fluid source node, flip source node, if I type and a flip source, ers can see flip top source, and it is only designed for working if you are going to create your own top network. If you are going to use this workflow, this flip boundary will only accept this polygonal piece of geometry, and it will convert this into volume and particle for us. Let's go into the flip solver and lets play. And here can see we have the continuous emission of our source, and we have the ground plane. Can go into the flip container, and onto the particle separation, I can lower this value down, and that way I can emit more particles. Let's lower this value down to 0.03 maybe and heroskanc. We are emitting lot more fluid particles. We have the same effect that we just build into this dub network. Let's go back and onto the flip boundary, we have some other option. We can add the additional velocity. And right now, we have the scale velocity, which means that it is a multiplier for the incoming velocity. And if you take a look at the fare, right now, we do not have a velocity in our source. I can create that. I can add an A point velocity node in her. Let's add this, let's connect this to the point velocity right node set compute from deformation, I'm going to change this set to value, and I'm going to give an A velocity onto the positive X. Let's change this to one. And also, I'm going to add an in noise as well as an animated noise. Now this flip boundary will going to import this velocity from the sob from this source into our simulation and Hears can see. We have these breakups happening in our fluid. I can go into the flip boundary node and I can scale my incoming velocity if I were to increase these 25, which means that we are just going to be increasing the scale of amplitude, overall amplitude of our velocity, if I were to hit play and heroes can see we have a very chaotic motion. Because we are scaling our incoming velocities. Let's go into the flip flip boundary, and let's change this to one, or I can just not use the point velocity and go into the flip boundary and add an A velocity. I can go into the additional velocity and change this to one. And what that will do, it will just give an A velocity into our source. And heres can see. I'm going to just increase this value to a higher value so that we have a bit more exaggerated effect. And Hears can see our Vlocity has been added and this flip boundary is adding them. I'm going to not add this, so let's change this to zero. Let's go back, and in here, let's add another collider because right now we are creating the ground plan onto the flip solver. If I go into the collision you can see, we have the ground plan option to add. But to add additional collider, we can add a flip collider node. Let's add an a flip collider and here we have it. Let's add this and we just need to connect this in between, and we need to put this new collision onto this input. Here, let's say, I'm going to add a rubber toy as an a collider. Let's add this and I'm going to connect this into this collision geometry, and I'm going to move my source a bit up because right now it is intersecting. Let's Let's move this up and let's reinitialize this flip boundary. And I think we are cutting off because of the flip container. Let's increase its Y size, and here can see now we have increased our domain and our source is back. Let's hit play again, and now we should see the collision happening, and hers can see this has been the source or this fluid is interacting with our collision geometry. And you can continue to add more and more collider if I were to, let's stop this if you want to add another collider, I'm going to just add another flip collider node. Let me add an flip collide and let's connect this in between, this time, maybe I'm going to add an sphere in here and let's connect this onto this new collision and let me find this sphere. Let's adjust its axis. First, maybe let's add an A Y upset. I'm going to move this a bit up, and now we should see both of them. Now, first, it's going to be collide with sphere, and now it's going to be collide with this rubble to a geometry. And that's how you can import your collision and to actually create the water tank effect that we had in here, if I type inhere and a flip tank, Hears can see the flip tank that we just created, we can also create this onto this soap level as well. Let's go into the flip solver and Heres see we have the water line. Let's go there and enable the water line. And what that will do, it will just create an A water line, and I can just increase the waterline, and it will just fill out. Right now we are at the frame number 24, so let's go back at the very first frame. I'm going to just play around with this water line. And hers can see. We are creating this filling out our flip with this water line. I'm going to stop this in here because right now the simulation is getting heavy. Let me stop this. Let's go back. And now we actually do not need the source imported in here. So let's maybe delete the flip boundary node as well. And let's go into the flip container, and I'm going to just default out my domain size by clicking on this middle mouse button. As you can see, we have our water in here, and right now it is colliding. I'm going to just stop this and let's rewind and let's not use both of these, or collider. I'm going to delete out this fare, and let's delete both of them. Right now, we have an gap in between if I go onto the flip solver, and that is coming from this narrow band. Right now, we are creating the narrow band simulation. And to actually make this water tank fill, I can go into the flip solver, and onto the Advanced tab, we have this option enable particle narrow band. Let's disable this. And now we are filling out this tank with particles. Let's play, and here you will see that we have this particle filled. Right now, our particle separation is too low. We are creating a lot more particles. Let me stop this. Let's rewind. Let's go into the flip container, and I'm going to just default out to 0.1. That we have a bit more manageable particles. And now Harris can see we are creating less particles. And same thing. If you want to create the particle forces, your pop forces to drive your simulation, you can dive inside the flip solver. Let's dive inside, and Hears can see. We have the force. We can plug all of the particle forces onto this force one. I'm going to add an APAP window. Let's add an APOP wind and connect this onto these forces. Onto the PA wind, I'm going to just increase the amplitude to higher value. Let's go back and hit play. And here you can see we have our wind force working. And that's how you can also apply your particle forces. Let's go into the test geometry and maybe let's animate this source or this collision. Let's add an transform node. And I'm going to just add an a very basic translation. I'm going to start this below the ground. We need to first disable the dynamic simulation. Let's rewind, press and hold the old key to add an A key. Let's go a few frame forward, and let's move this up. Let's continue moving this up, and let's add another key. Let's go into the flip solver, and let's import this as an a collider. I'm going to use an flip collider node. Let's at this, and that is our collision. Let's sit play and heroes can see. Our animation is imported and we actually forgot to enable our dynamic simulation. Let's enable this and let's it play. And this rubber toy will going to affect these particles and heroes can see. This rubber toy is actually creating the slash onto these fluids. And that is the flip sop workflow. That's how you can create the flip fluids right in here onto the soap level. 66. 66 Writing Cache And Meshing: Now let's take a look at the writing the flip simulation cache onto our hard drive, and also let's take a look at the meshing our flip fluids. First, I'm going to create a very basic flip simulation. Let's create an geometry node, and I'm going to create an spare node in here, and I'm going to just convert this into polygons and increase the frequency because I'm going to add an mountain node in here to add deformation onto this source too so that we have some of the breakups. And maybe let's also animate the noise and let's enable the real time playback. We have the sum of the animation built in, and that will create an interesting source. I'm going to use the soap workflow for creating this basic simulation. First, we need the flip container for setting the boundaries. Let's add on a flip container. And when the node is selected, I'm going to add an A flip boundary node for importing our source. So let's tie flip boundary and press Shift Enter. That will just connect all of these input. And when that node is selected, add an A flip solver node in here. Let's add flip solver and our press shift enter again and let's view our flip solver. We need to connect this onto this geometry to source, and here you can see our sources been working and it's importing every frame. Right now it is visualized as an A sprites. Let's go into the flip solver. We can go into the visualization and let's uncheck this point as sphere. I want to visualize them as an A, these particles, and these are very light way to visualize. Let's add an A ground plane in here. Let's go into the flip solver, collision tab, let's add an A ground plane. And we are going to move this sphere up because right now our source is just cutting off. Let's go in here and increase its size or this center. Sorry, we are adjusting the center to add an AY offset. Let's go into the flip solver and hit play. We have this source and it is working. I can go into the flip container. I can lower down the particle separation to create more particles. Let's lower this value down to an value of 0.03 so that we are creating a lot more of the fluid particles, and here we have them. And while we are here, maybe let's also animate this source as well. Let's add an transform node, and I'm going to add this after that. And in here, I want to just add the translation onto my this X direction, and I can just let me disable my this Db simulation at the very first frame, let's start with its zero value. Let's add Ake go a few frame forward, and I'm going to move this onto the positive direction, and we need to visualize this so that I can see what I'm doing. Let's make this onto the one unit, add another key. Let's go a few frame forward, and I'm going to change this to minus one, and let's add another key. Let's go a few frame forward, and let's change this back to zero, and let's add another key. Let's go into the flip solver. Let's go back at the very first frame, enable the flip simulation, and let's play here as you can see our source has been animating and we also distorting this with the mountain node. Right now, this fluid is moving down. Let's add an A viscasty in here. I want to create a very viscous fluid. I can do so by going onto the flip container. And by enabling this viscosty option, let's collapse this and enable the viscosty. And now we can define the viscosty value in here. I can say 100. Let's start with 100 and let's see how this viscosty is looking like. We will get an A viscous fluid like an A honey or chocolate. And here can see we have the viscus. I can continue increasing this. Let's change this to 1,000. That way we can create a very viscous fluid. Let's say, if I want to create an A caramel chocolate effat and heres can see we will see some of the layer happening once our source will go onto this side, and I think we need to also increase the viscosity, even higher value, I'm going to let's add another zero in here and let's play again. And now we should start to see some of the really viscous fluid happening in here. And Heirs can see we have this quite hard deformation because it is very viscous fluid. And we have this option varying viscosty enable the wearing viscosty, we can create an a viscosty attribute onto our source. And right now, heres can see we are creating this a some sort of layer type effect because we are using a very high viscosty value, and I'm going to just stop this inhere. I think our animation has been stopped. Let's it rewind and hit play. And let's see that in action, and here can see that is our viscosty let's see how this faring viscosty work. If this option is enabled wearing viscosity, which means that this flip node, we're going to use the viscosity attribute if the viscosity attribute is present onto the source. And right now we are not creating the viscosty attribute. I can create this. Let's go into the mountain before the mountain. I can add an attribute noise node, and let's connect this. And by using the attribute noise, we can create an noised up viscous attribute. Right now we are using the CD. I'm going to change this to float. Viscasty is a float attribute. In here, I'm going to type the name of the attribute that I want to create and I want to create the viscosty attribute. I'm going to change the range. Let's change this to zero centered, and maybe let's visualize the attribute noise. Let's click on this to add the visualizer, let's increase the amplitude and make sure to enable the minimum value of zero. And one so that our range is in zero and one. I can also animate the noise, and here is can see we have the animation. Let's lower down the element size and play around with the amplitude. Now that we have the viscosity attribute present, I can go into the flip solver and Hears can see how this viscosity attribute has been imported and onto the flip container, this varying viscosity is working. Now, this viscosity now will act as a multiplier. Which means that where we have the noise value of zero, we will not getting viscosty. Let's hit play and here you will see. Some of the part will going to be viscous and some of them will not. And that's how you can actually vary your viscosty and here as you can see. And I'm going to just not use this first maybe, let's hide the visualizer. Let's go into the viscosty let's click on this button, and that will hide the visualizer. Let's click on it and heres can see. Now, we do not have an A visualizer. And I'm going to maybe let's go in here and let's not use the amplitude value, lower down the amplitude value and make the element size to a bigger value so that we have the bigger chunk of the viscus and very smaller chunk of not viscus, the regular viscus, fluid particles. Let me stop this and let's disable this viscosty I'm going to go into the flip container and let's not use the varying viscosty. I'm going to use this plain viscosty attribute that is present in here. And let's lower down this viscosity value because it is a very high value and we are not picking up a lot more detail. I think that viscosity value of 100 is fine. I can go into my source onto my mountain node, and let's play around with its amplitude to really make this interesting source. And let's go into the flip solver and let's view result again. And now we should see some of the details into our source. And let's say that we are happy with this simulation. Now let's see how we can write out our simulation into our hard drive because you might be working with millions and millions of particles, and first, we need to write out our caches. And after that, you can add an a file cache node. Let's add a file cache. And the very first is for the fluid particles. And if I were to visualize this, if I were to add an annual in between and here can see, these are the particles that we want to write, and you can add a file cache and you can do so. And that is fine. But whenever you are working with flip fluid, there is a better way to write out your particle cache. And that is first, we are going to compress these particles, and that will create a very lightweight cache. And the way that we can do that is by using an a fluid compressed node. If you type fluid compressed, here's can see we have that node. Let's add this and we are going to connect all of them in here. And what that will do, it will going to pack our particle. Here's can see how this visualization has been changed onto box. If I were to middle mouse button, and here is can see now we are packing our geometry, and now I can just connect this in here and now I can write out our caches, and that will be very lightweight cache onto our hard drive. Onto the fluid compressed node, here we have the particle separation right now it is grade out because we are picking out this particle separation from here. And if you are working with the regular solver, let's say you have built your flip network by using the dub and you might not have access to all of this node, then you are going to just connect this very first And now onto the fluid compressed node, and it will still work. It does not need to be onto the soap level and you must connect them. You can do so. Let me unto the change. I want to remove this wire. You can do so like so, and it will going to compress your particles, but you need to go into the fluid compress and we have the particle separation and you must link this particle separation with your source. So you might have an Asurce in here, let's say, flip source. If you are creating an Asurce, you have the particle separation. Can either link this from there or you might have a flip object in here that said in a flip object, and here we have the particle separation. So this value must be linked with this particle separation if you are going to use the top net, but we are using this sp network, which means that this node will going to pick its particle separation from this fluid container, and we do not need to do anything. By default, it is fine. Now you can go into the file cache. You can define your location and write out your caches. And once your cache has been done, now you can convert this into mesh because right now, hers can see we have these particles. We do not have mesh. And to actually mesh this, we have node called particle fluid surface. Let's add a particle fluid surface, and there we have it. And this node, how to unpack this particle. If you are going to use the fluid compress node, and you might be working with these packed particles, you can just connect this in here, and this will going to just pick up all of our let me connect both of them. This particle fluid surface will going to unpack our particles and generate an a mesh for us. And if I were to view this particle fluid, and here can see it has unpacked our particle and our mesh has been there. I can hit rewind and hit play. And here you will see that our mesh has been generated. And right now it is heavy because it has to calculate the mesh every frame. And once you write out this fluid compress these particles, and then you can add another file cache node, and this time, you are going to connecting this particle fluid surface into there and you can write out your actual mesh onto hard drive, and then you are ready to render out your simulation. Let's go into the particle fluid surface and here we have some of the option and we can define right now we are generating the polygon soup and let's go into the filtering. We have the option to smooth out our mesh. If I were to enable this smooth, let's enable this and Here can see, I can now define the smoothing amount and that will just smooth out all of your detail. If I were to go back, here's can see. If I were to uncheck this, here you will see that we are getting all of these bumps and if you were to enable this smooth, it will just going to smooth out your mesh. You can define how much smoothing you want to apply, and we also have the option to dilate our mesh. Let's enable this. What it will do, it will going to expand our mesh, and it's also going to add an A erosion we are dlating as well as eroding our mesh. I'm going to, let's say, uncheck this erode. So both of these values are right now link, and it will generate an A high resolution mesh when you are working with high resolution particles, when you are working with a lot more particles. It will just even out your detail. You can also uncheck this. If you don't want that, you can disable the diet, and onto the region tab, we have this container and all of these options that we are not going to talk about. Let's go into the surfacing and in here we have the option for the adaptivity. Right now, hers can see we are generating this adoptive mesh. And if you were to increase this adaptivity, Heirs can see we are adding more polygons where we have a lot more deformation and we are not adding more polygons where we do not have to. And we are creating this adaptive mesh, and it is a very lightweight mesh. And all of the default values are just fine. I'm going to just change this to default adaptivity. And after the particle fluid surface, you are basically ready to write out your cache. And then after that, you can just create an A null node at the end and create an A out and dive inside the lob net and assign the material and render out your fluid simulation.