transferring attributes from primitives to points

   12774   5   2
User Avatar
Member
54 posts
Joined:
Offline
is it possible to transfer primitive attributes to points ?

I placed points in the center of each primitives of a mesh using a popnet “Prim center (ordered)” source , and I would like to copy the area primitive attribute (created with measure sop) to these points .

I'm trying to do that with an attrib transfer node , source group type = primitives , destination group type = points , but it doesn't work so far …
I have the popnet in the first input , the original mesh in the second input.

?
User Avatar
Member
606 posts
Joined: May 2007
Offline
Ray SOP seems to work, but feels a bit dirty.

Attachments:
ee_pript_v002.hip (49.4 KB)

User Avatar
Member
54 posts
Joined:
Offline
works fine … thanks !
User Avatar
Member
299 posts
Joined: Jan. 2010
Offline
Is not this what the Attrib Promote is for?
Drive, monkey, drive!
User Avatar
Member
606 posts
Joined: May 2007
Offline
Erik_JE
Is not this what the Attrib Promote is for?

Well, not exactly. The promotion works between elements where one is the “member” of the other, e.g. points and the primitive they are part of.

Here it's completely separate geometry we need to transfer the attribute to.
User Avatar
Member
39 posts
Joined: July 2005
Offline
Hey, there. If your primitive and point orders match (which they might if you used prim center ordered and aren't creating any more points than primitives), you can use the “prim” expression to copy the attribute. i.e. use prim(“path_to_primitives_sop”, $PT, “area”, 0) in an Attribute Create. See the attached hip file. Cheers!

Attachments:
copy_prim_to_pts.hipnc (43.3 KB)

  • Quick Links