4
$\begingroup$

In cycles, with particle hair strands, I can get the colour from the texture of the emitter object for colouring the entire strand.

Image of the strands

When I use the "Particle Instance" modifier on a mesh (a simple cylinder in the image bellow), I do not manage to get the same result. I would like to set the colour of the instances (cylinders), so each instance has a different colour (example, the first instance is blue, the second is red etc). This colour should be based on a texture mapped to the emitter, like it is the case when I apply a texture to hair strands (see the image above).

My goal is to model custom hair primitives (like dreadlocks, or mesh braids) while maintaining the ability to paint on the emitter for variance between each instance.

Here is what I get with my instances material. My goal is to get the same result as my first image (for the material, not the shape of course): Image of the particle instance

Here is the file if someone wants to try (Made in Blender 2.79) : https://www.dropbox.com/s/chbt1mp28a6wt4k/demo_for_help.blend?dl=1

(I did not find a way to add a .blend attachment so I used dropbox).

$\endgroup$
  • $\begingroup$ Blender lacks this functionality, would you be interested in a solution using Animation nodes addon? $\endgroup$ – Jaroslav Jerryno Novotny Nov 9 '17 at 10:13
  • $\begingroup$ Yes ☺️ I always wanted to test this addon anyway! What I would like tho is though is not to apply the changes. Understand that I want to keep the features of particle hair for physics for instance. $\endgroup$ – Maxx Nov 9 '17 at 10:20
  • $\begingroup$ Well, unfortunately even with AN it's not that easy as it turns out. You need custom code to sample the color from surface and set it as vert colors for the hair instances. Deforming these instances along splines is this complicated: blender.stackexchange.com/a/46589/7777. Getting the splines from hair is easy: animation-nodes-manual.readthedocs.io/en/latest/user_guide/… $\endgroup$ – Jaroslav Jerryno Novotny Nov 9 '17 at 18:39
  • $\begingroup$ I have a feeling Sverchok can do this one, there is no specialized node yet to get color based on closest 3D point to match its UV texture, but ... Sverchok has UV node which can layout mesh to match its uv layout... it is very possible to get color from UV and apply it to the instace... let me think... $\endgroup$ – Blender Sushi Guy Nov 10 '17 at 12:32
  • $\begingroup$ @Jerryno : thank you, I will try this if no easier solutions is proposed $\endgroup$ – Maxx Nov 10 '17 at 12:39

Your Answer

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

Browse other questions tagged or ask your own question.