background preloader

Effets

Facebook Twitter

Flex book component (beta) : Ruben’s blog. Create an Impressive Magnifying Effect with ActionScript 3.0. Twice a month, we revisit some of our readers’ favorite posts from throughout the history of Activetuts+. This tutorial was first published in April, 2009. In this tutorial we'll create a magnifying glass effect, demonstrating use of the displacementMapFilter. The effect can be achieved in a relatively short space of time and with very little code. Final Result Preview Let's take a look at what we're aiming for: Step 1: Brief Overview We're going to work with two layers, plus an additional optional layer. An optional fourth layer will be an overlaying graphic acting as the frame or lens surround.

Lets look into it! Step 2: Document Setup First thing we need to do is make a new ActionScript 3.0 Flash file - make the document size 530px X 400px with a framerate of 30fps. Step 3: Import Resources Next we need to import an image that we can use for this effect - I found a cool, freely available desktop image at 1024px X 768px. Import this to stage and name the layer "Image". Step 5: Effect Scale. MC Tween | Animation types. Animation Types When tweening properties with MC Tween, there are several different animation types (or easing equation or transition types) that can be used . They are all based on Robert Penner's easing equations, so if you have played with other tweening systems, chances are you already know them by name (I even used his own words to describe most of the transition types here). If you don't, don't worry; they're quite simple to learn and use: just specify the type you want depending on the transition you want to achieve.

How to chose the best transition type? To exemplify the animation types available in a more graphical fashion, below is a list of all of them with a little animation and some explanation: look at the small circle on the right-side of the movie and notice how different animation types make it move differently. Also notice that the "animation type" parameter is case-insensitive on MC Tween methods. Auto scrolling the contents of a VGroup container in Flex 4 | Fl. Popup Window with light point on title created using PixelBender.