0
$\begingroup$

I'm making a coral. It has UV map image texture and I spread it out some points with Geometry Node on the surface of the mesh, and I wanted to apply my UV texture to points.

For instance, yellow points on the position of the UV map painted with yellow parts. But I couldn't do what I expect with set material node Can you guys help me? I attached my screen image screenshot

$\endgroup$

1 Answer 1

1
$\begingroup$

I'm not sure if I understood your question correctly. Do you want to project the colors of the points emitter onto them? You don't need UVs for that, but you need to turn these points into real meshes.

Even if you were to apply UVs on these points you'd need them to be actual meshes, because afaik only then they'd be able to hold and use this kind of data.

Full Geo Tree

I've generated the color map on the fly for this example. You must replace the Noise Texture node with an Image Texture with your coral colors, plugging the UV map into the Vector input in the same way shown here.

You can use a Subdivide Mesh node before storing the image color data into an attribute in the cases the emitter mesh isn't dense enough to hold this data faithfully into its points or face corners.

Texture setup

Turn the points into real meshes by instancing something on them and realizing the instances.

Point setup

You can now transfer the color data to the new meshes, assigning a material to them so it shows up. This is basically a Vertex Color map. In case you want it done properly, change the stored domain to Face Corner.

Transfer color data

When using generated meshes in Geometry Nodes it's important to change the Material link type to Object, because the generated meshes aren't part of the real data of the object unless you apply the modifier.

Material link

$\endgroup$
4
  • $\begingroup$ Thank you very much for your detailed reply. But is there any way to move the color on the UV map to Vertex color? $\endgroup$
    – studentz0
    Commented May 31, 2022 at 2:39
  • $\begingroup$ @studentz0 What do you mean? I think you're confusing UV maps with image textures. There's no color data in UV maps, they're just a texture coordinate system used to map the mesh's vertices into 2 dimensions. If you meant the color from the image texture to vertex colors, then this is pretty much what this answer does. It's storing the color data into the points vertices. Apply the GN modifier and take a look at the object data panel. $\endgroup$
    – Rhaenys
    Commented May 31, 2022 at 4:11
  • $\begingroup$ i can't find "named attribute" node and "Store Named Attribute" are you using blender version 2.9? $\endgroup$
    – studentz0
    Commented May 31, 2022 at 7:10
  • $\begingroup$ @studentz0 Oops, the docs are confusing so I thought they were in 3.1 already, but it seems they're only available in 3.2 beta (with an experimental setting enabled) or 3.3 alpha versions. $\endgroup$
    – Rhaenys
    Commented May 31, 2022 at 12:20

You must log in to answer this question.

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