It is always better to pre-comp the elements of one animtion into one single comp.
[it's difficult to work with because you're animating the whole comp]
See this tutorial how to Aharon has animated a flock of bird:
Make sure your pre-comp resolution is not too big. Press "Cmnd/Cntrl + K" and keep the comp resolution smaller so that the butterfly just covers the comp.
The procedure is called rigging. Rigging a butterfly should only take about 5 minutes.
Take a nice image of a butterfly from the top and position it so the body is vertical with the head at the top.
- Use the pen tool to create two masks. One for the body and one for the left wing.
- Move the anchor point of the layer to the right edge of the left wing.
- Make the layer 3D
- Name the layer something like butterflyL
- Duplicate the layer and rename the duplicate body
- If you want to have antennae on the butterfly use the pen tool to create a couple of stroked paths. Make the shape layer 3D and make it a child of the Body layer.
- Delete the mask for the left wing on the butterfly layer
- Duplicate the butterfly layer and rename it something like butterflyR
- Set the scale of the butterflyR layer to 0
- Add the following expression to the Y rotation property of the butterflyL layer:
- value - thisComp.layer("butterflyR").transform.yRotation
- Add the following expression to the scale property of the butterfly L layer:
- value + thisComp.layer("butterflyR").transform.scale
- Set the rotation of the butterflyL layer to 180º
- Move the butterfly R wing so that the left edge is adjacient to the right edge of the body layer
- Here's the trick. Parent the left wing and the right wing to the body.
- Select the body layer and press Ctrl/Cmnd + Alt/Option + o (Layer > Transform > Auto Orient) and set the oriientation to Orient Along Path.
- Lock the Left wing and the antennae layer
- Animate the y rotation of the butterflyR (right wing) layer. I usually use just 4 or five random keyframes and add loopOut(cycle = "pingpong") to the property
- Lock the right wing layer.
- Animate the position of the body layer.
- Adjust the orientation of the body layer to line the body up with the path. 270º, 0º, 0º should work nicely
As a final step add a 3D null to the composition and make it the parent of the body. This will help you line up your butterfly in 3D space.
There you go. No need to pre-compose. If you are adding this butterfly to some live footage you can use AE's Camera Tracker to tie the butterfly to a null and it will be amazing. If you wanted to stop the flapping of the wingsa a simple pre-compose of this group of layers and a time remap with a new key frame where you want the flapping to stop would do the trick.
Here's a Project File (cs6 and 5.5) file with an example that took me about the same amount of time to create as it did to write this post.
Thanks so much Rick, so nice of you to take the time to write a step by step tutorial. I will try it out. One question though: how do you create two masks with one layer?
Finnish one mask and start another one. You can put as many masks as you'd like on a single layer.
I just put up a short video on how to rotoscope that shows masking clearly. I'm just uploading the version with audio so it may be a few minutes before this video is ready.
I gave it a try, but it did not work. I may be a little bit too novice for some of the steps you described. For exemple, I was a little confused with step 9:"Set the scale of the butterflyR layer to 0". At that point, lost both wings and it got messy. I will try later. I need to understand what I'm doing. Thank you for your help.
Did you download the project file? Do so and then take it apart. I actually left out a step that was unneeded. You don't have to set the scale of the right wing to 0 unless you add the fancy expression that I left out to the right wing scale property.
Here, I've made a screen cap movie of the process. It's currently WO audio but it should give you an idea of the steps. It's just under 2 minutes. Enjoy.
I may be a little bit too novice for some of the steps you described.
Rick has explained the Steps pretty well. But if you have problem in understanding the steps, here is another tutorial which may help :
Rick[Did you download the project file?]
The Project file link is broken. I think thats why Dynopete is unable to understand the steps.
This actually how I did the animation. Much more simple for me to do. But I will for sure study Rick's tutorial and maybe use the project files if the link is made available again.
Glad to help
Thanks a bunch Rick. That is so nice of you. I will study it and come back to you if I have questions.