[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyQt] QImage in BI24 format
From:       David Boddie <david () boddie ! org ! uk>
Date:       2012-09-19 21:32:11
Message-ID: 201209192332.19704.david () boddie ! org ! uk
[Download RAW message or body]

On Wed, 19 Sep 2012 09:31:55 -0700, Matt Newell wrote:

> On Wednesday, September 19, 2012 12:19:31 AM Gelonida N wrote:
> > On 09/18/2012 08:13 PM, Gelonida N wrote:

> > > I tried to set the pixel format to QImage.Format_RGB888
> > > and I can see the image.
> > > However the red and blue colors are inversed.
[...]
>
> Any conversion is going to need to be implemented in C++ for best speed.

Possibly, though it might be possible in the general case to use the Python
Imaging Library to manipulate channels in an image.

The simplest solution might be to call the rgbSwapped() method on the QImage
holding the data to obtain an image with the red and blue channels swapped.
This is, of course, done in C++ by the Qt library itself.

David
_______________________________________________
PyQt mailing list    PyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic