Hi
One of my frnd taught me a method to make the objs fall based on the point expression.
my question is that I want the few objects which are in the 1 color not to fall and the other objects which have other color to fall.I have attached an example.Please help me out.Thank you.
Color fall dop
2238 5 0- omy
- Member
- 71 posts
- Joined: Feb. 2010
- Offline
- tamte
- Member
- 8449 posts
- Joined: July 2007
- Offline
at first you need to sample source points by point expression, not the copied boxes since number and order of source points == number and order of your fractured pieces in DOPs
second, you better use $OBJ instead of $OBJID to get exact point index
third, it's better to create groups directly in Copy SOP since you will be sure about correct order if you use $PT in group name, Assemble SOP will most probably do it in right order but anyway it is not necessary if that option is already in copy
here is slightly modified file, just with animated color so the effect is more visible
(PS: color will not change on boxes in DOPs, obviously, because geometry is not reevaluated since there is no need for it, but in SOPs you can see full effect even with this visualization)
second, you better use $OBJ instead of $OBJID to get exact point index
third, it's better to create groups directly in Copy SOP since you will be sure about correct order if you use $PT in group name, Assemble SOP will most probably do it in right order but anyway it is not necessary if that option is already in copy
here is slightly modified file, just with animated color so the effect is more visible
(PS: color will not change on boxes in DOPs, obviously, because geometry is not reevaluated since there is no need for it, but in SOPs you can see full effect even with this visualization)
Tomas Slancik
FX Supervisor
Method Studios, NY
FX Supervisor
Method Studios, NY
- omy
- Member
- 71 posts
- Joined: Feb. 2010
- Offline
- tamte
- Member
- 8449 posts
- Joined: July 2007
- Offline
- omy
- Member
- 71 posts
- Joined: Feb. 2010
- Offline
- tamte
- Member
- 8449 posts
- Joined: July 2007
- Offline
sure, but then you need to ask yourself a few questions
1. is it possible to spread color on source points instead?
2. if not and you really need approach of spreading color over the surface of each RBD (box) then the question is what's the triggering state of that color?
a) RBD will be released when at least one primitive/point of that RBD is colored
b) or over half of the primitives/points are colored
c) or every primitive of that RBD is colored?
d) or some other case
if 1 is the case, no problem
if 2 is the case then easiest will be to use forEach SOP to iterate over every point of source points or just any group of points with the same count. And you can create attribute or color on them based on current box (by current I mean box which correspond to currently processed point in foreach ), the value depends on the case a) b) c) or d)
then just use the points to pass that value to active state of the RBD in dopsim as in example
1. is it possible to spread color on source points instead?
2. if not and you really need approach of spreading color over the surface of each RBD (box) then the question is what's the triggering state of that color?
a) RBD will be released when at least one primitive/point of that RBD is colored
b) or over half of the primitives/points are colored
c) or every primitive of that RBD is colored?
d) or some other case
if 1 is the case, no problem
if 2 is the case then easiest will be to use forEach SOP to iterate over every point of source points or just any group of points with the same count. And you can create attribute or color on them based on current box (by current I mean box which correspond to currently processed point in foreach ), the value depends on the case a) b) c) or d)
then just use the points to pass that value to active state of the RBD in dopsim as in example
Tomas Slancik
FX Supervisor
Method Studios, NY
FX Supervisor
Method Studios, NY
-
- Quick Links