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

Tracking the top middle of a layer for an expression

New Here ,
Feb 03, 2024 Feb 03, 2024

Trying to figure out how I would track the topmost middle of an arbitrarily changing shape layer for use in a expression. Said shape layer changes size to fit the size of a textbox.

TOPICS
Expressions , FAQ
167
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

correct answers 1 Correct answer

Community Expert , Feb 03, 2024 Feb 03, 2024

An expression like this maybe:

L = thisComp.layer("Shape Layer 1");
r = L.sourceRectAtTime(time,false);
L.toComp([r.left+r.width/2,r.top])
Translate
Community Expert ,
Feb 03, 2024 Feb 03, 2024
LATEST

An expression like this maybe:

L = thisComp.layer("Shape Layer 1");
r = L.sourceRectAtTime(time,false);
L.toComp([r.left+r.width/2,r.top])
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