Andrei_S Posted November 21, 2005 Share Posted November 21, 2005 I want use color of object (Cd) as individual mass of each rbdfracturedobject but i don't know how made this. Can you help me? mass_As_object_color_Cd.zip Quote Link to comment Share on other sites More sharing options...
mtucker Posted November 21, 2005 Share Posted November 21, 2005 There are two ways you could do this. One is to do it as an expression on the RBD Fractured Object DOP. To do that, you would need some way of relating the DOP object name or id to a point in the source geometry. In your example, this is pretty easy because each piece has the same number of points. So you could put the expression: point("/obj/Sphere_with_point_color/null1", $OBJ*42, "Cd", 0) in the Mass parameter of the RBD Fractured Object DOPs. A more general solution (which requires no information about the source geometry) is to set the mass of the objects after the objects are created using a Modify Data DOP between the merge1 and rbdsolver1 nodes. At that point in the network, each RBD object has its own geometry attached already, so you can reference the Cd attribute on the DOP object's geometry rather than referring to the original SOP geometry. In the Modify Data DOP, just set the "VALUE 0 Name" to "mass", and the "Value 0 Float" to: point(".:$OBJID/Geometry", 0, "Cd", 0) I hope this helps. Mark Quote Link to comment Share on other sites More sharing options...
Andrei_S Posted November 21, 2005 Author Share Posted November 21, 2005 exellent. Solution 2 is perfect. Quote Link to comment Share on other sites More sharing options...
Andrei_S Posted November 22, 2005 Author Share Posted November 22, 2005 This solution not work with Glue Object I can't change mass and internal glue use this expression. Why? Quote Link to comment Share on other sites More sharing options...
mtucker Posted November 22, 2005 Share Posted November 22, 2005 It works fine for me with an RBD Glue Object. What is it doing wrong for you? What values is it setting for the mass on the separate RBD Objects? Mark Quote Link to comment Share on other sites More sharing options...
Andrei_S Posted November 22, 2005 Author Share Posted November 22, 2005 In this scene i want change internal glue through object color bun it's not work Glue_Strength_as_point_Color.zip Quote Link to comment Share on other sites More sharing options...
mtucker Posted November 23, 2005 Share Posted November 23, 2005 A couple things about this hip file. First, the ModifyData node is not set up to change the mass of the boxes, which explains why it isn't setting the mass. I added the expression above to set the mass avlue on the boxes, and the mass value got set corectly. However this resulted in some of the boxes having a mass of zero, which seemed to confuse the RBD solver. So I added "+0.1" to the point expression for setting the mass, and eveything worked as expected. Second, I noticed the Modify Data was setting a value called internal_gluethreshold. I understand why you did this, but it will have no effect on the simulation. The value you want to set is actually gluethreshold. The internal_gluethreshold parameter on the Glue Object DOP is referenced by an RBD State DOP inside to set the gluethreshold value on the boxes. Mark Quote Link to comment Share on other sites More sharing options...
Andrei_S Posted November 23, 2005 Author Share Posted November 23, 2005 Thanks Mark I suspect that internal glue = gluethreshold But i have another question. In that scene black box have glue =0 and they must move down and white box stay glue together. But this not working, why? Where I can see mass of each object for example? Something like Spreadsheet for DOP? Can i use sop group in dop level? Sorry for my question but DOP documentation is soo small. Glue_Strength_as_point_Color_v2.zip Quote Link to comment Share on other sites More sharing options...
mtucker Posted November 23, 2005 Share Posted November 23, 2005 Glue can only be broken by a collision, so until the black boxes hit something, they will remain glued to the other objects. If you change one of your panes to "Details View" while looking at a DOP Network, you'll get a tree view which shows you pretty much everything there is to know about what's going on inside your simulation. There are a couple of topics on the Side Effects forum (www.sidefx.com/forum) talking about that tree view and what it shows (search for "simulation tree view" or "details view"). Mark 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.