diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-02-14 19:02:28 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-02-14 23:45:57 +0300 |
commit | b5fe00d1ac43c16ec8f74d3ad7689599dfb2ef00 (patch) | |
tree | e2dcae056cde3c6eaa3bcaf2c1b9117a0a5e87a1 /intern/cycles/kernel/shaders | |
parent | f6107af4cf4d907495e2e9c18e5866fd1d420650 (diff) |
Cycles: restore Particle Info Index for now, keep it next to Random.
It seems to be useful still in cases where the particle are distributed in
a particular order or pattern, to colorize them along with that. This isn't
really well defined, but might as well avoid breaking backwards compatibility
for now.
Diffstat (limited to 'intern/cycles/kernel/shaders')
-rw-r--r-- | intern/cycles/kernel/shaders/node_particle_info.osl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/intern/cycles/kernel/shaders/node_particle_info.osl b/intern/cycles/kernel/shaders/node_particle_info.osl index 05358400bf8..2a0252d5e45 100644 --- a/intern/cycles/kernel/shaders/node_particle_info.osl +++ b/intern/cycles/kernel/shaders/node_particle_info.osl @@ -17,6 +17,7 @@ #include "stdosl.h" shader node_particle_info( + output float Index = 0.0, output float Random = 0.0, output float Age = 0.0, output float Lifetime = 0.0, @@ -25,6 +26,7 @@ shader node_particle_info( output vector Velocity = point(0.0, 0.0, 0.0), output vector AngularVelocity = point(0.0, 0.0, 0.0)) { + getattribute("particle:index", Index); getattribute("particle:random", Random); getattribute("particle:age", Age); getattribute("particle:lifetime", Lifetime); |