Subject: Masking Animation Technique
Difficulty: Intermediate
This tutorial will guide you through the process of using the masking technique in Flash. Using masking you can create movie like transitions or use the effect to control what parts of the animation the user can see.
To begin, open Macromedia Flash and begin a new Flash document.
You will be presented with a blank new document. From this screen you will be able to do everything needed to create a masked animation.
You must first import an image to your stage. This means bringing an image in to Flash so that it can be used as part of the animation. To do this choose File > Import > Import to Stage or press Ctrl+R. Browse your computer and find the image which you want to import and open it. You will now see the image in Flash.
You can edit the size of the image using the image properties at the bottom of the screen when you have the image selected. Try to match it to the size of the canvas and align it so that it is covering the canvas.
Next, on the timeline, located at the top of the screen, insert a frame at frame 60. To do this right click at 60 on the timeline and from the menu select Insert Frame.
Rename that layer on the timeline as ‘Image’ and then lock it. Do this by double-clicking Layer 1 in the layer panel to the left of the timeline and typing in the new name and then clicking the dot underneath the padlock icon. Locking this layer means that it cannot be edited by accident as you progress.
Once you have done that add a second layer. To do this click the new layer button located to the bottom left of the layer panel (circled below). Rename this layer ‘Mask’. Your layer panel will now look like this:
On this new layer you now need to create a circle somewhere near the centre of your image. Select the oval tool from the tool menu at the left of the screen. Select any fill colour for the circle.
Now hold shift to create a perfect circle and click-and-drag out a small circle in the centre of your image.
Select the circle and press F8 to convert to a symbol. This means that it will be saved into the library and can be used again at any time. In the pop-up box that appears name the symbol ‘Circle’ and choose the graphic type.
Next on the mask layer insert a keyframe at 60 on the timeline. Right click on the mask layer under 60 on the timeline and choose Insert Keyframe from the menu.
Keep the 60th frame selected and click on the circle. Go to the menu bar and select Modify > Transform > Scale, then drag out the circle so that it covers the whole image as follows:
To get this shape to mask the image click the first frame of the mask layer and in the properties at the bottom of the screen select motion from the tween options.
After the motion tween is set right-click the mask layer in the layer panel and select ‘Mask’ from the menu. The image is now masked and is revealed as the circle gets bigger.
Press Ctrl+Enter to view your animation in a new screen. It should look something like the animation below: