• Keep in touch:
  • Linked In
  • Twitter
  • RSS

How do I make something appear or disappear?

The transparency of an object is changed simply by using an additive colour transform where only the values for the alpha channel are changed.

int delta = 0;
int step = 10;
int count = 255/step;
for (int i=0; i<count; i++, delta -= step) {
    transform = new ColorTransform(0, 0, 0, delta);
    movie.add(new Place2().setLayer(1).setTransform(transform);

It is worth noting that you can change the transparency of any object, even shapes and text where the colours were created without the alpha values (DefineShape, DefineText).