Our artist made an animated character by over-lapping different body parts. Strange thing, when I fade out the character using an alpha-tween of the outer-most clip, I can see the overlapping parts at the joints. It's like the alpha is affecting the individual parts within the movieClip rather than being applied to the composite movieClip. This is in AS2, and I just use the mx.transitions Tween class. I guess to cacheAsBitmap before doing the tween, but shouldn't alpha be applied to a composited clip by definition? I can't think of any reason why you would ever want an alpha effect to apply to the individual parts within a movie clip. I mean, if I wanted that effect I would set the alphas of the individual parts, right?

This is the usual behavior. It's unrelated to player version, actionscript version, or fading/tweening code used. Alphas of children containers are simply multiplied by the alpha value of the parent container.

If you don't want that "x-ray" effect, set blendMode of the container to "layer". That forces precomposition of the container content before the alpha is applied so it'll fade as a whole. That's the correct solution for that problem.

Using 'empty' filters (say, a blur with a radius of 0) has the same effect. Using cacheAsBitmap *usually* has the same effect too, but it is erratic - depending on changes done to children content, it may force redrawing and you'd lose the flattened transparencies.

With all those solutions, if you use different blendModes on the container children you'll lose them.

Zeh
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to