Create AWESOME Surface Effects with Geometry Nodes in Blender!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
all right so hi everyone in this video i'm going to show you how to create a really interesting surface effect using geometry nodes in blender and this kind of goes along with what i've been showing recently because i've been developing the new version of the biogen add-on and one of the new features of that is being able to select a surface effect and paint it onto a pre-existing mesh like so so this means you can very quickly and rapidly build up really cool looking hyper complex services on pre-existing objects so that can really help you to experiment and speed up your workflow but before i show you how this works i need to let you know that this video is sponsored by nvidia and pc specialist they're teaming up under the nvidia studio initiative to design products for creative professionals and if you take a look at the link in the description there'll be a page on the pc specialist website where you can take a look at the nvidia recommended specs so you can design your own custom computer and you've watched my last video which was about designing my own ghost for destiny 2. you know that they sent me a new computer which will help to enhance my own creative projects i've seen a huge render speed improvement so if you want to get your hands on your own machine like this then check the link in the description so this technique of being able to paint a variety of mesh effects onto an object is something i've been a bit obsessed with recently because i love doing these repeating abstract structures and it just seems like the perfect addition to the biogen add-on if you don't know biogen's my free add-on to help people do generative modeling in blender but this effect is quite easy to set up because the way the system works is we're essentially just taking the geometry input of the object getting a bunch of points from the surface providing a collection as an input which has all of our source meshes like these tiny cubes and these tangle curves in between and then we're instancing those objects on the points gathered from the surface randomizing them in some way with a seed value to choose the different objects and a random flow value to control the scaling of the individual objects and then we're merging the original surface with the new generated result so the principle is quite simple but there are a few key things to keep in mind when designing your collections for these surface effects because if i zoom in closely you can see that these surfaces are actually much more complex and they look further away because what we essentially have here is this spaghetti like mid structure underneath the cubes and the cubes are becoming the extra surface element poking out the way you design these objects will have a significant effect over how the surface looks from a distance okay so i've opened a new clean file here and i'm going to take you through the steps of getting those point distributions going around the object and then how to be able to paint the new effect on the surface and this is the equivalent of the new feature coming in by jen where if i choose this tangle mode and press apply with weight paint i can then immediately paint the effect on the surface then i have control for scaling and things afterwards so let me reset that if you have your object selected there are two things you can do to make a new geometry nodes tree you can go to the add modifier and then choose geometry nodes or if you have the geometry nodes window open like i have on the left here you can just press the add button and they'll make a new tree so let me bring this over a bit and you can see that quite simply we have our geometry input plugging straight into the geometry output so what we're seeing is just the mesh by itself if we want to grab points around the object all we need to do is press shift a and type in distribute points on faces and if we click that in quite simple the geometry goes into the input for the node and then we get points as the output and you can see roughly that these points are going around the surface of the object if i scrub up the density then you can see how we get more and more points and it's starting to kind of make up the shape of the object so that's how we get our distribution for where we're going to instance the other mesh objects on top then if we wanted to instance objects on that points quite simply we'd go to instance on points and put that in here now we're not instancing anything on this yet but you can see how this works logically we're taking the points that we generated and we're plugging into this node and then we want to provide it with something to instance like a different type of object and then that's going to plug into the geometry output now you see that i've got a few extra objects lying around here so why don't i take one of these if i make an object info node hover over this value here press e and then click on my cube down here that's going to put it into the node and then if i plug the geometry into the instance you'll notice that now it's instancing those cubes around our original object now we can play around with the scale like this so we can make them smaller and do all kinds of whatever weird effects we want but that's not quite what we're looking for that's a bit simple so let me just reset that scale now an important point here like the particle systems is you don't have to use single objects as inputs you can instead use collections which is very important for what we want to do so if i add the collection info node and then if you look in the top right i have a collection called source and that contains all of my little objects here which i'll explain later so if i click on this and choose source and then plug the geometry into the instance then we have this weird stuff going on we have all of our different types of objects but they're being displaced and they're very weirdly laid out two things we need to do here take both of these tick box on the collection info node separate children and reset children and what that's going to do is it's going to move them onto the area where the mesh is now this doesn't quite look right and i think he's trying to instance every object on every single point which we don't really want but to visualize this better i'm going to randomize the scale and that also gives an opportunity to scale it down at the same time so if i make a random value node and have it set to float which it is we could technically plug this straight in but for the sake of exposing the different values in case we wanted to randomize them in different ways i'm going to add a combine xyz node here plug this into each of these and then plug the vector straight in there so if you wanted to do the axes differently if for some reason you're doing an effect where it was stretched out in a certain axis or you wanted to animate that for motion graphics then you can just remember that you can control the scale for the axes separately here now with the minimum value set at zero it means that some objects will be infinitesimally small so they won't show up so i'm going to set that up to something like 0.15 i would think and i'm going to turn the larger scale down so now we have these clusters of variable scales some are smaller than others and yes it does seem that every object we have in that collection is being instanced on every single point which is not what we want because that's not going to give us a nice amount of variety so i need to randomize which objects are being selected for every point and to do that we need to plug something into the instance index an index is basically a key or a number essentially for every object that exists in a list so take a look at our source collection up here you can imagine that for each of these objects the index might be something like 0 1 2 3 and 4. because with code and programming the first item in the list tends to start with zero so you work up from there so essentially what we want is a random number between the first and the last item in the list and we're going to plug that into the instance index so every time we have a point it's going to choose a random object from that collection to put there so again to do this we would make a random value but this time instead of a float we're going to set it to an integer which basically represents a whole number so one two three four then if you plug this value into the instance index we'll notice that it's still not choosing random points but then if we tick pick instance it's now going to choose them now technically you don't need to have this random value here you could just take pick instance but what having this random value does is it gives us a seed value so as we change this we can randomize the order of the selection now this can come in handy later on because sometimes you might have a layout where something is sticking in a weird way and just changing the seed value by one value fixes that issue so having the seed value is a very useful thing so one thing we could do is move the seed value outside so if i plug that in here then if you check the modifier stack i can scrub the value here and that basically changes our seed so we have these random objects scattered around but what happened to the original object our original character what we want to do is combine our original character model with these instanced objects so to do that we'll make a node called join geometry and here we'll plug our instances and we want to grab the geometry from the input node but that's all the way over here so what i'm actually going to do is duplicate the input node now if you didn't know that already you are allowed to have more than one group input node then i can plug the geometry into the join geometry node and then plug the result of that into the output and then you'll see we have our original character and the instance objects but this is still looking all weird and nothing like original result if i come back over to the original file you'll see that this is so much cooler you know we've got this effect all tightly packed and scattered and it looks like a proper surface so how do we get from our weird scattered result to that effect well there is a couple more things we need to do i'm just going to pack this over here to keep it nice and tidy so one thing you'll notice is that none of these objects are pointing towards the character they all have exactly the same rotation which looks a bit strange especially where we have these curve points kind of floating out into mid air and we don't want that if they're going to make up the surface of the object they need to be pointing towards it well something you can do quite simply is take the rotation output of the distribute points on faces and plug that into the rotation of the instance on points and you'll see that they start to point towards the character it's not perfect especially where we have some of these curve objects that come off at weird angles but we can talk more about mitigating that effect later so now we have them roughly on the character how we're going to turn this into a more dense surface well again with the density value on the distribute points on faces we can just turn that up and as we do that we're going to get more and more of a surface effect going now i'm going to take this to an extreme value so i'm going to do something like 1500 and we can start seeing that the entire object is covered it's quite intense let me turn down the scale a bit now it's quite messy but it is a cool surface effect so if i go into the rendered view here i have a special material applied to these by having the density high it looks like it's making up an interesting surface now i'm going to bring these original objects up close to the character so i can explain details compared to origins and that will make sense momentarily so if you have your original objects in a collection there are a few things you need to keep in mind so the position of the origin of the object in relation to the mesh content is important because that will dictate where the mesh is going to intersect to the original surface so if i bring these closer to give you a demonstration if i choose this one curve object here go into edit mode select the handles and then move it lower down from the origin you might be able to slightly see on the left there but as i'm moving this up and down that object is moving further away and closer into the surface if i move it too far below the origin then it's going to go inside of the body which we don't really want so we need to find a balance area where some of the object is moving below the origin and some of it is above so you'll notice that for each of these curve objects the origin is horizontally somewhere in the midpoint of the object so when thinking about the distribution of details if you wanted some large medium and small scale shapes think about it in terms of levels these cubic objects have flatter surfaces so there's more of a surface area to show if i wanted these to be more obvious than the tangle shape what i should do is go into the vertex mode choose all of the top vertices and push these higher out so what it's going to do is make them come out further than the curves so then if i look at the surface what we have is these cubic objects poking out and this tangle of work could be wires below those objects and then theoretically if you wanted a larger scale of shapes again thinking about the distribution of detail we could do a second of the objects make it larger and then pull out these vertices even more to have them become the next layer now this is a bit of a messy demonstration but what i'm trying to demonstrate is that you can have different layers of details and different scales that can be made obvious by having them on different levels now i'm going to make this slightly more interesting by pinching some of these vertices so i'm going to select these end ones here and bring them together on the x-axis so we get more of a triangular shape so i'm basically improvising and making something new here and i think that would look quite cool for a final result so now we're going to move on to the weight painting so how do we restrict the influence of this effect onto just the body well first thing we need to do is make a vertex group so i'm going to go into the solid view into the object data properties now i've got vertex groups here for the different parts of the armature i've already got one called group that i've set up and i'm going to make a new one for you so i press the plus button here i've got group.001 i might call it weight group just to keep it simple so we know this is a group we're modifying so what we want to do is have this vertex group become an input for the geometry node tree this is actually surprisingly simple all we need to do is drag this input creation point here this socket that's ready to be made into an input into the selection input of the distribute points on faces what it's going to do is turn the selection for the faces that we want to have points instance on into an input and if i press n and choose the group input go into group and then take a look at the selection we can see that this is a boolean value by default and we can confirm this on the right here because the selection value only goes between zero and one and this basically applies to all of the faces on our character so zero meaning that no we don't want this to be selected and one yes we do but how can we change this to a vertex group where we can get that value for every single phase so zero for this face but one for another and zero for another and so on well if you press the button to the right of it which is the input attribute toggle that will change it from a boolean value to a string pretty much and then in here we can type the name of our vertex group so weight group so now our vertex group is the input which defines the selection which the points will be generated on consequently meaning that our mesh will be put on those points so now we can start painting so i have my character selected in the top here i'll go from object mode to weight paint and i'm just going to make this note group visible here so you can see the whole thing at once now with the draw mode selected i can start clicking and dragging around our object and you can see that we're now painting the effect on so if i toggle the overlays and start rendering you can see how the effect is only happening now on this part of the object funny thing is i can now paint in the rendered mode so literally as we're watching it being rendered i can create this effect across the surface and if you zoom in you can see all the details there with the curves tangled in between and because we've got quite a high density we can get fairly finite with it as well but what i'm going to do is put it around the character's torso and kind of come up the neck a bit okay so here we go this is a basic representation of how you can create a complex surface effect made up of multiple separate meshes with different scales and levels and then paint them onto a character so i bring the objects back up again i'm going to scale them down to make them a bit easier to uh see here and we don't even necessarily need to worry about the rotation until we apply it using ctrl a so i'm going to have them rotated so we can tell that basically this is our selection of objects which is making up the surface so while we're looking at our character we can modify these in real time because the geometry node is calculated in real time so you can see that as i modify the height of this object it's changing on the character so i can lower that and you can get creative with making all kinds of different effects by modifying what source objects you have now because the note 3 is picking a separate object for each point we have every object you have in the collection is going to reduce the chance that another one is being selected so say i delete our larger object here and start deleting the cubic ones we're going to get more of the curve selected until we have only curves so that's one thing to keep in mind and that gives us a completely different effect now it looks like we always have a wicker basket effect going around the character what if i do the opposite where i remove the curves instead well then we just have the cubic elements and we can start doing some other fun things what if i insert this and try and make a bridge between them so i've made a hole through the object and then we can see that represented as well now this isn't just good for making interesting compact surface effects they can do a lot of other stuff of it as well so if i remove this geometry nodes tree click on my object open up biogen version 9 and choose the barnicles demo then if i apply with weight paint i can then paint barnacles onto the surface now these are quite large at the moment so i'm going to scale them down i don't have a good material for them at the moment but basically this effect is also good for scattering objects over a surface so you can see that i'm essentially painting barnacles onto our character now let's put some around his face i'm sure that's very attractive and if i go into object mode i can take the material that's applied to the barnacles and change it however i like to get some weird and gross effects going if you want but hopefully that's an interesting introduction to geometry nodes and how you can scatter objects to make interesting surface effects and all kinds of other scattering effects okay so for the last section of this we're gonna take a look at my more artistic demo which is slightly more advanced here i have a world volume going i've also got the denoising going as well just to help me visualize the scene thanks again to nvidia now if you watch one of my recent videos about tips and tricks in blender one of the things i pointed out was the power of the ambient occlusion node so i'm actually going to turn off the world volume just to have a look at this close up here i have the surface effect by itself and the material here in the bottom left and by itself it looks interesting we can just about see the character mesh underneath the surface here which is red but i want to make this effect more interesting and one way to do that is take the ambient occlusion node with a ramp like a color amp plug the ao in and then plug that into the base color and then we can bring the black valley for the ramp up and then you can see that in between the areas of the different objects it's now being darkened so basically enforcing a shadowing effect in between the different points by itself if we bring this all the way up it can look quite comic booky again depending on the surface effect that you're creating but that also gives us control over the color as well so say add a new handle in between and then give that something like a blue we are now adding a blue element in between the shadowing and the white upper area and you can get more and more creative with this as well so maybe i'll put like a red somewhere in here as well and i'll bring that closer to the white maybe even i'll remove the white from the top so we have red coming out i think it's really interesting using ambient occlusion where there are so many areas of repeating elements because it's going to make so many intersecting objects so we're going to have so many areas for interesting shadowing to occur so plugging the world volume back in we can end up with an interesting surface now for the upcoming version of biogen i'd like to have a range of surface effects which are both useful like kind of realistic and artistic so more abstract as well and stylized so people have a nice variety of things that they can work from so hopefully you found this interesting and if you haven't touched geometry nodes yet then maybe this can put you on your way with making some really cool effects and if you do give it a try make sure to show me what you make because i'm interested in seeing what kind of results you can come up with remember this video is sponsored by nvidia and pc specialist they're working together to design products for creative professionals when i'm making renders with blender i rely so heavily on the cuda and optics render devices so i have a lot to thank nvidia for in terms of giving me the performance that i need and if you're interested in getting a new computer or designing your own new machine then if you take a look at the link in the description you'll see a list of nvidia's recommended specs like i said they also provided me with a computer which i've nicknamed the render beast and this is basically representation of what you can get from the pc specialist website i will leave the major specs on the screen here just in case you want to recreate it yourself yeah hopefully you learned something interesting give it a try well i like how that looks it's kind of like some broken machinery or circuitry i might keep that in mind anyway have a nice day and i will see you next time
Info
Channel: Curtis Holt
Views: 20,277
Rating: undefined out of 5
Keywords: geometry, nodes, blender, surface, effect, procedural, tutorial, free, bygen, by-gen, layers
Id: AMuwvRJIVUA
Channel Id: undefined
Length: 17min 17sec (1037 seconds)
Published: Tue Nov 02 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.