mstarktv Posted July 9, 2016 Share Posted July 9, 2016 I may be missing something in the voronoi fracturing SOP, but I can't figure out a way to create clustering without causing fracturing on the geo. For instance. A standard brick will or just group of geo that clusters into groups using the scattering method so I could make the cluster groups bigger or smaller. I feel like I'm overlooking something so obvious, or maybe I have to create proxy geo that is clustered and test if the brick particles are inside of it to group them? Ah, now I've just confused myself. I hope a few of you have run into this problem and have some incite. Thank you :D! Quote Link to comment Share on other sites More sharing options...
Malf Posted July 10, 2016 Share Posted July 10, 2016 You should check out the 'cluster' and 'clusterpoints' SOP nodes. They preform pretty much the same functionality as what happens inside the voronoi fracture node. I tend to use this method for clustering even when using the voronoi fracture node, to assign clusters to the points before feeding them into the fracture. Cheers Jake. 1 Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 11, 2016 Author Share Posted July 11, 2016 i'll give it a look. I'm still new to Houdini, so it's not so much that I know you can do everything, I just aren't sure about the capable nodes that exist already. I agree with your method, though. I know it's convenient to have them in 1 node, but how I work, I like everything sort of self-contained into it's own step; even if it adds more to a tree. It's easier to get to at glance too. Thanks for the help! I'll give it a look and see what happens. Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 11, 2016 Author Share Posted July 11, 2016 Okay, I tried the method you mentioned but it doesn't seem to be working out. I am obviously doing something wrong. I added a color node and colored them by the new attribute I made. I just need each of those boxes to be a part of the cluster they are assigned to. Then have each cluster be treated as it's own piece. hmm? I attached a quick file I made. cluster.hipnc Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 11, 2016 Share Posted July 11, 2016 I'm not really clear about what you want to do - like in, what is the behaviour you desire? If you are talking about clustering like in keeping groups of fragment together in a sim or what? I just need a frame of reference for what the heck you are doing with this thing... 1 Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 11, 2016 Author Share Posted July 11, 2016 On 7/9/2016 at 8:43 PM, Malf said: You should check out the 'cluster' and 'clusterpoints' SOP nodes. They preform pretty much the same functionality as what happens inside the voronoi fracture node. I tend to use this method for clustering even when using the voronoi fracture node, to assign clusters to the points before feeding them into the fracture. Cheers Jake. Okay, so here is what I got. I managed to figure out how to take the points and cluster them. However, when I put them into DOPs I want each cluster to behave as its own single object. Right now when they collide they all just act as individual boxes. I tried looking for a way to merge objects by an attribute, but I don't know if that's even the correct method. I attached my file again. Any help is appreciated cluster_2.hiplc Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 11, 2016 Share Posted July 11, 2016 (edited) Michael, you're confusing the functions here. The clustering is for grouping points you use to fracture an object, if you want to "cluster" objects/fracture pieces to hold together in a RBD sim, you use constraints. They are basically lines with attributes so they are amazingly easy to control, you can do stuff like feeding a noise onto them as a multiplier for strength if you want random clustering of fragments in your sim, etc... Edited July 11, 2016 by Farmfield 1 Quote Link to comment Share on other sites More sharing options...
Solitude Posted July 11, 2016 Share Posted July 11, 2016 There is actually a way to set it up so each cluster acts as it's own object without creating constraints. I'll have to find my example file when I get home,but you can essentially use each 'name' to define a compound object. It acts more like an implicit glue constraint. You need to make each cluster have it's own unique 'name' (all in cluster 1 have the same name), and have "Create Convex Hull per Set of Connected Primitives" checked on. This is how I've done some more complex 'concave' geometry while having it be made up of voronoi pieces -- but without the hassle of setting up the constraint network. 1 Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 11, 2016 Author Share Posted July 11, 2016 43 minutes ago, Solitude said: There is actually a way to set it up so each cluster acts as it's own object without creating constraints. I'll have to find my example file when I get home,but you can essentially use each 'name' to define a compound object. It acts more like an implicit glue constraint. You need to make each cluster have it's own unique 'name' (all in cluster 1 have the same name), and have "Create Convex Hull per Set of Connected Primitives" checked on. This is how I've done some more complex 'concave' geometry while having it be made up of voronoi pieces -- but without the hassle of setting up the constraint network. This is exactly what I was trying to acheieve. @Farmfield, the problem with constraints is that I don't want them to break or have to worry about figuring out how to constrain between common attributes. Plus, I feel like that is one step removed from what @Solitude is saying. It's not that I want them to be "connected" as much as I want them to be considered a single piece of many. It's kind of funny how you can add a Vornoi Fracture and just click "Cluster" and problem solved. I'm happy my that I started moving into the direction of trying to combine the primitives that had the "clusternum" attribute I created. I just got stuck there not knowing how to make them compound. Thanks guys! Both ideas helped a lot and I can't wait to see the setup when you get time. This has been bothering me for a good week. Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 12, 2016 Share Posted July 12, 2016 (edited) @Solitude - Ian, that sounds really efficient. though if you do I guess you can't constraint the clusters, or perhaps you have functions in DOPs you can use for that? Would love to se an example setup - though I'll look into it here see if I can figure it out. Edit 1: I did figure it out, pretty simple. Tnx for the tip, Ian. cluster_2-FF.v1.hiplc Edit 2: And as constraints are created from the name attribute, not the actual pieces, you can use constraints as usual even clustering pieces in the solver like this. cluster_2-FF.v2.constraints.hiplc Really cool and efficient - and good timing, I'm just about to start working on a complex dynamics setup, so this might come in handy! @mstarktv - And doing it with just constraints, you'd do it like this... miclustark.hiplc If you are going to use constraints anyway, and if it's not a huge setup, I would keep the clustering in constraints rather than using Ian's method, the reason being it's easier to have the constraints thing in one place - if you cluster using the name setup, then use constraints, it going to be messy to tweak. Oh, this piece is to big, or doesn't break like I want, but is it due to the name clustering or the constraints? Like that... But doing more complex setups, clustering using the name thingie is of course way more efficient as it creates way less collision hulls. Edited July 12, 2016 by Farmfield 2 Quote Link to comment Share on other sites More sharing options...
Solitude Posted July 12, 2016 Share Posted July 12, 2016 (edited) Awesome. Glad you figured it out! I couldn't get on the computer last night (darn kids!). Edited July 12, 2016 by Solitude 2 Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 13, 2016 Author Share Posted July 13, 2016 This is EXACTLY what I was trying to figure out. It was more a general curiosity for things that may not end up fracturing but i want to control the sticking. Constraints are fine, but something like this is super useful for things things that can appear more complex than they really are. I love that I was racking my brain so hard, and it just turned out to be 1 node of turning the strings into attributes. Or the other way around. I can't wait to put this to use ASAP! Thanks guys!!! 1 Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 13, 2016 Author Share Posted July 13, 2016 Okay, so in the natural effort to make everything complex, I got an idea to use this concept but on something that is probably more typical in an everyday situation. @Farmfield I moved some nodes around and uploaded the file. What I'm trying to do is the same exact thing now. EXCEPT, this time it's using primitives that exist already instead of clustering the points AND THEN copying in geometry. In the file you'll see the issue when you hit play. What is happening is the cluster is treating every single primitive(face) as it's own, instead of the object as a whole. I understand why it's doing what it is doing, but I'm trying to figure out a way around that. So just to distinguish the difference between the old snd the new files: The original file you posted used scattering to cluster points and then "meshed" them with boxes. This file has boxes that I'm trying to cluster as combined pieces. For instance, if someone passed me along a file that had a bunch of unique objects, and I wanted to use scattering to section ares off into their own clusters. Sorry if I'm being confusing as always. I just think that this scenario is more likely than the former. cluster_geo.hipnc Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 13, 2016 Share Posted July 13, 2016 (edited) 7.30 am here and I just came into the thread when you posted this - I'll check it directly. Edit: Oh, what's happening is you're clustering primitives (as in polygons) and not pieces. I'll see if I can sort it out in an easy way. Gimme a couple of minutes. Edited July 13, 2016 by Farmfield 1 Quote Link to comment Share on other sites More sharing options...
mstarktv Posted July 13, 2016 Author Share Posted July 13, 2016 it's 1 am here, lol. Good timing. Quote Link to comment Share on other sites More sharing options...
Solitude Posted July 13, 2016 Share Posted July 13, 2016 Just check "pack geometry before copying" on the copy sop and it should work. Quote Link to comment Share on other sites More sharing options...
Solitude Posted July 13, 2016 Share Posted July 13, 2016 Also I attached a quick file. It works off the voronoi clustering. You basically pack each individual piece, then repack each cluster. TA-DA!! You just have to get the naming right, but it's all automagical from the cellpt attribute and the name attributes generated by the voronoi node. dop_bullet_compound_voronoi.hiplc Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 13, 2016 Share Posted July 13, 2016 (edited) I did it like this, using a foreach - but Ian's way is a tad more efficient. cluster_geo.FF.v1.hipnc Edit: Looking at Ian's solution, note that packing the pieces in the copy and then in the assemble SOP will mean you pack them twice - and you'll have to unpack them twice - so here I set it up to unpack and colorize the pieces before repacking them in the assemble SOP. cluster_geo.FF.v2.hipnc Edited July 13, 2016 by Farmfield Quote Link to comment Share on other sites More sharing options...
Solitude Posted July 13, 2016 Share Posted July 13, 2016 Ah, even better. Team work rules. Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 13, 2016 Share Posted July 13, 2016 (edited) Ian, just gotta ask - in your last file, in the wrangle, aren't you trying to convert a string to a string? Edit 1: I'm probably wrong, I thought the cells attribute was a string already... Edit 2: I was wrong, because of course. Edited July 13, 2016 by Farmfield Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.