Skip to main content
Participant
February 3, 2021
Question

Issues with Corner Pinning + Collapse Transformation

  • February 3, 2021
  • 1 reply
  • 1653 views

I recently finished a project where I had to composite a video-confrence pre-comp into a computer screen. The .mov/shot of the computer screen was static but at an angle, so I applied Corner Pin to the pre-comp into the computer screen. My client wanted a slow moving close up of the computer screen. I made my .mov and comp both 3d layers, applied collapse transform to preserve quality in the pre-comp, and made a 3d camera and animated it to zoom in.

 

However, this is when I noticed that my corner pinned comp fell out of alignment with my computer screen (see example attachments). All layers in the pre-comp were 3d and rasterized where applicable. The same issue happened when scaling up the .mov and pre-comp as 2d instead of using a cam. Only when collapse transform was turned off did corner pinning work. 

 

Does anyone know why this is happening? I tried using toWorld or toComp on the corner pin coordinates to see if those methods could help but I'm not a strong scripter and couldn't get it to work.

This topic has been closed for replies.

1 reply

Roland Kahlenberg
Legend
February 4, 2021

I see issues with your workflow. 

* Corner Pin should be applied to the 'final comp', the composition where you create the composite; the pre-comp, if you need one, is where you size/re-size your insert footage such that it is the same size as your 'final comp'. BTW, this is the workflow for tracking and doing screen/signage inserts.

 

AND, read the section on Render Order ... to have a better grasp of AE's Render Order with respect to Layer Transformations, Masks and Effects and how the Continuously Rasterize/Collapse Transformations switch affects the Render Order. Then to mess your head up even more, dive into how 3D layers, 3D + 2D layers are affected by the SAID switch. And when you've just made headway and gotten some breathing space; look into Adjustment Layers, with and without Masks help/destroy your workflow.  🙂

https://helpx.adobe.com/after-effects/user-guide.html/after-effects/using/precomposing-nesting-pre-rendering.ug.html

 

Very Advanced After Effects Training | Adaptive & Responsive Toolkits | Intelligent Design Assets (IDAs) | MoGraph Design System DEV
Participant
February 5, 2021

Thanks for your reply Ron! This article was insightful :). I don’t have great knowledge with rendering order and it was helpful and useful to see how it prioritizes order with collapse transform on or off. I think I’m reading your message correctly and I apologize if I used incorrect terms and, more likely, inaccurately explained my issue. I believe I have solved the issue and wanted to post this in the event someone else had run into it.
 
My pre-comp I considered, as your reffer to, my final-comp/composite to insert into the computer screen. Nested inside the final-comp were other comps and video files to make up the composite (as you said to adjust the footage, manipulate the contents of the final-comp). All layers nested inside the final-comp were swited to 3D and collapse transform to take advantage of rasterization. Same as the final-comp, switched to 3D and collapse transform, to keep the final-comps contents rasterized.
 
The issue I was experiencing was converting the cornerpin coordinates on the final-comp from layer space to world space. That way the cornerpin coordinates on the final-comp would update/scale relative to the computer screen when I moved a camera or scaled up it’s parent layer (computer screen). The nested contents of the final-comp were behaving as intended with collapse transform activated (transforming relative to a 3D camera position); However the cornerpin window on the final-comp was not, and zooming into the screen resulted in revealing the mask cut out on the computer screen and the alpha channel behind it, all while scaling the final-comp's content in a tiny cornerpin window.
 
This article from Dan Ebbert contained a javascript conversion that resolved the issue. It required some javascript and creating 3D nulls. I had to create four 3D-Nulls, position them where I wanted the corner pins to be (corners of the computer screen, layer switched to 3D as well), then link the coordinates of the cornerpins respectivly to the anchorpoints of the four nulls. To do this the four cornerpin coordinates on the final-comp needed to convert the null's positions to comp space from world space, and then I had to covert those coordinates from comp space to layer space.

Participant
February 5, 2021

I meant Roland! I'm very sorry.