Copy transform SOP vary scale per copy (alternative to $CY?)

   1766   5   2
User Avatar
Member
29 posts
Joined: Oct. 2015
Offline
Hi, what's the recommended way to access the current copy index in the Copy and transform SOP?

In the old copy stamp SOP $CY gives you the ability to modify based on the current copy indes, but can't figure out a simple way to do this with the Copy transform SOP. The only thing I can think of is adding three points, setting the pscale attribute on those to the values I want, then using foreach as in the foreach copy stamping [www.sidefx.com] tutorial, but this seems a lot of unnecessary work.

Is there a simpler way?
Edited by Lyubomir Popov - Jan. 3, 2022 08:52:47

Attachments:
copyQuestion.hipnc (94.4 KB)
CY.jpg (80.3 KB)

User Avatar
Member
731 posts
Joined: Dec. 2006
Offline
Use the attribute adjust float SOP to create random pscale (or some other scheme), on the template points, and the copy SOP should just recognize that.
Sean Lewkiw
CG Supervisor
Machine FX - Cinesite MTL
User Avatar
Member
29 posts
Joined: Oct. 2015
Offline
Thanks for the reply, but I'm not sure I understand - the Copy transform doesn't take points as input, just the geo to be copied.
I know how that can work with the Copy to points SOP, but was hoping to be able to just use the simple Copy and transform instead of multiple SOPs.
Edited by Lyubomir Popov - Jan. 3, 2022 09:34:56
User Avatar
Member
731 posts
Joined: Dec. 2006
Offline
Ah sorry, I didn't read your post carefully enough. Yeah, I can't see a simple way to do it.

My solution would be to toggle on "Copy Number attribute" , and then put the results in a foreach named primitive loop with "copynum" as the piece attribute. Inside the loop put down a transform with $CEX $CEY $CEZ in the pivot transform and scale that way using the current iteration as a seed.

But yeah, convoluted.
Sean Lewkiw
CG Supervisor
Machine FX - Cinesite MTL
User Avatar
Member
333 posts
Joined: April 2018
Online
The replacement for Copy Stamp is Copy to Points. The reason it was replaced because Copy Stamp suffers from poor performance, and Copy to Points can handle significantly larger data sets more easily.

If your scenarios isn't heavy, you can stick with Copy Stamp, but if you need something beefier, you need to use Copy to Points, and whatever extra steps using it entails.

You don't need a For Loop with Copy to Points, you can initialise the attributes and be done with it.

Edited by eikonoklastes - Jan. 5, 2022 02:29:38
User Avatar
Member
29 posts
Joined: Oct. 2015
Offline
Thanks, I resorted to a wrangle and did it all there eventually, but your way is nicer and simpler.
  • Quick Links