Jump to content

Bounding box group creation from fractured object


Recommended Posts

Hello forums.

I was wondering how one would go about creating individual groups from a pre-fractured object. Let me explain further.

I have a pre-fractured box. All of the pre-fractured pieces are already named piece*. I then have a group node that groups primitives based on a bounding sphere. However, there's a problem. Say I have 10 fractured pieces and the sphere is intersecting 5 of them. Well those 5 pieces get put into ONE group. What I would like to do is put those 5 pieces into another unique name like "bounding_box_pieces". So instead of getting 1 group with 5 primitives, I get 5 groups with 1 primitive each.

There has GOT to be a way to do this, but I am completely stumped. I've attached a .hip file as a start if anybody cared to use one.

Thanks!

hip_file.hipnc

Link to comment
Share on other sites

Are you sure you need individual primitives or do you want whole pieces in the group ( 1 primitive != 1 piece )

anyway, I had a go at that, here is the hip file ... it isn't fast, there must be a better way of doing it!

Ah thanks for trying. Yeah I meant the whole pieces in the group. I attempted to use a connectivity--partition setup with no avail. I think the problem is that I have a bounding sphere animating through the debris pieces. That sphere is picking which debris pieces go into a group. However, when the sphere isn't touching the debris pieces, those pieces are taken OUT of the group. So, is there a way to "preserve" or keep what pieces I want in the group once they get in there? I attached the .hip file of my attempt with the connectivity---partition method. Thanks so much!

hip_file2.hipnc

Link to comment
Share on other sites

Without trying, I think the trail method would be sluggish...if you are going that route it would be better to leave a trail of particles from the sphere, and let those particles transfer an attribute that puts stuff into the group. That way you have persistent groups.

Edited by Netvudu
Link to comment
Share on other sites

Without trying, I think the trail method would be sluggish...if you are going that route it would be better to leave a trail of particles from the sphere, and let those particles transfer an attribute that puts stuff into the group. That way you have persistent groups.

Well I attempted to do an Attribute Transfer type thing with no luck. I don't understand why this effect is so difficult for me to accomplish, lol. This is the effect I'm going for:

It's in the first 10 seconds. I figure if I can get a bounding box to activate already fractured pieces, I can feed those groups into a DOP network and let them react to forces.

I attached the .hip file modified a little further. Grrr, what am I doing wrong?

Thank you for the help!

hip_file2.hipnc

Edited by derm
Link to comment
Share on other sites

Ok, you should have started by showing the video example of what you wanted to do :)

I didn´t check your scene because a few weeks ago I shared a scene at these forums, and it does precisely what you want. To "unglue" a fractured object based on another animated object.

Here it is. It has post-its all around with explanations of the different aspects of the scene, for your convenience.

Hope it helps.

Unglueing_SOLVED.hipnc

Link to comment
Share on other sites

Ok, you should have started by showing the video example of what you wanted to do :)

I didn´t check your scene because a few weeks ago I shared a scene at these forums, and it does precisely what you want. To "unglue" a fractured object based on another animated object.

Here it is. It has post-its all around with explanations of the different aspects of the scene, for your convenience.

Hope it helps.

Thanks! I haven't looked at it yet but I actually wanted to correct my above reply:

So sorry, my sentence that said "I don't understnad why this is so difficult" wasn't meant to be directed at other people. It was supposed to be, "I don't understand why doing this effect is so difficult." It was solely directed at myself. Sorry for the misunderstanding!

I really appreciate the help!

Link to comment
Share on other sites

Hi Netvudu

Thanks for sharing your Unglueing_solved file with all the notes and extra things to visualise.

Could you tell me though why the $OBJIDs of the RBD fractured objects start with 2 and not 0?

I noticed when evaluating the color with point expression you needed to subtract $OBJID by 2 to get the right point.

Thanks

Link to comment
Share on other sites

Sure. Good call. I should have explained that as well in the file.

That number depends on the order of creation of your RBD objects. If you start with the ground, for instance, Houdini assigns the OBJID= 0 for that object, then the next is 1, etc...For this setup to work, the points you created on the For Each have to match the OBJID...that´s why I subtracted 2: my first piece had an OBJID=2.

In fact you will have to subtract more or less depending on how you created the DOP Network.

Fortunately it is very simple to know which number you need. Just go to your first piece, and check at the Details view its objid. That´s your first number.

I hope it is clearer now.

Link to comment
Share on other sites

Sure. Good call. I should have explained that as well in the file.

That number depends on the order of creation of your RBD objects. If you start with the ground, for instance, Houdini assigns the OBJID= 0 for that object, then the next is 1, etc...For this setup to work, the points you created on the For Each have to match the OBJID...that´s why I subtracted 2: my first piece had an OBJID=2.

In fact you will have to subtract more or less depending on how you created the DOP Network.

Fortunately it is very simple to know which number you need. Just go to your first piece, and check at the Details view its objid. That´s your first number.

I hope it is clearer now.

Thanks Net! Makes sense :-)

Link to comment
Share on other sites

Thanks heaps Netvudu.

Was looking all over help files for how that number is assigned. Still, I was pretty sure I created my groundplane last and still had my first piece numbered from 2. Ah well, main thing is to check it in the details...there goes the proceduralism.

Another thing to note, if using the voronoi fracture tool to prefracture your geo, it helps to add an offset surface value=-0.1 like you did in "RBD fractured object\Collisions\Volume\Offset Surface". With this separation, the activated pieces don't drag the rest with them. Default is zero. Of course, one can use smaller values for smaller separation and therefore some influence by main falling pieces on others for a more natural look.

Link to comment
Share on other sites

Thanks heaps Netvudu.

Was looking all over help files for how that number is assigned. Still, I was pretty sure I created my groundplane last and still had my first piece numbered from 2. Ah well, main thing is to check it in the details...there goes the proceduralism.

Another thing to note, if using the voronoi fracture tool to prefracture your geo, it helps to add an offset surface value=-0.1 like you did in "RBD fractured object\Collisions\Volume\Offset Surface". With this separation, the activated pieces don't drag the rest with them. Default is zero. Of course, one can use smaller values for smaller separation and therefore some influence by main falling pieces on others for a more natural look.

Oh man, fantastic tip! I was wondering about how to stop that from happening. Thank you sir!

Link to comment
Share on other sites

  • 4 weeks later...

You're welcome.

Do share your progress in getting the shot you wanted (the vimeo video).

I too am trying but have not been successful in getting it to work on a vertical wall.

The entire wall crumbles when the top ones start to break away.

Any ideas Netvudu?

Hey Siberian, I came across another topic of exactly what I think you and I were trying to do. The original scene file is a bit complex (for me at least) because it deals with animating geo, however, I stripped it down to the bare essentials (I think). I don't quite understand all of it yet but I know that it does what we were looking for.

Original post here:

chunkActivationExample.hipnc

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...