Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Trim paths and offset issue

  • Trim paths and offset issue

    Posted by Adam Lewen on September 16, 2019 at 1:30 pm

    Hi.
    When animating a dashed stroke with trim paths, once the line starts animating in or out, the dashes run fast.
    How can I prevent it? I would like to have the dashes moving (offset) in the same speed and not to be effected by the fact its trim paths start/end…

    Thanks so much!

    Adam Lewen replied 6 years, 8 months ago 2 Members · 2 Replies
  • 2 Replies
  • Walter Soyka

    September 17, 2019 at 10:36 am

    Can you cheat? Duplicate the shape layer, animate Trim Paths use a slightly thicker, non-dashed stroke, and use it as a track matte for the dashed layer underneath?

    Otherwise, the best I can figure is approximate the length of the path and use that to drive the dash’s Offset value as the Trim Paths “Start” property is animated with an expression like this:

    var approxPathLength = length(content("Path 1").path.pointOnPath(0, time), content("Path 1").path.pointOnPath(0.01, time)) * 100;
    linear(content("Trim Paths 1").start, 0, 100, 0, approxPathLength)+value;

    Walter Soyka
    Designer & Mad Scientist at Keen Live [link]
    Motion Graphics, Widescreen Events, Presentation Design, and Consulting
    @keenlive   |   RenderBreak [blog]   |   Profile [LinkedIn]

  • Adam Lewen

    September 18, 2019 at 6:05 am

    Walter! What a simple solution! ☺ Why the hell didn’t I think about it?!
    Thanks so much! Big help!

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy