<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Re: Fun With ImageData, MaskData and AlphaData</TITLE>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<STYLE type=text/css>BLOCKQUOTE {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
DL {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
UL {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
OL {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
LI {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
</STYLE>
<META content="MSHTML 6.00.2716.2200" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT size=2>Thanks for the kudos, Mark! Yeah, I discovered that that bytes
are switched between Mac and Windows; glad you got some use out of
it...</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>Ken Ray<BR>Sons of Thunder Software<BR>Email: <A
href="mailto:kray@sonsothunder.com">kray@sonsothunder.com</A><BR>Web Site: <A
href="http://www.sonsothunder.com/">http://www.sonsothunder.com/</A></FONT></DIV>
<DIV> </DIV>
<BLOCKQUOTE dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=luetzm@texasreading.org href="mailto:luetzm@texasreading.org">Mark
Luetzelschwab</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=metacard@lists.runrev.com
href="mailto:metacard@lists.runrev.com">metacard@lists.runrev.com</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Friday, July 05, 2002 10:52
AM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> Re: Fun With ImageData, MaskData
and AlphaData</DIV>
<DIV><BR></DIV>
<DIV>Ken,</DIV>
<DIV><BR></DIV>
<DIV>Thanks for sharing these functions about imageData, etc....they were
always in the arena of "when I might have some time"...but now they are quite
within my grasp!</DIV>
<DIV><BR></DIV>
<DIV>Two items:</DIV>
<DIV><BR></DIV>
<DIV>1. The order that you had in your example for making the 50% transparent
blue image:</DIV>
<DIV><BR></DIV>
<DIV><FONT face="Courier New" color=#000000 size=+2>repeat with i = 1 to
400<BR> put binaryEncode("CCCC",255,0,0,0) after
iData<BR> put binaryEncode("C",128) after
aData<BR> end repeat</FONT></DIV>
<DIV><BR></DIV>
<DIV>did not work for me on my Mac, using 2.3.2</DIV>
<DIV><BR></DIV>
<DIV>I had to switch the order:</DIV>
<DIV><BR></DIV>
<DIV><FONT face="Courier New" color=#000000 size=+2>repeat with i = 1 to
400</FONT></DIV>
<DIV><FONT face="Courier New" color=#000000
size=+2> put binaryEncode("CCCC",0,0,0,255) after
iData</FONT></DIV>
<DIV><FONT face="Courier New" color=#000000
size=+2> put binaryEncode("C",128) after
aData</FONT></DIV>
<DIV><FONT face="Courier New" color=#000000 size=+2> end
repeat</FONT></DIV>
<DIV><BR></DIV>
<DIV>2. Just for fun - I added a red-to-blue gradient..you can add to your
page if you so desire!</DIV>
<DIV><BR></DIV>
<DIV>(this is for a 16 x 16 image - will require some more calculations for
other images)</DIV>
<DIV><BR></DIV>
<DIV>repeat with i = 1 to 256<BR> put
binaryEncode("CCCC",0,min(i,255),0,max(255,255-i)) after
iData<BR> put binaryEncode("C",128) after aData</DIV>
<DIV> end repeat</DIV>
<DIV><BR></DIV>
<DIV>Thanks again - your work is most appreciated!</DIV>
<DIV><BR></DIV>
<DIV>-ml</DIV>
<DIV><BR></DIV><X-SIGSEP><PRE>--
</PRE></X-SIGSEP>
<DIV>Mark J. Luetzelschwab<X-TAB>
</X-TAB><X-TAB>
</X-TAB><X-TAB>
</X-TAB>luetzm@texasreading.org <BR>Texas
Center for<X-TAB>
</X-TAB><X-TAB>
</X-TAB><X-TAB> </X-TAB>(v) (512)
232 9477<BR>Reading and Language Arts<X-TAB>
</X-TAB><X-TAB> </X-TAB>(f) (512)
232 2322<X-TAB>
</X-TAB><X-TAB>
</X-TAB><BR>http://www.texasreading.org</DIV></BLOCKQUOTE></BODY></HTML>