Image Masks - Completely lost

Bob Warren robertum at brturbo.com
Thu Dec 29 09:56:54 EST 2005


In order to complete this thread, I would like to tell you what it was 
that led me up the garden path from beginning to end. This is so that 
other lost souls in the future don't consider suicide.

I have learned that:

1. Picture masks need to include transparency, and for that reason they 
are restricted to GIF and PNG formats.

2. Assignments of the following type really are viable:
   set alphaData of img display to alphaData of img disc.png
   set imageData of img display to imageData of img grad.png

I would also like to thank those who made great contributions towards my 
better understanding of the way images are stored and how they can be 
manipulated (see previous items in the thread, together with links for 
more info).

The help I received culminated in a single example - exactly what I was 
looking for - provided by Scott Rossi at

http://www.tactilemedia.com/download/masktest.rev  .

Considering that it is only a demo, this is an exceptionally 
well-presented example, and it works perfectly.

Now, before actully running it, try changing the size of the output box 
on the right called image "display". When you subsequently run the demo, 
you will get nothing but garbage in the output display box.

The very simple fact, that I have learned the hard way, is that THE 
INITIAL SIZE OF THE OUTPUT IMAGE BOX NEEDS TO BE PRE-SET TO THE EXACT 
SIZE OF THE MASK IMAGE.

If not, NOTHING will seem to work successfully, and you might be tempted 
to speculate wildly, as I did, about the cause of the problem.

Bob






More information about the use-livecode mailing list