0
$\begingroup$

Its a simple question, yet google does not yield any results. In the image below, the extrude mesh node outputs a bunch of instances that each have a scale attribute. I want to read that attribute, then realize instances and then read the uv_map attribute in the second picture, multiply it with the scale, and write it back. This is so that the planks in the object have uniform uv mapping.

I'm probably not understanding the attribute workflow because it seems to me like reading and writing (and more generally addressing by name) attributes should be the most basic of operations? Yet I can not find anything on it anywhere.

Update: I'm using Blender 3.1, so maybe this has to be done with fields now? Most attribute nodes used in tutorials are not available in 3.1 anyways

Read the scale attribute

read and write the uv_map attribute

$\endgroup$
0

1 Answer 1

0
$\begingroup$

I'll give you an example.I make two models,one is monkey which I want to get the data from,another is a cube,just a container of GN. (numbers represent the node) Link GN as this
enter image description here

  • You can see that I add 3,it's input is monkey,means I want to get the data of monkey,but which data I want?I want the normal of each vertices,which we know that they are a list of vectors,so I choose Vector/Point in 3.
  • To show the data,link 3-5,5 has two input,the first is which object you want to show,the second is the data,so,we know our data type is vertices,we click Vertex in text,and we can see the viewer on the right,which is the normal of each vertices.
    enter image description here
  • If we want to get the Points data shown below,we should link 3 to Points of 4,but the data type of viewer changed,so we should click Point in text and also get the data we want.
    enter image description here enter image description here
$\endgroup$
3
  • $\begingroup$ How would you do what I asked for though? Read the scale from the instances and the uvs from the face corners and write the new uvs to the face corners. I have seen the capture attribute node, but all people ever plug into that is normals or positions. What if you want to capture another attribute? $\endgroup$ Mar 14, 2022 at 16:28
  • $\begingroup$ If something has that data,then GN can capture them,all data type is almost limited to a list of vector/float, so,there's nothing different as I shown.Only need your design.The scale from the instances,just a math problem ,and you should make a node list yourself. uv is not a GN problem. $\endgroup$
    – NatureK
    Mar 14, 2022 at 16:40
  • 1
    $\begingroup$ That still doesn't make it clear how I should read the uv_map attribute. The way you read the normal attribute in your example is by plugging it into a normal node. Since there is no uv_map node, how do I tell the capture node what to capture? $\endgroup$ Mar 14, 2022 at 17:35

Not the answer you're looking for? Browse other questions tagged .