<DIV><FONT face=arial>Hi,</FONT></DIV>
<DIV><FONT face=arial></FONT> </DIV>
<DIV><FONT face=arial>I am a bit confused about the color mapping of BitBlt, esp. mapping (from 32 bits) to 1 bit (for From >> stencil). Checking the sources (in 3.7) gave me the following "hints"</FONT></DIV>
<DIV><FONT face=arial></FONT> </DIV>
<DIV><FONT face=arial>1. From the comment of BitBlt:</FONT></DIV>
<DIV><FONT face=courier>... When blitting from a 32 or 16 bit deep Form to one 8 bits or less, the default is truncation...<BR></FONT></DIV>
<DIV><FONT face=arial>2. From Color class >> colorMapIfNeededFrom: sourceDepth to: destDepth</FONT></DIV>
<DIV><FONT face=courier>... (sourceDepth >= 16) & (destDepth >= 16) ifTrue: [<BR> "mapping is done in BitBlt by zero-filling or truncating each color component"<BR> ^ nil].</FONT></DIV>
<DIV><FONT face=courier></FONT> </DIV>
<DIV><FONT face=arial>3. Color class >> computeRGBColormapFor: destDepth bitsPerColor: bitsPerColor</FONT></DIV>
<DIV><FONT face=courier>... (#(3 4 5) includes: bitsPerColor)<BR> ifFalse: [self error: 'BitBlt only supports 3, 4, or 5 bits per color component'].<BR></FONT></DIV>
<DIV><FONT face=arial>For a simple test I inserted</FONT></DIV>
<DIV><FONT face=arial> <FONT face=Courier> depth >= 16 ifTrue: [^nil].</FONT></FONT></DIV>
<DIV><FONT face=arial>into Color >> maskingMap: depth. And all my stencil tests ran fine.<BR></FONT></DIV>
<DIV>Can anyone could please give me a hint how the color mapping of BitBlt really works? Thanks a lot</DIV>
<DIV> </DIV>
<DIV>Rudi</DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV> </DIV><p>__________________________________________________<br>Do You Yahoo!?<br>Tired of spam? Yahoo! Mail has the best spam protection around <br>http://mail.yahoo.com