Create very long trail from moving object

Create very long trail from moving object

DavidHenion
Enthusiast Enthusiast
592 Views
3 Replies
Message 1 of 4

Create very long trail from moving object

DavidHenion
Enthusiast
Enthusiast

I have an object animated to move and want to create a thin trail of its path behind it as it moves. It needs to be really long as I may have to run the animation out for 1000's of frames.

 

Option 1: I can attach an nParticle emitter to it - this works just fine but gets really slow the longer it runs, and would be a pain to cache it all for rendering, etc.

Option 2: I can create a curve for the path and use a sweep mesh, using a partial offset curve to trim the path. I attach the object to the trimmed path as a motion path and set its position along the path to 1 so it stays at the head of the curve. This also works - but the offset curve gets VERY slow once more than about half the curve is revealed. Near the end it takes 10's of seconds to evaluate every frame.

Option 3: Create a nurbs circle and do a partial extrude along the path. For some reason animating the max value of the path subCurve  does not have the same performance problems that offset path does, BUT I can't seem to connect the object to the path subCurve path so can't move the object along the head of the curve.

 

Using Maya 2022 and 2023, both seem to be about the same with the same performance issues.

 

Any ideas for a better way to accomplish this? Either option 1 or 2 would work fine on a shorter animation/path - but become too cumbersome on a really long animation.

0 Likes
Accepted solutions (1)
593 Views
3 Replies
Replies (3)
Message 2 of 4

mcw0
Advisor
Advisor

If your trail is extremely long as you say, at some point, the trail becomes a line, visually.  I'm assuming it's not dissipating like a gas.  So then I think you've touched on ideas that if combined might give you something reasonably manageable.  You've mentioned extruding a circle.  What if you combined nParticles with an extruded surface?  Give a reasonable overlap of particles to leading edge of surface.  Fade out the particles based on position along extrusion/path curve.  And for your surface, have an opacity ramp at the leading edge to blend that into your particles.  

0 Likes
Message 3 of 4

DavidHenion
Enthusiast
Enthusiast

Thank you for the idea, yes the trail is just a thin line and does not dissipate, but do want to avoid using particles. Think I found a solution, will post a separate reply.

0 Likes
Message 4 of 4

DavidHenion
Enthusiast
Enthusiast
Accepted solution

Found a solution that is a variation of option 3 - I extrude a circle along the curve set to "partial" so that I have a subCurve with min and max values. Then attach the object to the curve with a motion path - BUT - use the motion path uValue to drive the extrude's subCurve max value. The end of the extrude and the object on the path didn't line up exactly so just needed to add a slight offset to the extrude subCurve max value, see attach image.

0 Likes