Rock Generation - Houdini For MoGraph Ep0011

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Applause] [Music] hey there folks welcome to the houdini for mograph tutorial series this week i'm going to show you how to do some procedural model generation of rocks we're going to be going through how to make these rock wall that i have in the example but i'm also going to show you how to populate a scene with rocks with just a few additional nodes so let's get into it all right first off we want to establish the shape of the rock wall so i'm gonna make a box and use the expression to keep the bottom at zero and just give it a bit of length so that it looks like a section of the wall so we want the rocks to look like they actually fit together with little intersections so we're going to use something called the voronoi fracture this node is used for a lot of destruction setups but what it does is it takes a piece of geometry and it breaks it up using the points that you make in this second input so you're going to get some really cool looks if you just mess around with some different point setups so we're going to use a points from volume for our wall the reason that we're doing this as opposed to a scatter node is that the varnish fracture works by making a piece centered around the input point so we want the rocks to be inside this volume not just up on the edges so i'm going to hook that up to the second input and just mess around with the jitter a bit and you can see that we have some cuts in the geo which is great so i want the rocks to be a bit longer than they are wide so i'm going to transform the geo before the points from volume and then copy that parameter make a new transform and paste that parameter and then enter 1 divided by before it so that it scales back to normal for a more low poly or stylized look these rocks could actually be exactly what you want but i'm going to try to add a little bit more detail into them for our purposes we're going to use a for each loop so that we can give each rock just a little bit of variety so use the 4-h primitive option and if you look at the primitive attributes you'll see that we have this name attribute that was generated by the voronoi so just enter that as the attribute to loop through now i'm going to set this to single pass since it's going to get a little heavy and just find a rock that i like okay yeah we'll work with this one all right so now first i'm going to drop a smooth node and just set that a little bit to relax the points then i'm going to remesh this to give us more geo to work with adjusting the target size to something around 0.2 and then i'm going to do another smooth just to round out some of those corners that we have now i want to start giving it some shape so i'm going to drop a point pop and dive inside here you can get real creative and really start messing around with different noises to add detail and just find the look that you like i like the way that the whirly noise looks so i'm gonna make that promoting the frequency and the offset then use a displace along normals node wire in the p and the n and let's use this dist 1 as the amount and then promote the scale and wire this to the out position now i'm going to bring the scale way down frequency up a bit just to get something that i'm happy with then i'll subdivide to smooth it out again and now i want to add uh some finer detail in there so i'm going to make another point pop drop in anti-aliased noise setting it to 3d and add that to the position and promote all those parameters this one will stay pretty low since i'm just using it for like a nice finer detail the noise nodes are really setting the shape so definitely explore all the possibilities here add more noise before the subdivisions after it try out different noises here's where you can really take these and get a real high level of detail if that's your goal i'm just going to drop a normals node now and then turn off single pass to see what we've got going to take a second and there is our rock wall one thing you might notice is that the noise is being applied evenly across the whole thing making it look kind of fake so to fix that i'm gonna put houdini into manual mode here what this does is prevents it from updating the viewport i'm just doing that so that we don't have to wait a second or two for every time we want to change something so go back up to the top of the 4-h loop and click create meta import node and name this info and if you guys are unfamiliar with this you can go check out uh one of our earlier tutorials that's on just4h loops to learn how this works now i'm going to type our detail expression into the offset of the noises so detail grab that info node set it to look at the iteration and point zero okay and i'm just gonna copy this down here turn off manual and voila we've got some randomness which is making it look more natural cool so at the top of the tutorial i said that i was going to show you how to populate a scene with these rocks so i'm just going to copy over this whole setup and then in the for each i'm going to add a transform in the positions we'll use some h script typing minus dollar cex which will center it in the x position now do the same for the other values just changing the x to y and z and now i'm just going to drop a pack to make this easier to work with and you can see all our rocks are right here in the center so now we're going to use the copy stamp setup we used in a previous tutorial so i'm going to make a grid and scatter some points onto it we want to make an attribute so we can grab each of these random pieces so i'm going to middle mouse here to see how many rocks we have and then make an attribute randomize naming it to type set the dimensions to 1 distribution to uniform discrete and we'll put that max that we just looked up here now make a copy stamp node turning on stamp inputs and tell it to look for our type attribute make a blast node enter the stamp expression to look for our type attribute and then set it to points and delete none selected hook all these up and there you go you've got rocks scattered across a surface now of course you could mess around with p-scale normal directions to add a bit of variety but there you have it that's just our intro to rocks i hope you guys enjoyed this one you can download the project files off of our site and until next time
Info
Channel: LoveDo
Views: 1,175
Rating: 5 out of 5
Keywords: houdini, sidefx, mograph, motion design, motion graphics, design, animation, cg, cgi, 3d, tutorial, beginner, new, computer graphics, education, how to
Id: LVFqjO4sXTg
Channel Id: undefined
Length: 8min 20sec (500 seconds)
Published: Mon Apr 05 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.