1
$\begingroup$

I'm trying to do like a magical girl hair transition from one material to another along hair curves (actual path curves) and I cant seem to make the (shader editor) standard separate XYZ trick work as it doesn't really flow the curve and I cant seem to figure out how to transition the material (geometry nodes) like with an IF-Than-else statement along the curve so I can use a controllable value to do it. Any suggestions on what a node tree for this might look like?

I'm trying to rig it up to flow out like this. from the base/start of the curve to the end. the curves all go the same way.

kinda like this https://gifdb.com/gif/anime-kaneki-hair-transformation-bbb7o57faihwvgrf.html

Image 1 is how I'm trying to get the material to flow. image 2 is what im currently getting with shader editor that has shown me I...probably dont want to use shader editor and need a geometry node set up...but dont know how to set one up to change between two materials dynamically with out recreating the object in the node tree.

desired result

Current Result

$\endgroup$
3
  • $\begingroup$ Hello. Wenth, I think we need more info to answer this. Please illustrate, indicating the desired effect, and as much as you can give us about the part that isn't getting there. Maybe share a representative chunk of your project on blend-exchange.com, editing the link into your post. $\endgroup$
    – Robin Betts
    Sep 5 at 7:10
  • $\begingroup$ .....how do i reopen this after adding more detail...... why was it closed just so I can add more detail? $\endgroup$
    – Wenth
    Sep 5 at 22:17
  • $\begingroup$ Hi, @Wenth .. On SE sites, if a question is closed by vote due to perceived lack of clarity, it's up to the mods to reopen after assessment.. (done). At the time of my review, I left your post open for you to edit; I think more votes must have come in after that. I'm sure your edit gives us enough to work with.. thanks! (I can't be sure without checking further, but at first sight of the tree we can now see, I would suggest UV is the right texture-coordinate, not Object. In the normal course of events for a profiled curve, U runs down the length, V around the profile). $\endgroup$
    – Robin Betts
    Sep 6 at 6:33

1 Answer 1

1
$\begingroup$

You can use the X-coordinate of the splines UV coordinates

enter image description here

enter image description here

enter image description here

$\endgroup$
1
  • $\begingroup$ Yep...yep....that works. if i cut out the gradient texture and color ramp i was using and just plug right from X to math node and a mix shader it works when mapped from UV....sigh... thankyou! its not perfect but I can make it work with some tweaks to how i built the hair I think. $\endgroup$
    – Wenth
    Sep 7 at 3:43

You must log in to answer this question.

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