|
|
In article <3982D386.884759BC@peak.edu.ee>, Margus Ramst
<mar### [at] peakeduee> wrote:
> I have absolute control over particle mortality :)
> If numbering were the other way around, then theoretically it should
> work. When the oldest particle is 1 and no particles are destroyed,
> all particles should go through the simulation with fixed index
> numbers, yes?
Assuming lifespan is either not specified or is larger than the "time"
value for all emitters, yes. However, remember that particles don't
always die in the order they are created, so this isn't so neat and
simple. I haven't really come up with a good way to do this, though the
unique ID number approach seems to be the best.
How about a get_particle2() function which takes an ID number instead of
an index. The current get_particle() function is still necessary, it
would be the only way to get the particle in the first place.
In other words, have get_particle() take an index between 0 and the
number of particles - 1, and have get_particle2() take a number unique
to each particle, and return 0 if that particle is dead.
--
Christopher James Huff - Personal e-mail: chr### [at] maccom
TAG(Technical Assistance Group) e-mail: chr### [at] tagpovrayorg
Personal Web page: http://homepage.mac.com/chrishuff/
TAG Web page: http://tag.povray.org/
Post a reply to this message
|
|