PDA

View Full Version : prob on setpixel in Qimage ?



Askar
3rd March 2010, 04:44
Dear Friends,
I m trying to draw on Qimage during run time by using setPixel() but i con't set the pixel..... program running successfully setPixel() function also executed but the pixel value is not changing. the code is ....


QImage *theImage = new QImage;
theImage.setPixel(x1 , y1,0x000000);

Thanks,

Regards,
Askar

aamer4yu
3rd March 2010, 06:23
Is that the code ?
If yes, it wont work because you didnt mention size.
Try QImage *image = new QImage(600,400,QImage::Format_ARGB32);