Another BitmapData Effect

These last times, we can see on some website a similar effect on bitmaps (like Wrangler or Vitaly Shepelev’s portfolio).

It’s rather simple to reproduce this kind of effect. You just have to play with bitmap channels (red, green and blue). You have to extract each channel and after that you can do whatever you want with them.

To do that, you can use the copyChannels method from BitmapData class :
copyChannel(sourceBitmapData:BitmapData, sourceRect:Rectangle, destPoint:Point, sourceChannel:uint, destChannel:uint):void

And don’t forget to change the blend mode to “add” :
myBitmap.blendMode = BlendMode.ADD;

Here is a little demo of this effect. You can change the speed animation, the delay for each channels and you can group two channels together to produce others colors during the animation.

Get Adobe Flash player

Download sources ChannelsMover - version 1.0 (81.67 kB)

This tutorial use MinimalComps and TweenLite
PS : To know more about this photo

Leave a comment

Archives