Image Masks - Completely lost

Scott Rossi scott at tactilemedia.com
Wed Dec 28 13:05:17 EST 2005


Recently, Bob Warren wrote:

>> To apply a mask to an image, you can set the alphaData of one image to
>> the alphaData of another.
> 
> I now understand this as a general objective rather than something that
> can be done directly. I have tried statements like:-
> 
> put the alphaData of image "themask" into the alphaData of image
> "fullcolour"
> 
> set the alphaData of image "fullcolour" to the alphaData of image "themask"
> 
> - and got no joy from RR other than a great fat rasberry!
> ...
> Is that more or less it, or do I still have my knickers in a twist?

Perhaps your knickers are a bit twisted.  I think your problem is the image
you are using for the mask contains *no* transparency information.  If you
want to use images directly as masks, they must be created with transparency
information included.  The white area in your circle image is read as color,
not transparency.

Execute the following in your message box and see if the stack demonstrates
what you are trying to do.

  go url "http://www.tactilemedia.com/download/masktest.rev"

The stack contains two images, both of which were created in Photoshop with
transparent backgrounds; the top image is a GIF with a 1 bit mask, the
bottom is an image with an 8 bit mask.  Notice that the 8 bit mask allows
for a smoother edge appearance.

Regards,

Scott Rossi
Creative Director
Tactile Media, Multimedia & Design
-----
E: scott at tactilemedia.com
W: http://www.tactilemedia.com




More information about the use-livecode mailing list