Skip to main content
Participating Frequently
September 21, 2022
Question

ExtendScript layer world matrix

  • September 21, 2022
  • 1 reply
  • 243 views

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?

This topic has been closed for replies.

1 reply

Community Expert
September 22, 2022