Jump to content

transfer Cd with CopyToPoints


Recommended Posts

Because you have assigned Cd to primitives, not points. There are no primitives in the sphere primitive, only the central point which derives the surface from a spherical calculation. Try assigning Cd to points, and it works.

Untitled-1.jpg

Link to comment
Share on other sites

When you pack the Cd attribute (or any attribute) into a point, the viewport can no longer access that attribute. It appears as missing to the system. Try turning off Pack and Instance your current setup may work. It's like not being able to see a thumbnail of an image inside a ZIP file. All you see is the ZIP.

 

 

Edited by Atom
Link to comment
Share on other sites

Geo spreadsheet is your friend here. And I admit it's a little confusing. Plus in your question there's some mixing of metaphors going on.

When you create a primitive sphere and apply a color to it, the color is applied to the point representing the primitive and the viewport does a trick to color the sphere from the point color.

When you pack and instance the copy to points, the sphere (primitive or poly) is stored in memory and color IS transferred to the new points that represent each packed sphere. If you look in the geo spreadsheet, you can see that Cd IS transferred to the points regardless of whether the sphere is primitive or poly. However, because the primitive sphere is itself packed, the viewport can't do its little display trick so they all look grey, despite having a Cd attribute. As Atom said, if you want to see the colors on the primitive spheres you have to unpack them (either by unchecking the pack and instance option or by appending an unpack node and transferring Cd in "Transfer attributes". Now the primitives are assigned a color and the viewport can display them.

Finally, pscale is NOT technically transferred. If you look at the geo spreadsheet after the Copy to Points, you'll see that there is NO pscale attribute on the points. The default is for pscale not to be transferred. Instead it (and the orient attribute) are applied as a transform matrix to all the copies. You could change this by unchecking "Transform Using Target Point Orientations" and deleting ^pscale (not pscale) from the list of "Attributes from target". Now pscale IS transferred as an attribute (although if you want to use it to scale your copies you now have to do that manually, but that is another post topic).

Digging through the geo spreadsheet is often a good way to figure out how Houdini is moving attributes about.

  • Like 1
Link to comment
Share on other sites

ah. this clarifies things.
thank you, much appreciated!

still, final question. remains unclear:
in above example of atom: color sop set to points, it IS working.
in above example of my initial screenshot: Cd set to points, it is NOT working.

so, both are technically the same. arent they??
(only diff is: Color SOP vs AttribRandomize SOP. both with Cd. both on points. one is working. one not?)

 

Link to comment
Share on other sites

Could also simply be a viewport bug. Houdini's viewport is notoriously buggy with packed prims, especially with colours. Sometimes it'll display, sometimes it wont.

You can try appending an unpack to see if the colour is there, if so you can swear, log a bug with sidefx, know thats how you do it from now on. It should render properly with mantra/karma, and can be made to work with mild effort with other renderers.

 

  • Like 1
Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...