0
$\begingroup$

I have a particle system which is rendering as objects. I would like each of these objects to have a uniform colour. I would like the colour to be dictated by the underlying material of the emitter. I.e. if the particle is emitted from a red part of the emitter, it should be red all over, if it's emitted from a blue part, blue all over.

I thought that this question would solve the problem for me:

Particle Color based on where the particle is emitted?

but it does not seem to. Here is my simple MWE .blend:

https://bit.ly/3bFLLcC

and below is a screenshot:

enter image description here

Any help greatly appreciated.

Thanks

$\endgroup$
2
$\begingroup$

Switch from Eevee to Cycles, make the materials Single User Materials by clicking on the "2" right to the material name in the material tab (either the plane or Suzanne) and uncheck "From Instancer" in the "Texture Coordinate" node of the plane's material node tree (only your instanced object has to have this option checked). If you change the noise texture setting on your plane, copy the plane material to Suzanne where you have to make it Single User and check "from Instancer":

curved plane with red and blue noise pattern and Suzanne head as particle instance objects

| improve this answer | |
$\endgroup$
  • $\begingroup$ Thank you very much. That works. I swear I tried this before and it didn't work! My MWE was left on Eevee not cycles by mistake. However the behaviour changes if I change emission from 'faces' to 'verts' - the particles all turn the same colour. Also if I change it to 'grid' rather than 'random', the same thing happens. Finally, if I switch from 'verts' to 'volume' then to 'faces', it does not update the appearance. This lack of updating with particle systems is something I have seen frequently. Are you able to reproduce this behaviour and do you have suggestions? Thanks again $\endgroup$ – d401tq May 24 at 3:12
1
$\begingroup$

@d401tq

Theory:

Since the setup above is based on UV-textures which are projected from the 2-dimensional UV-texture space onto surfaces it's logic that the emission source has to be a face. For the 3-dimensional procedural textures using UV-coordinates like the "Noise" texture in our example here, only the color values at W = 0 are taken into account (Note: "W" is the third dimension in a UVW-texture space but Blender's UV-editor only uses the UV-plane at W=0) .

The only colors associated directly with vertices are vertex colors which you can access by an "Attribute" node in your "Shader Node Editor". Use the name of your vertex color map in order to specify that attribute. By this you can use vertex colors for shading objects in your rendering but only on the object that has these vertex colors. You can't access vertex colors from another object so that your instanced object can't copy the vertex colors of your instancing particle emitter object.

Grids are totally separated from the mesh itself so that they can't have any connections to UV coordinates onto which the mesh vertices are mapped in the process of UV-unwrapping.

Solution:

If your object instances don't need one color per instance at maximum but can copy the emitter object's surface color rather like a chameleon then try it with object coordinates and choose the particle emitter as the source for theses coordinates. Furthermore set the noise textures on the instancer as well as on the instanced object to "2D" (a 2-dimensional noise texture beeing stretched along local Z):

Instance Objects at Instancer Vertices

This works as long as the object instances don't move away from the particle emitter or - if they move - only along the emitter plane's local Z-axis: Instance Objects emitted along Instancers local Z axis

| improve this answer | |
$\endgroup$
  • $\begingroup$ Very clear explanation, thank you. $\endgroup$ – d401tq May 24 at 20:33

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.