Answers.Body: <p>There are a couple of ways to achieve this:</p>
  
  <ul>
  <li><p>Use a <strong>track matte</strong>. Create a layer with the desired size / shape and put it above the zooming layer. You can use masks to create any shape you want, or use an image that has an alpha channel, or even just a copy of the original layer without the animated scale. On the zooming layer go to the Tack matte / mode panel (you may have to hit <kbd>f4</kbd> to toggle between switches and modes), and choose <strong>Alpha Matte "layer name"</strong>. This will turn off visibility for the top layer, and apply its transparency to the layer below.</p>
  
  <p><img src="https://i.sstatic.net/20E2J.png" alt="enter image description here"></p></li>
  <li><p>Use a layer with the <em>stencil alpha</em> transfer mode above your original layer. This does a similar thing to a track matte, but it's not just for one layer, it's for every layer below the matte layer. And the visibility for the matte layer has to be on for it to work.</p></li>
  <li><p>Use a preComp. Pre-comping replaces the original layer (or layers) with a composition containing just that layer(s). So you want to pre-comp the layer with the animated <strong>Scale</strong> property – select it and hit <kbd>shift</kbd>-<kbd>cmd/ctrl</kbd>-<kbd>c</kbd> or choose <strong>Layer>Pre-Compose</strong> from the menu. In the dialogue that appears choose <em>move all attributes into the new composition</em>. Now you can add a mask to the pre-comp to crop off the scaled edges of the layer. A pre-comp is similar to what you'd get if you rendered the layer as a movie and then brought that back into your comp (but with a few advantages). As the pre-comp is not zooming, just its contents, the mask will crop the edges as the contents get bigger.
  <img src="https://i.sstatic.net/cGasI.png" alt="enter image description here"></p></li>
  </ul>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-01-22T06:12:10.643Z
Answers.LastActivityDate: 2015-01-22T12:37:29.380Z
Answers.LastEditDate: 2015-01-22T12:37:29.380Z
Answers.UserDisplayName: stib
Body: <p>I am using After Effects, i am zooming an image using two keyframes and the scale setting, but as i zoom in, the image gets bigger. </p>
  
  <p>I want the image to have the zoom-in but keep its assigned size. So i want something like "crop" on top of the zoom.</p>
  
  <p>How to do this?</p>
  
Tags: <after-effects>
Title: after effects how to Zoom-in but keep same size (zooming and cropping)
UserDisplayName: Sharky
ThreadText: # after effects how to Zoom-in but keep same size (zooming and cropping)
  
  (Asked by: username_0 on 2015-01-21)
  
  I am using After Effects, i am zooming an image using two keyframes and the scale setting, but as i zoom in, the image gets bigger.
  
  I want the image to have the zoom-in but keep its assigned size. So i want something like "crop" on top of the zoom.
  
  How to do this?
  
  **Tags:** after-effects
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2015-01-22. Score: 3 | Accepted answer
  
  There are a couple of ways to achieve this:
  
  * Use a **track matte**. Create a layer with the desired size / shape and put it above the zooming layer. You can use masks to create any shape you want, or use an image that has an alpha channel, or even just a copy of the original layer without the animated scale. On the zooming layer go to the Tack matte / mode panel (you may have to hit `f4` to toggle between switches and modes), and choose **Alpha Matte "layer name"**. This will turn off visibility for the top layer, and apply its transparency to the layer below.
  
    ![enter image description here](https://i.sstatic.net/20E2J.png)
  * Use a layer with the *stencil alpha* transfer mode above your original layer. This does a similar thing to a track matte, but it's not just for one layer, it's for every layer below the matte layer. And the visibility for the matte layer has to be on for it to work.
  * Use a preComp. Pre-comping replaces the original layer (or layers) with a composition containing just that layer(s). So you want to pre-comp the layer with the animated **Scale** property – select it and hit `shift`-`cmd/ctrl`-`c` or choose **Layer>Pre-Compose** from the menu. In the dialogue that appears choose *move all attributes into the new composition*. Now you can add a mask to the pre-comp to crop off the scaled edges of the layer. A pre-comp is similar to what you'd get if you rendered the layer as a movie and then brought that back into your comp (but with a few advantages). As the pre-comp is not zooming, just its contents, the mask will crop the edges as the contents get bigger.
    ![enter image description here](https://i.sstatic.net/cGasI.png)
  
  
  ---
  
  