Brian, that's awesome! How long have you know this and not told anyone? ;-)
Ken Ray Sons of Thunder Software Email: [EMAIL PROTECTED] Web Site: http://www.sonsothunder.com/ ----- Original Message ----- From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, July 05, 2002 6:19 PM Subject: Re: Images and Image Data > While we are still on this thread... (thanks Ken, Scott- cool stuff)... > > If you want to use alphaData to adjust the opacity of images, this works real > fast: > > setprop opacity x > put min(100,x) into x > put max(1,x) into x > put the alphaData of me into aData > replace (char 1 of aData) with binaryEncode("C",(255*x/100)) in aData > set the alphaData of me to aData > end opacity > > Then just say: > ## 75% opacity > set the opacity of image "someImage" to 75 > > DISCLAIMER: don't use this method if you do anything which sets alphaData > values which vary anywhere within the alphaData. If you do, you can do this, > which is still faster than building byte-by-byte: > > put binaryEncode("C",(255*x/100)) into x > repeat with i=1 to 255 > replace numToChar(i) with x in aData > end repeat > > Best Regards, > Brian > _______________________________________________ > metacard mailing list > [EMAIL PROTECTED] > http://lists.runrev.com/mailman/listinfo/metacard > _______________________________________________ metacard mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/metacard
