Hi Eric,

> rowBytes does not have to be even.
> UInt32    numBits = bitsPerPixel * (UInt32) width;
> UInt32    rowBytes = (numBits + 7) / 8;
> 
> How is it that you are having to concern yourself with this?  The
> conversion tools should all handle this properly.  Is your source image
> in an odd depth or something like that?  What tools are you using?

It appears it must be even on older models (strangely, on a Zire it does not
matter, but on a IIIc or Vx it does). I am making the bitmaps from scratch
(I don't need no steeking conversion tools) and they are written to a Palm
database. For example, if I have a 145x145 bitmap in 4-bit grayscale
(rowbytes = 73), I get the odd-address-crash within the call to
WinDrawBitmap. If I pad with 1 byte to make the rowbytes 74 instead of 73,
then everything is happy.

Terry



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please 
see http://www.palmos.com/dev/support/forums/

Reply via email to