ReadPixel works in 32bit color but not 16bit ?

Blitz3D Forums/Blitz3D Programming/ReadPixel works in 32bit color but not 16bit ?

I'm locking my image buffer, then using "readpixel", then unlocking the buffer

The value returned is correct when in 32bit colour mode
The value is incorrect in 16bit colour mode

I've tried readpixel fast but same happens

Note I have to use an offscreen image - which is why I'm using "imagebuffer"

Can anyone explain this ?

This should help to explain it...

http://www.blitzbasic.com/codearcs/codearcs.php?code=3

thank you