6 Replies Latest reply on Oct 26, 2016 3:24 AM by Roei Tzoref

    Duplicate and move solid automatically

    Joe Bodego Level 1

      I have a 1920X1080 comp and i want 8 solids evenly on the 1920 side. so that means each solid has to be 1080 by 240. I there a way to automate this like you can in Illustrator? Right now i have to duplicate and move each solid?

        • 1. Re: Duplicate and move solid automatically
          Mylenium Most Valuable Participant

          You can apply an expression so things snap into place everytime you duplicate something. Otherwise AE does have alignment tools just like AI...

           

          Mylenium

          • 2. Re: Duplicate and move solid automatically
            Roei Tzoref Adobe Community Professional

            A few ways to do this accurately. Here's one approach: make one, snap it to the right by holding the ctrl/cmd key or allow snapping. duplicate and snap to the left. Now duplicate 6 times and select all and use window->align to distribute.

            • 3. Re: Duplicate and move solid automatically
              Rick Gerard Adobe Community Professional & MVP

              You can grab the position of the layer above with an expression and then add the layer's width to the x value. The only trick is that the first layer in the group would not have an expression. Now every layer below the top will be positioned exactly next to the layer above no matter what the size. If you threw in a calculation that compared the half the layer's width then it wouldn't make any difference how wide each layer was, each would line up perfectly with the layer above it. You just can't have an expression in the top layer in the stack.

               

              The expression looks like this:

              L = thisComp.layer(index-1);

              x = L.position[0] + L.width/2 + width/2;

              y = L.position[1];

              [x, y]

              This is just one of my 200+ custom animation presets. You should be able to figure out how to write it so it would stack up layers by height also. It would be a good exercise in basic expression language.

               

              If you really wanted to get fancy you could throw in a calculation for scale so no matter what size or what scale a layer was they would stack right next to each other horizontally or vertically. I also have this as one of my animation presets.

               

              The other easy option is to use a shape layer and a repeater instead of solids.

              • 4. Re: Duplicate and move solid automatically
                Roei Tzoref Adobe Community Professional

                a way to simulate the duplicate+copy feature of illustrator is this:

                1. duplicate your layer and move to the desired distance

                2. duplicate once more and Alt+parent to the previous.

                when you are done you can remove the parenting

                001.gif

                • 5. Re: Duplicate and move solid automatically
                  Joe Bodego Level 1

                  This is not making sense at all, "alt click what" don't you think you should explain that? your animation explains nothing

                  • 6. Re: Duplicate and move solid automatically
                    Roei Tzoref Adobe Community Professional

                    This is not making sense at all, "alt click what" don't you think you should explain that? your animation explains nothing

                    it's hard for a user responding to a thread to know the experience level of the original poster. if the original post was starting with something like "new user of After effects", I would have broken down my workflow to more tiny bits. if you search for the term "Alt+Parent" in even google, you will find many results.

                     

                    the gif shows how this is done but there is no way for me to show you the shortcut's I am clicking on unless I manually add text layers to my screen capture but guess you were expecting a tutorial. Here is one:

                    http://www.sternfx.com/blog/index.php/04-2011/alternative-parenting/