Introduction to the new Geometry Nodes in Blender

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
geometry nodes is the biggest thing to happen to blender since left click it not only lets you achieve things that were previously impossible but it also gives you the artist much more flexibility to create complex objects and interactions with speed and geometry notes is just the start of the much larger everything nodes project future releases will add node-based systems for working with particles simulations and even collections since development is ongoing and constantly changing this tutorial will focus on something small but common which is scattering objects in our case scattering some sugar crystals on a little gumdrop but the exact same method could be used to scatter anything like the new rocks from polygon professionally scanned from locations around the world that go great with our new plants and photo scan grounds sand dirt snow and grass materials so start creating better vendors today faster by signing up at polygon.com or clicking the link in the description so geometry nodes can be added to any object like our starting default cube here and the way you access it is by changing any window like this timeline here to be the geometry node editor which is it's got its own little node editor so click that and you won't see anything until you click on new now if we zoom in here you can see we have something pretty familiar if you're familiar with shader nodes anything like that you've got an input and you've got an output and basically much like a conveyor belt it's moving you know in one direction okay and so yeah using the conveyor belt analogy right you've got uh you know a plate of food on this end and then like as it goes along like a node will like add something to it and then another node will like change that scale of that thing and it'll go along and it'll you know do a bunch of stuff and then what you end up with at the end there is what the actual geometry will look like so that's the that's the basics of nodes just in general right so for example we could add in right here a transform node which could be used to you know add rotation to our cube we could um let's say move it along the x-axis a little bit we could scale it a little bit we could do a bunch of stuff with this but if we go into edit mode you can see we've still got our original cube okay so these operations are happening after that because we start at this end with our edit and then we end up over here with uh with the final object okay so um oh gosh turn that off uh so yeah so you could you could combine it you could do some interesting stuff like a boolean operation right you could perform a boolean operation on itself right and now you've got like some fun stuff that you could do right geometry nodes is cool you can do a lot with it okay so in our case what we want to do though is the most common thing that everyone wants to do when they start with geometry nodes is uh scatter stuff because also that was actually the goal of the first implementation of geometry nodes was to create a uh scattering sco scattering stone demonstration so if it can do that it means they hit their goal and yeah that's why everyone's doing scatter stuff anyways so what we want to start with is and by the way i'm hitting shift a to bring up this add menu if you want aware but we want to start with a point distribute node and there's no reason you should know that so don't feel bad points distribute we want to plug this into our geometry and we won't see anything until we take this and put this into our geometry output okay so it always has to be connected to the output in order to see it and when we do that with this density value here you can see we get a whole bunch of points but we have lost our cube and the reason for that is we have replaced the geometry with points and now we've just fed you know points right so if we want the cube as well which we do we want to combine it with a join geometry node okay which is something that you end up using a lot because you do a bunch of stuff and then you want to combine it with the original so you join it together like so and by the way my join node will look probably different to yours if you're using 2.92 and that is because there is a new input that will actually combine things in 2.93 on um so basically you can you can cram as many inputs into this uh this thing right here it's not just like yeah it'll accept as many inputs as you throw into it which is really cool i love that idea for a node so yeah anyways look at that got some points so we want our points to become sugar crystals so first of all we need to create a sugar crystal for it to instance so i'm going to add in a cube move this to the right here scale this down like so and since we have changed the scale as well you can see our scale values have changed i'm going to hit control a and apply the scale okay so um what we need to do is after our points have been created because that's what this is doing you could almost call it the point creation node instead of distribute but anyways we want to instance something and there's no option to do that in here it's a separate node so we're going to hit shift a point point instance okay and drop this in right after it our points have disappeared until we click our little eyedropper here and select an object the cube so now all those little points have become a cube very easy now the scale of this matches one to one of these which by the way is great um using the old particle system you could never get the scale exactly right you had to kind of match it up and guess but this is an exact one to one which is cool but let's say we wanted to change the scale and like yeah we could change the scale of that but it's annoying to have to like apply it and you know yeah it's just annoying right so yeah how would we change the scale well there's a number of ways that's what's really cool about geometry nodes is it's really flexible and one way to do it would be to add a point scale node which is pretty self-explanatory you drop this in right here now by the way the order of these things like you might be thinking like how would i know to put it in between these two things that could equally go after it and like yeah i guess um but i guess after it's been instanced it's no longer a point anymore it's like an object right so in order to scale the points you have to put the points anyway you sort of learn it as you become more familiar with it what sort of order is um it's very new at the start right don't feel bad if it's like oh i'm overwhelmed anyway the point scale this is how we uh that's how we change things okay so um it hasn't done anything currently our points have just disappeared and the reason for that is a point scale by default will scale it according to an attribute which you would put in here now we'll talk about attributes soon um but an attribute can be anything in our case well in this case let's say you want to just scale it along a single value vector is what you would be after now vector gives you three values and the reason for that is that there are three axes the x-axis the y-axis and the z axes okay so you can scale it on each of those independently do some fun stuff or you could click drag down and then you can scale it along all three at the exact same time okay now that's cool and all but generally when you are instancing something you don't want them to all be the exact same scale if it's a rock if it's a tree if it's a whatever you want it to have some slight variation between it okay so we're going to remove that by hitting control x which will delete a node but keep its connection handy tip and i'm going to hit shift a now and not in points here we are instead going to go up to attribute and there's a whole bunch here there's a whole all these nodes are pretty fun to play with but uh the attribute randomized node is what we are after and we're going to drop this in here okay now again hasn't done anything but looking at it you'll notice you've got a bunch of words at the top float replace create whatever you get more advanced as you go along i'm sure but there's two values here minimum and a maximum value which is really good and that's what we want however nothing has changed and the reason for that is that this is an attribute node meaning we have to put an attribute in here for it to drive something okay because otherwise it doesn't know what to drive what are you trying to randomize okay so um sometimes you'll see the value would pop up there depending on i think if you've referenced it already along the chain and i think also this is a 2.93 feature that the pop-up appears otherwise you have to manually type it in scale and when you do that it now knows scale is something uh to reference and now it has scaled it randomly um now the usability of this like i actually passed on that feedback to uh someone at the institute like yeah it is a little daunting to have to know what to type in before something happens um so i think the drop up the drop down helps with that but in this case it didn't include scale so i don't know what's going on anyways um so this is cool the cool thing about this little you know what i like about it is like you know unlike particle nodes or what a particle particles and particle instancing is you've got like an actual value here i know that like the start of it is going to be this value and the maximum is going to be this value you don't have to like guess and do everything by i it's uh it's actual values here which is really handy once you're sort of like figuring out like you know okay the the smallest size of my crystal i want there to be is sort of like that size but then the largest size i want it to be like maybe 3x that so something like that so you can kind of do that whereas with particles it was really hard to figure that kind of thing out and you've also got seed value right so you can change that to anything and it'll just randomize it and pick a different one to make it big or small pretty cool right so um that is one randomization what about rotation which is the other really big one that people generally want to randomize when you're scattering something so let's move this along and we would drop it in right here next to it or before it actually it doesn't matter scale and rotation could be either or so i'm going to duplicate it just move it to the right and now this value this one does actually pop up i don't know why but it's rotation if you don't see it pop up just type it in manually make sure that it's spelled correctly rotation and you should see that we've now got some random rotation now something to note is that this rotation isn't exactly random okay because there is three axes in which it can rotate on a float value will not rotate along all three axes it's sort of doing it i don't know is it doing it evenly across all three at the same time or something anyway what you want to do instead is change this from float to vector and just like before you've now got three of these values to change from zero zero zero one one one as the minimum and maximum and also to really confuse things um these values oh i should have looked it up before i started i was going to do that but basically it has to be any value over pi which i guess is like 3.4 something in order for it to do a full rotation so whatever these values are is based on pi i don't know anyway generally all i do is i just click drag down and then just go with my mouse right and just drag it to the right anything over three or whatever will randomize it i don't care what it becomes um just so more than so long as it's more than 3.4 and look at that we've got randomization everywhere and uh just quickly as well if you were perhaps building a scene using some of the new rocks from polygon and uh you wanted to rotate objects just on the z axes and not have the rocks flip around or whatever um you could do that just by rotating the bottom uh value there which is the z axis which is cool i don't know how like in particles every time i was like building a scene that needed to like rotate trees or something on that axis and be like oh how many like i could never remember the exact like whether it was normal or tangent and like which one to was the rotate it was so confusing i could never figure it out but anyways it's easy now so we've got it rotated it on all axes which is good now something to note with geometry nodes is that geometry nodes is yes it is influencing the mesh here but it is actually a modifier so if you go to the modifier stack you can see that our geometry nodes there is uh is appearing and if you were to do you know normal stuff with a modifier you can disable it appear it make it disappear in a render or etc but you can also add stuff before or after it so if you were to add a subsurf modifier it'll slow down a little bit and it's now subdividing the cube as well as each of these little points individually right so you could rearrange it see it's pretty cool and also there's by the way a sub surf modifier inside the geometry nodes that you could use as well but anyways something to note is that uh it'll disappear geometry nodes will disappear if the modifier is not actively selected and selected is a new thing for modifiers by the way um didn't used to be uh but now you can select things inside the modifier stack so when it's got this blue outline on it that is selected so yeah that was something that i came across when i was using i was like where's my modifier like where's my geometry nodes going i'm like clicking i'm moving around and uh yeah it yeah it's because it wasn't selected so it is annoying because generally i only have one node sorry one geometry node thing selected for the whole time i'm working anyway so you can click this little pin icon and that way you can you know select and do things and it'll always remain there so that's handy okay but let's talk about something else that's really cool with geometry notes you can expose a value all right so for example this density value here is a value that i might want to change later on so i'm building a scene and whatever and i realize i need more or less rocks it would be cool if i didn't have to you know open up geometry nodes and like oh where's that node which is the one with the density and then find it well you can expose it by clicking and dragging to the input right here where it's got density max and now the value there has has gone but it has appeared over here isn't that cool and to make it even cooler if i hit the n key and finale with that node oh sorry with uh this selected yeah has to be no it doesn't matter which one selected um you can see that uh i've got it there density max is what it's called but i can double click it or click this and type in a name for it that i would be familiar with sugar amount okay and look at that so you can see this is really handy once you're building like a full scene and you've got like rocks trees plants and a bunch of other things like you could have like different values for different things in fact the actual scattering stone example that was uh is provided on the blender.org homepage it shows you exactly that so they've labeled things and you can see how an artist would really love a tool that's well built because you can just go through ideas really quickly which is great so it's awesome okay now we want to start making this look like uh um what do you call it a gum drop i keep thinking it's called a jube like a sugar jube but that's not is that a thing sugar jube i don't know maybe it's an australian thing i don't know but one thing to note though is that our um cube here our gumdrop currently is two meters by 2 meters which wouldn't be very good so let's scale this down so a gumdrop i haven't seen a gum drop in years i don't know where they went but i'm guessing at most it's probably like 2 centimeters so with my dimensions here i'm going to click and drag down and i'm going to type in 2 centimeters i don't know what that is in inches penny farthings or whatever it is you americans use about the size of one nickel i don't know but it's about that that big right um now because we've changed the scale i'm going to apply the scale control a scale and what the hell just happened now sometimes when you do this you might actually see that all of your particles like thinking of them as particles their points have disappeared um and what's actually happened is is that they are still there and actually let's just let's move this sugar cube over do scale it down to be relative to the size of that apply the scale okay so it is there all right we have one no we have two two little sugar cubes why is it no longer reading our sugar amount value there right like why is there not 300 sugar cubes there that was my question why is there not 300 well it's because you're still thinking of that as particles and it is not particles it is points and points are based on the volume the size of the world okay and how much how big your object is in that volume how much space it takes up so if i was to scale this in edit mode and just scale this up you would notice that as you scale it up more and more and more points appear on it okay whereas then when you scale it down and down and down the points reduce reduce reduce until it is what it is which is two centimeters right um so i find it actually helpful this is a weird analogy but think of it like bug splats okay and like a highway if you've got a truck the bigger the truck the more bugs are gonna splatter against it whereas the smaller the car is or a bike or whatever there's gonna be less chance of it hitting a bug to the point that it's not going to hit any right that's the way i think of points and the density right it's the density is how many bugs there are and so therefore uh if it's a small thing it's not going to hit any right so anyways that i don't know if it's gonna make it confusing like when we get to like you know i want exactly 10 rocks to appear on my plane here like what density value is that i don't know um somebody did mention on twitter there might be a value in the future for like points per face which might make things easier but for now you know it's this now the problem with this is that when you're working with an object of this tiny small scale what i'm doing right now is i'm moving my mouse and i'm dragging up over here and i still haven't got nearly enough sugar on it right and also what the problem is is like once you get to around about like a hundred thousand particles or something it's like it's hard to count like how many zeros is that is that four or five zeros you kind of have to and it's annoying and i was thinking like oh this is annoying i wish i could change this to like a value of like 10 and then have it multiply and then i went aha geometry nodes i can do exactly that thing so let's change this to a value like 10 and then add in a math node right here drop this in and then multiply it by any value we want 1 0 0 0 0 and now i have some values here which would actually make sense to me and i can move my mouse left and right and it is multiplying it by that amount which is what we do because we're working with a really tiny tiny object and we need to have some dense points on it so um so there really cool and actually i i discovered also that's exactly what they're doing for the uh blender demonstration file with the stones is they had a multiple thing as well and i was like ah all right i'm on the right track so anyway very cool um whoops yeah ten thousand make sure it's yeah sit around there okay let's make this look a little bit more like a sugar jube gumdrop i'll move this up let's uh increase the sub surf and how do you make it look like a sugar tube well all you got to do is inset the bottom face so if i just inset it slightly it's now going to wrap around it and you can see it starts to look like a little gumdrop and i can take my top face move this down squash it and then scale this in ha ha wouldn't you know it we have a gum drop um now a really simple thing we could do to improve this all these little sugar crystals look the same because they're all copying this one object and that's not the case with sugar crystals some of them can be like long and short or whatever so first of all sugar crystals are generally beveled so i'm going to hit ctrl b on this and just give a little bit of a bevel that's it then i'm going to duplicate it and i'm going to create uh i'm going to make make a couple of them of sort of like different sizes and shapes which i'm sure everyone knows how to do that's like a flat ish looking one and then i'll do one more and then i'll actually like create like a clump right like something like uh i mean i'm trying not to like ruin the bevel so i'm trying to just select one of these parts like this okay and then i'll hit l and then let's move this around so i just want to create yeah the appearance of like a clump of crystals because i noticed that when i was looking at references that it can sort of look like a clump but anyways uh i'm sure you are familiar uh you could probably guess how to do this because obviously it's just still copying the one uh and that's because it's just referencing an object uh we want to reference a collection so first of all let's move our sugar crystals here to a new collection let's go m and then go new collection sugar crystals hit okay and then collection select sugar crystals and then by default it's going to reference the entire collection i don't know why that's the default but we want to change it to just individual objects randomly and look at that it starts to look a little bit closer to sugar crystals on a gumdrop and while this is mostly a geometry nodes tutorial i do want to quickly show you how i set up the scene with the lights the plane etc to get that lovely gumdrop look most importantly the sugar crystals you need to select them and just uncheck shadows so it doesn't cast a shadow give it this material and the most important one of all is the gumdrop which is this material now normally i would explain things but that would make this tutorial twice as long as it already is and we just want to focus on geometry nodes so copy this if you want to follow along and get that exact result otherwise in the next part what we'll be doing is using texture to drive where those points actually appear and then also using another texture to drive like big and small shaped particles as well so doing some more advanced stuff with geometry nodes so click here to join me in the next and final part of this little mini series and i will see you there
Info
Channel: Blender Guru
Views: 509,982
Rating: 4.9694629 out of 5
Keywords: blender, tutorial, geometry nodes, blender 2.92, blender 2.93, gumdrop, sugar coated, crystalized sugar, scattering, attribute
Id: 52UYqe3zdxQ
Channel Id: undefined
Length: 23min 4sec (1384 seconds)
Published: Thu Apr 01 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.