Qt-interest Archive, April 2008
converting a QImage into transparent QPixmap
Message 1 in thread
Dear listener
what's the fastest way to convert a QImage (with or without
tranparency info) into a transparent QPixmap (eg removing the
white/black backgound) ? BTW, at the same time I need also to scale
and rotate the "source" QImage.
thanks in advance
Andy
--
[ signature omitted ]
Message 2 in thread
Do you know the color that you want to convert?
If its truly white or black, I have had the best success with looping
over each line, getting the bytes for the line, and setting the matching
colors to Qt::transparent
Scott
> -----Original Message-----
> From: Andy Hirsh [mailto:andhirsh@xxxxxxxxx]
> Sent: Wednesday, April 16, 2008 8:24 AM
> To: qt-interest@xxxxxxxxxxxxx
> Subject: converting a QImage into transparent QPixmap
>
> Dear listener
>
> what's the fastest way to convert a QImage (with or without
> tranparency info) into a transparent QPixmap (eg removing the
> white/black backgound) ? BTW, at the same time I need also to scale
> and rotate the "source" QImage.
>
> thanks in advance
>
> Andy
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
> "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
--
[ signature omitted ]