1
$\begingroup$

So I've created a bezier curve, added some thickness and converted it to a mesh. Now I would like to add a gradient texture to that mesh but following the shape of the body like the reference image on the left.

I've tried to play with a Texture Cordinate node and Mapping, but I don't really now what I'm looking for.

What I am missing ?

my results so far

$\endgroup$
3
  • $\begingroup$ maybe the easiest way to do it would be to assign one color to each of your cylinder face? $\endgroup$
    – moonboots
    Aug 1 '20 at 18:33
  • $\begingroup$ I really would like to do use using nodes system so I can tweaks more easily, also my cylinder has a lot of faces $\endgroup$ Aug 1 '20 at 18:57
  • 1
    $\begingroup$ I don't know if a procedural can follow all around the cylinder, you could create your stripes on a flat surface then bend it but it seems a bit tedious... $\endgroup$
    – moonboots
    Aug 1 '20 at 19:09
2
$\begingroup$

Try using a wave generator set to use the Z axis of the object to power your color ramp.

I was able to get the following result by creating a curve, converting it to a mesh, and using the following node setup:

enter image description here

I've also used a Vector Math node to offset the pattern start, else the pink takes up more than it's fair share. Try adjusting the OFFSET input, as well as the Wave texture scale attribute.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.