{"repo":"rendertom/LST","free":true,"listed":false,"github":"https://github.com/rendertom/LST","clone":"git clone https://github.com/rendertom/LST.git","description":"Layer Space Transforms for Adobe After Effects","language":"JavaScript","stars":41,"topics":["aftereffects","layer","matrix"],"license":"Apache-2.0","category":"chat-messaging","readme_excerpt":"LST # LST, short for Layer Space Transforms , is a utility class for Adobe After Effects, that helps calculating layers position in composition scope, very similar to toWorld() and toComp() methods available inside expressions. Why LST? ## The old fashioned way to get layer coordinates in ExtendScript in composition scope, when it had a chain of parents, was to: - create a temp layer in the composition, - apply the expression to a temp layer that uses toWorld() method - read expression value and pass it back into ExtendScript, - remove the junk layer. That's not an ideal way to handle things in ExtendScript, especially in cases when the layer position depends on its index value. That's where LST comes into play - it doesn't use any of this nonsense. LST logic is entirely based on matrix calculations and Model-View-Projection logic. This allows retrieving a layer's data in any scope - composition, as well as in a camera, no matter how many parents it has. API ## LST.toComp(layer, offset); Transforms a point from layer scope into composition scope. LST.toWorld(layer, offset); Transforms a point from layer scope into view-independent world scope. The offset coordinates parameter is optional. If not provided, uses layers Anchor Point value. To get layers top-left corner coordinates, pass in [0, 0, 0] . Both methods return 2 or 3 dimensional Array . Usage ## Download the repository and include the class in your main script. Case 1 ### Case 2 ### Case 3 ### --- Notes ## LST assumes","default_branch":null,"files":null,"tree":[],"storefront":"/r/rendertom","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/rendertom/LST/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}