[SOLVED] DrawEllipse and save image problem
Hi to all,
I'm trying to draw an ellipse and save it in a PNG file.
The image is really simple, but I've a problem because the image saved is not clear (it has something like noise...).
@ QImage *placemark = new QImage(QSize(16,16),QImage::Format_ARGB32);
placemark->save(QString("./images/%1.png").arg(name), "PNG")<< endl;
The variable c is a QColor.
The result is this "image":http://dl.dropbox.com/u/3894235/BOAT.png
Have you tried to clear the image first?
It will contain random bits after construction. Cleaning them up takes time and an idea which color the user will want as a background.
If you are going to draw each pixel anyway, then that clean-up time as also wasted.
Thank you so much Tobias!
I've solved by cleaning the image.
I've used this code:
Now it is ok!!