[Qt-interest] Adding arbitrary depth to Graphics Scene & Friends
Jason H
scorp1us at yahoo.com
Tue Apr 26 16:46:25 CEST 2011
Yes, you are missing something. None of the GV operations change underlying
data. They only transform the view of it. The Item is the data. The Scene is the
object hierarchy. The View is the scene objects with transforms applied.
If you are trying to use GV to modify your item data, you are going up the wrong
tree. Only a QPainter will do that.
You might be able to Subclass QGraphicsView and use your derived high BPP
painter. Also, you'd need a QGraphicsItem that would paint() in high BPP. But
how would you do that with standard ARGB items?...
________________________________
From: Javier Urien <javierurien at gmail.com>
To: Jason H <scorp1us at yahoo.com>
Cc: qt-interest at trolltech.com
Sent: Tue, April 26, 2011 10:36:17 AM
Subject: Re: [Qt-interest] Adding arbitrary depth to Graphics Scene & Friends
On Tue, Apr 26, 2011 at 11:28, Jason H <scorp1us at yahoo.com> wrote:
That is all fine and well.
>
>Your data will always be in your maximum bit depth. Your operations (graphics or
>I/O) would write in your bit depth.
>You'd probably want something like:
>QByteArray highBPPData;
>QPixmap displayData;
>
>Do your operations on highBPPData, and when you modify it, either copy/convert
>the effected region of highBPPData (raster op) and splice it into displayData,
>or call the same function on the displayData (like for drawLine() (vector ops)).
>And just use paint(...)to paint the displayData.
>
But what of the operations that the framework provides? For example, if the
framework operates a QGraphicsTransform, it would be on displayData, and if
highBPPData is of different data type I would not be able to map it back. Or
perhaps I am missing something.
Regards.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110426/db89dc72/attachment.html
More information about the Qt-interest-old
mailing list