Saturday 3 December 2016

Attribute Interpolating UVs & things other than scattered points.

Creating "sourceprim" and "sourceprimuv" attributes for things other than scattered points. In the Houdini docs for the scatter node, there is a guide on getting your scattered points to follow animated/deforming geometry. The scatter node can generate the source primitive and it's uv attributes for you at the tick of a box. You then stick that into an attribute interpolate node and away you go.

However, if you want to interpolate something else like say..a colour attribute or a UV attribute, or something like that - then you'll have to create your own sourceprim and sourceprimuv.
Freeze your geo using a timeshift. Then just lay down a pointVOP, connect it to your geo & then plug the source (ie in the case of the scatter example, it's the object you want to stick to) into the second input.
Within the VOP make an XYZdist node and wire up P to the position input and the second input into the "file" . Create two bind exports and change the output names to sourceprim and sourceprimuv, making sure the data types are correct.
Finally just play around with the search distance in the XYZdist node so you get correct values. Jump out of the VOP and plug the appropriate bits into the Attribute Interpolate node. Adjust the settings to whatever you need (Vertex,point etc...) and everything should be good! You might have to change the pointVop to a vertexVop... too haha.

2 comments:

  1. A scatterplot is a data visualization that shows the values ​​of two different variables as points. The data for each point is represented by its horizontal (x) and vertical (y) position in the visualization. Additional variables can be encoded using labels, markers, color, transparency, size (bubbles), and by creating 'small multiples' of scatterplots. Scatter charts are also known as scatter charts, scatter charts, scatter charts, scatter plots, and scatter charts.
    https://ppcexpo.com/blog/scatter-plot-examples

    ReplyDelete