View Full Version : Thinking Particles as light sources pt.2
01-04-2013, 10:08 AM
This is to follow up of a question I asked here yesterday & got very good/quick answers to:
Having achieved the individual particles as lights, I have been attempting to create short 'light trails' behind each particle as it moves through space - Much like a small firework would. And then, once collided I want to take the event data & use that to fade out the light.
Unfortunately I have had no luck at all in doing this and was wondering if anyone could point me in the right direction?
I'm aware that I could do a tracer/sweep nurbs combination for the trails, but that has caused me some issues (render artifacts/glitches in tracer start and end points joining) so am keen to know if there are any other techniques or tools I may not know of in C4D.
I've attached my test scene file here, so feel free to open & have a look at my very basic set-up :)
(Apologies if these issues are common or super novice - I have looked thoroughly for any online documentation/tutorials but can't find any. I'm a long time Sidefx Houdini user, so although I understand particle systems, I'm just not used to TP in C4D )
Thanks in advance for any help!
It seems you did not take my tip from your last thread regarding the placement of the original shape into account, you might like to correct this, otherwise you will have the original light visible in the rendering, additionaly to all created particles.
To create the trail just spawn light particles with zero speed (see the TP Presets on this).
On collision kill the old light particle and create a new one with the brightness animated from 100% to 0%. The animation of the brightness will be evaluated over the particles lifetime.
>I moved the thread to the appropriate subforum
01-04-2013, 11:09 AM
what you want is a spwaning emitter. there is one in the presets. the dimming out is more
complicated. you could either use particlegroups and change the particlegroup on collision
(the first particle group has a static particle geometry and the 2nd one after the col. containss the animated particle) or you could use the particle delta time which would be a bit more
a rough sketch of how it could look (the deflector event is fed into the enable port of the group), it is the simple version with 3 particle groups, red - rockets, yellow - sparks before collision, green sparks after collision.
if you want to do this for 'real' you will have most likely to toch python or coffee nodes and
get in touch with simple matrix and vector calculations. you might get away with the
alignment node, but spwaning emitter are more complex than they seem to be.
01-04-2013, 11:14 AM
Thanks for another response & moving this thread to the most suitable location.
I did take your advice - However I accidentally uploaded the 1 version previous to my latest scene version. Sorry about that :/
Could you please explain a little clearer to me what you mean by 'spawn'? I cannot find any presets that you mentioned (a help search yields zero results for 'particle preset'). I have attempted to connect a pstorm/pborn to my particle group in xpresso, but it seems to be reading the scene origin location rather than each individual particle ID (not sure if there is even a particle ID attribute which is accesible in C4D?)
Again sorry if I'm being a little obtuse, I'm just not used to moving around C4D/knowing where's best to pick up attributes.
(I've attached latest file)
thanks, really appreciate it!
01-04-2013, 11:17 AM
Apologies, my question was posted while little_devil was posting, I will look into this now.
Though I'm still a little perplexed as to where I find the presets? :/
Thanks to you both.
01-04-2013, 11:21 AM
i am only on demo here which doesn't come with the presets, so i can not say it for sure, but when i remember correctly the spwaning emitter was actually called spawning emitter and should be located at content browser\presets\tp\oneofthesubfolders\spawningsomething.lib.
you could also just rebuild the first two rows of my screenshot , then you will have also
a spwaning emitter. the basic idea is to move an emitter to the particle positions of
another particle group/stream.
01-04-2013, 12:08 PM
I found the preset thanks to you & though it does what it describes, on reflection I think it would be best for me to stick with the tracer solution for now. (To create the density of lights I require would take a little too long to simulate/render)
I did also end up rebuilding the first part of your screenshot to create the spawner, and it worked quite well! considering it has about 30 nodes less that the preset ;)
I have one final question & then I won't bother you guys again...
I had my tracer setup from a previous file working on all particles, copy pasted it across to my new setup & now is not working on any of the particles. Could someone please take a look at the scene & tell me where the (probably obvious) issue is?
(The light is attributed to the particles correctly, but the sweep isn't)
Thanks again guys!
Maybe also check out the documentation for the presets, it comes with numerous examples
01-06-2013, 12:50 PM
Thanks for the feedback guys!
There's one last thing I'd like to achieve though & I can't figure it out from your descriptions above.
Basically I'd like the intensity of the light to decay to zero by the time a particle dies, but only after collision. I can't figure out how extract the date properly from xpresso.
I've tried birthing another P on collisio, nut it has a different trajectory to the original which isn't the effect I'm after.
Alternatively, it would be just as effective If I could reduce the opacity of the particle from 100% to 0% over the last 20% of a particles life, is there a control for this?
Again apologies if this is basic stuff, I just don't know where to extract the correct data/attributes from!
Thanks for any feedback guys... here's the file!
You can copy the velocity and position from the old particle to the new one on creation, that should give you a continous movement. Alternativley just switch it's shape to the one with animated brightness and set the age to 0.
01-06-2013, 08:37 PM
you could either use multiple particle groups (and shapes) as shrek suggested. or you could also use the particle age. when you drive the particle age manually you can basically play the particle animation forwards and backwards as you like. here is a small example of a particle shape which is animtaed over 25 frames from red to blue. the setup uses a falloff to drive this animation arround an object. the advantage of this is approach is, that you are not bound to the actual length of actual animation of the particle shape, but you can stretch and squash it as you like (as the particles enter the falloff they play their animation forwards, as they leave, they play it backwards).
01-06-2013, 08:37 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2015, Jelsoft Enterprises Ltd.