So I am looking at trying to move from using the “old” copy sop with stamps functions to the new copy to points sop. I have hit a bit of a snag. How do I us a “switch” node with this to randomize the mesh copied? I am also using a probability matrix along with $ID to control the frequency that a certain mesh might get used.
Looking at the doc's I don't see $ID, are any type of equivalent attribute the copy to points recognizes? any ideas?
Now I am trying to sort out if i can somehow dictate the $ID with the old copy sop, and then use the new copy to points to do the scaling and orienting. Maybe some sort of transfer attributes hack .
Does the "Copy to points" sop not recognize $ID?
4457 4 1- Kfinla
- Member
- 100 posts
- Joined: 8月 2014
- Offline
- tamte
- Member
- 8833 posts
- Joined: 7月 2007
- Offline
- Kfinla
- Member
- 100 posts
- Joined: 8月 2014
- Offline
Thanks for your help once again Tomas. I was looking at this earlier. So I have things kinda working.. i have random scale, rotation.. and even object selection.
What I don't have is any control. The Stamp function sends an attribute up stream. I am scratching my head about how to put the $ID value into the switch node.. basically copy mesh #5 when the point has attrib is ID#5.
Like I do with stamp(“../copy4”, idval, 0) on my “old” copy stamp setup.
What I don't have is any control. The Stamp function sends an attribute up stream. I am scratching my head about how to put the $ID value into the switch node.. basically copy mesh #5 when the point has attrib is ID#5.
Like I do with stamp(“../copy4”, idval, 0) on my “old” copy stamp setup.
- Kfinla
- Member
- 100 posts
- Joined: 8月 2014
- Offline
In the mean time, my tacky solution is to create point groups based on each $ID and use a copy to points to copy each mesh type to the appropriate point group. Its not pretty, doesn't scale up and down with object count but it improves performance by about 3x (not-compiled yet) vs doing the ID, scale, and rotations all on the old copy sop.
Edited by Kfinla - 2017年12月15日 17:25:47
- tamte
- Member
- 8833 posts
- Joined: 7月 2007
- Offline
I'm not sure you've watched those videos or understood the use of copytopoints within foreach loop, but here is a simple example that can clear things up, I on purpose left out compile block to not make it confusing, but it would naturally be faster when compiled
left example is using iteration from metadata directly as the ptnum
right example is using the attribute from the point directly (in this case @id attribute that represents ptnum, but it can be any value of any attribute from the point that drives your “stamping”)
left example is using iteration from metadata directly as the ptnum
right example is using the attribute from the point directly (in this case @id attribute that represents ptnum, but it can be any value of any attribute from the point that drives your “stamping”)
Tomas Slancik
FX Supervisor
Method Studios, NY
FX Supervisor
Method Studios, NY
-
- Quick Links