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

ExtendScript layer world matrix

Explorer ,
Sep 21, 2022 Sep 21, 2022

Hi all,

I'm trying to write an ExtendScript 'equavalent' function of the C++ SDK function:

AEGP_GetLayerToWorldXform

 So far, I've managed to get matching values for any kind of layer using the following forumla:

Ainv * S * R * OR * P where:

Ainv = 4x4 Anchor point inverted matrix.

S = 4x4 Scale matrix.

R =  4x4 rotation matrix.

OR = 4x4 oreintation rotation matrix.

P = 4x4 position matrix.

I ran into non-matching values when I use this formula on a Two-Node Camera Layer, where the Point-Of-Intereset is different from the position of the camera(which make sense).

Does anyone knows how should I embedd the Point Of Intereset values in my formula, or having a different way of "mimicking" the C++ SKD function mentioned above in ExtendScript?

TOPICS
How to , Scripting , SDK
194
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 ,
Sep 22, 2022 Sep 22, 2022
LATEST

i think it's a "look at" kind of calculation.

https://stackoverflow.com/questions/349050/calculating-a-lookat-matrix

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