[Meego-tv] QT Webkit performance tuning for TV platform

donald.carr at nokia.com donald.carr at nokia.com
Wed May 18 12:37:05 PDT 2011


And again.............

One thing I neglected to mention is that your choice should be between the following Qt graphics systems:

Raster
OpenGL

when rendering html content. The default configuration which uses the X11 engine performs absolutely terribly in comparison to either of the above. I would therefor recommend:

QApplication::setGraphicsSystem("raster"); as your opening gambit in your main.cpp, using a QGraphicsWebView with accelerated compositing enabled  and then setting the viewport to being a QGLWidget when rendering controlled constrained tested html. (We have customers optimizing their frontend html code for DirectFB, where the functionality they are hammering is a subset of OpenGL: Blitting, scrolling, blending)

All my best
Donald

On May 18, 2011, at 9:53 AM, ext donald.carr at nokia.com wrote:

> Hey Juan,
> 
> On May 17, 2011, at 11:24 PM, ext Zhao, Juan J wrote:
> 
>>         I found there were many nokia QT experts here. So I raise my question here and hope for some useful information. J
>>         I found that QT Webkit like QWebView inherit QWidget and QGrahpicsView inherit QFrame. All these will use QPainter to draw and the performance is not as good as using QGLWidget.
>>         I tried to use “-opengl” and “—graphicsystem opengl” but he performance is not enhanced. Any idea to enhance this performance here?
> 
> The optimal configuration of your WebView strongly depends on your usage, but the default usage of QWebView is supremely sub-optimal
> 
> You want to use QGraphicsWebView inside of a QGraphicsView, and you want to enable:
> 
> QWebSettings::AcceleratedCompositingEnabled
> 
> You should see significant gains by doing this alone.
> 
> OpenGL can significantly speed up rendering of certain content, but it has to be controlled content as our OpenGL graphics system can produce a fair amount of artifacts or be counter productive if utilized to render a massive amount of primitives.
> 
> If you want to use OpenGL, set the viewport of the QGraphicsView containing your QGraphicsWebView to be a QGLWidget:
> 
> .setViewport(new QGLWidget())
> 
> and set the viewport to full updates:
> 
> setViewportUpdateMode(QGraphicsView::FullViewportUpdate)
> 
> If you are rendering very pixmap heavy content you should be significant performance gains.
> 
> As you can see, there is no silver bullet, but if you are using HTML for developing a controlled constrained animated frontend for large screen devices, this is probably the configuration to use. (I would not recommend using it for rendering random HTML from the world wide web without investigating this yourself)
> 
> Are you collectively aware of this development:
> 
> http://labs.qt.nokia.com/2011/05/11/qtwebkit-2-2-technical-preview-available/
> 
> are you evaluating the state/capabilities of our different webkit branches? Modular discrete webkit releases are clearly the way of the future, and I hope they are suitably visible to you for consideration/usage.
> 
> Yours sincerely,
> Donald Carr
> 
> --
> Donald Carr
> donald.carr at nokia.com
> 
> _______________________________________________
> MeeGo-tv mailing list
> MeeGo-tv at lists.meego.com
> http://lists.meego.com/listinfo/meego-tv

Yours sincerely,
Donald Carr

--
Donald Carr
donald.carr at nokia.com



More information about the MeeGo-tv mailing list