[Qt-interest] QWebView Blinks In GL Accelerated QGraphicsView
Karol Krizka
kkrizka at gmail.com
Tue Apr 21 07:02:39 CEST 2009
My apologies, but the code I attached in my original email embeds a
QPushButton instead of QWebView. My real test code is basically the
same as the original, but with QPushButton replaced with QWebView
(with a webpage loaded).
I should note that the QPushButton does not flicker under OpenGL, but
still has some rendering problems. For example, when I press the
button, the area right under the mouse pointer is drawn as highlighted
instead of pressed.
--
Cheers,
Karol Krizka
http://www.krizka.net
On Mon, Apr 20, 2009 at 9:56 PM, Karol Krizka <kkrizka at gmail.com> wrote:
> Hi all,
>
> I am working on an animated UI in Qt, so I'm embedding QWidgets in a
> QGraphicsView. However, when I turn on OpenGL acceleration in Qt 4.5.0
> by setting the viewport to a QGLWidget() and embed a more complex
> widget, like QWebView, the widget starts flickering when I move my
> mouse over top of it. I have this problem on both Linux (Gentoo) and
> Windows (XP). I didn't have this problem with Qt 4.4. Has anyone
> experienced this before?
>
> I'm using the following code:
> #include <QApplication>
> #include <QGLWidget>
> #include <QGraphicsView>
> #include <QGraphicsScene>
> #include <QWebView>
>
> int main(int argc,char* argv[])
> {
> QApplication app(argc,argv);
>
> QGraphicsScene scene;
> QGraphicsView view(&scene);
>
> QGLWidget viewport(&view);
> view.setViewport(&viewport);
>
> QPushButton wdg;
>
> scene.addWidget(&wdg);
>
> view.show();
> return app.exec();
> }
>
> --
> Cheers,
> Karol Krizka
> http://www.krizka.net
>
More information about the Qt-interest-old
mailing list