Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
1

Expression for individual keyframes

Community Beginner ,
Feb 07, 2024 Feb 07, 2024

Dear community,

 

I've encountered an expression challenge while working on a template. In short, I need to link two specific keyframes (with the same value) to a slider control or a similar solution.The other two keyframes denote the in position with a different x value. In the attached screenshot, I've highlighted the two keyframes, which need to be controlled and represent the out position for a shape layer. Has anyone faced a similar issue and found a solution?

 

Thanks a lot!

TOPICS
Expressions
377
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 07, 2024 Feb 07, 2024
LATEST

It depends on exactly what you're doing, but it might be like this:

s = effect("Slider Control")("Slider");
if (time < key(2).time)
  ease (time, key(1).time, key(2).time, [s,key(1).value[1]],key(2).value)
else if (time < key(3).time)
  value
else
  ease(time, key(3).time, key(4).time, key(3).value, [s,key(4).value[1]])
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines