Answers.Body: <p>The overlord plugin can do this with simple shapes from AI.
  <a href="https://www.battleaxe.co/overlord/" rel="nofollow noreferrer">https://www.battleaxe.co/overlord/</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-11-23T09:19:48.863Z
Answers.LastActivityDate: 2020-11-23T09:19:48.863Z
Answers.UserDisplayName: tomh
Answers.Body: <p>I don't think that it's possible to import AI shapes as parametric shapes (in 2019 at least, this might change, with luck). There are workarounds that can help though.</p>
  
  <p>If you convert the AI layer to a shape layer you can get the individual points of the path like so:</p>
  
  <pre><code>var pts = thisComp.layer("test Outlines").content("Group 1").content("Path 1").path.points(t = time)
  </code></pre>
  
  <p>where the layer <strong>"test outlines"</strong> is the shape layer created by converting the AI document, and <strong>Group 1</strong> is one of the paths in the shape layer. Then for a rectangle you can get the size like this:</p>
  
  <pre><code>var pts = thisComp.layer("test Outlines").content("Group 1").content("Path 1").path.points(t = time);
  var size = pts[0] - pts[2];
  </code></pre>
  
  <p>if you want to set the size you could do the reverse, putting this on the path property:</p>
  
  <pre><code>var size = [123, 45];
  var pts = [[0, 0] - size/2, [0 - size[0]/2, size[1]/2], size/2, [size[0]/2, 0 - size[1]/2];
  createPath(points = pts, inTangents = [], outTangents = [], isClosed = true);
  </code></pre>
  
  <p>if you do the substitutions you'll see that the second line works out to</p>
  
  <pre><code>[-61.5, -22.5], [-61.5, 22.5], [61.5, 22.5], [61.5, -22.5]]
  </code></pre>
  
  <p>which describes a rectangle 123 wide and 45 high.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-10-30T00:42:55.477Z
Answers.LastActivityDate: 2019-10-30T00:42:55.477Z
Answers.UserDisplayName: stib
Body: <p>I need to rig up some expressions to a shape layers "size" and "position" parameters and the layer transform "position" parameter as well. When I create the shapes directly in AE there are the shape parameters of size, position and rotation. Though, when I import AI files and convert them then they lose the options of the shape itself and the only option that is available to edit is the "path" parameter. </p>
  
  <p>How do I import AI files as parametric shapes not a bezier shape?</p>
  
Tags: <after-effects>
Title: Importing Adobe Illustrator files as Parametric shapes in After Effects?
UserDisplayName: Ision Industries
ThreadText: # Importing Adobe Illustrator files as Parametric shapes in After Effects?
  
  (Asked by: username_0 on 2019-10-29)
  
  I need to rig up some expressions to a shape layers "size" and "position" parameters and the layer transform "position" parameter as well. When I create the shapes directly in AE there are the shape parameters of size, position and rotation. Though, when I import AI files and convert them then they lose the options of the shape itself and the only option that is available to edit is the "path" parameter.
  
  How do I import AI files as parametric shapes not a bezier shape?
  
  **Tags:** after-effects
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_1 on 2020-11-23. Score: 0
  
  The overlord plugin can do this with simple shapes from AI.
  <https://www.battleaxe.co/overlord/>
  
  
  ---
  
  ### Answer by username_2 on 2019-10-30. Score: 0
  
  I don't think that it's possible to import AI shapes as parametric shapes (in 2019 at least, this might change, with luck). There are workarounds that can help though.
  
  If you convert the AI layer to a shape layer you can get the individual points of the path like so:
  
  ```
  var pts = thisComp.layer("test Outlines").content("Group 1").content("Path 1").path.points(t = time)
  
  ```
  
  where the layer **"test outlines"** is the shape layer created by converting the AI document, and **Group 1** is one of the paths in the shape layer. Then for a rectangle you can get the size like this:
  
  ```
  var pts = thisComp.layer("test Outlines").content("Group 1").content("Path 1").path.points(t = time);
  var size = pts[0] - pts[2];
  
  ```
  
  if you want to set the size you could do the reverse, putting this on the path property:
  
  ```
  var size = [123, 45];
  var pts = [[0, 0] - size/2, [0 - size[0]/2, size[1]/2], size/2, [size[0]/2, 0 - size[1]/2];
  createPath(points = pts, inTangents = [], outTangents = [], isClosed = true);
  
  ```
  
  if you do the substitutions you'll see that the second line works out to
  
  ```
  [-61.5, -22.5], [-61.5, 22.5], [61.5, 22.5], [61.5, -22.5]]
  
  ```
  
  which describes a rectangle 123 wide and 45 high.
  
  
  ---
  
  