# Integer to integer not working

I need the same counts from the previous Mesh Line or Curve Line nodes to continue Multiplying or dividing for ahead but at this point, I am confused that in the Viewer node it is showing the exact integers I want but it is not working. Why?

• The Count input is a single number, like a count of 10 with an offset of 1 m meaning every meter there is a point and 10 overall. You try to input a list (called "field" in Geometry Nodes) of index integers into it. The indices are 0, 1, 2, 3 etc. but a mesh line can only have one count of points, not several. How should a single line have an overall count of 0 points (impossible anyway, has to be 1 at least), but at the same time 1 point, 2 points, 3 points etc.? Sep 8, 2022 at 13:30
• I got it Thanks, but I want the same count I have in the previous Mesh Line node for the next one. Is it possible to get this? Sep 8, 2022 at 14:33
• The count is a fixed value. So why not simply put the same value in there? And if you want to change the value, just use an Integer node which you plug in both Count inputs. There you can set a single value. The Index holds a list of incrementing numbers, not the count of the Mesh Line. Sep 8, 2022 at 14:39

If you use Capture Attribute or Transfer Attribute to query the index of a geometry on a certain domain (in your case you have chosen the attribute domain Points), you will always get the consecutive index of each point.

So you get back an integer value changing per point. This is called "field" and this type is marked with a diamond shaped socket. You can also compare this with an array consisting of several values.

In contrast to the "field", which is a whole array of values, the node Mesh line needs a single value for the input Count. This is represented with a circular socket.

So to feed both nodes with a single value you have (at least) two possibilities...

Either you give both nodes the same integer value:

Or you evaluate the number of points of one node with Domain Size and feed the second node with this value:

• After a few comments and looking at the marked index column in the screenshot, I think he wants something else, hence my answer... Sep 8, 2022 at 15:13
• ...once again I didn't understand the question at all, and he didn't actually tell us what he really wants to do here :D Sep 8, 2022 at 15:14
• Yes, I think he confuses the "count" in the mesh line with the incremental index numbers which are like you "counted" the points... but that's just a wild guess :D Sep 8, 2022 at 15:16

I guess we are talking of different things in the comments. What you show in the Viewer node is the index of points in that Mesh Line, the index is their unique number to identify them. The Count in the Mesh Line node is the sum of all points that are building this line, so they are 10 points altogether.

Each Mesh Line with 10 points would have the indices 0, 1, 2, ..., 9 for its points. But after you combine them with Join Geometry, they are treated like a single object consisting not of 10 points, but 20. Since the index is a unique indentifier, no two points are allowed to have the same index inside an instance or mesh.

If you want them to repeat, you can use the ID instead of an index. Therefore you have a Set ID node in Geometry Nodes. You can use the Index node and plug it into a Math node set to Modulo with the other value set to 10. The result will be the difference between the index and a multiple of 10.

So while the Index in the joined geometry goes from 0 to 19, the ID goes from 0 to 9, then starts again at 0 and up to 9 again. So if you need these values for anything later on, you can use the ID node instead of the Index node.