Flash CS4 eraser effect using lineBitmapStyle method

Posted in Flash by Flash CS3 and Flash CS4 tutorials on the 10-08-2009

We have seen how to create a drawing board and export PNG from SWF at runtime, this time we’ll see how to create an eraser effect using Actionscript 3.0.
I divided the tutorial into two samples, the first one uses lineStyle method with the same color of SWF’s background, in this case, however, is necessary to have a single solid color as background.
Instead the second one sample uses the lineBitmapStyle method in case we have as a background image or a multicolored background.

  1. First case: I have an image on the Stage with a single colored background and use the same color as the background to draw on the image.
  2. Second case: I have an image on the stage with a colorful background and uses the background colored pixels that are on the current mouse position to draw the image and thus here seems to erase the image using a real eraser tool.

Read more…

Tags: , , ,

Related posts


Read full article

  1. Responses to “Flash CS4 eraser effect using lineBitmapStyle method”

Post a Comment

captcha