PDA

View Full Version : How to access each bit of QImage.



noufalk
28th February 2008, 05:33
Hello ,

This might be a easy question but I couldn't figure it .
I am using QT 2.3.10,I need to access each bit of QImage having the width 590 , height 470 and depth 1 .Qt provides a function uchar* QImage:: scanLine(int) to access a bit(pixel) ,by reading the Qt reference documentation doesn't provide a clear idea in solving my problem (mentioned above).

Any suggestions will be highly appreciable

Thanks
Noufal k

jpn
28th February 2008, 07:28
Use QImage::bits() (http://doc.trolltech.com/2.3/qimage.html#dc0cf3) or QImage::pixel() (http://doc.trolltech.com/2.3/qimage.html#ecfb25).

noufalk
29th February 2008, 06:17
Thanks Jpn..