Phonon::VideoWidget embedded inside a QGraphicsProxyWidget

Reza Shah rshah0385 at kireihana.com
Sat Mar 27 01:18:50 CET 2010


On Sat, Mar 27, 2010 at 3:03 AM, Alessandro Diaferia
<alediaferia at gmail.com> wrote:
> As you currently may be aware of, embedding a Phonon::VideoWidget inside a
> QGraphicsProxyWidget causes the video appealing awfully while playing.

Does this because of high CPU usage?
I played sometime ago with videowidget(gstreamer backend).
I tried image scaling inside VideoWidget::setNextFrame(), instead of
doing it inside paint method ( i mean inside QPainter->drawImage).
Something like this:
m_frame = QImage((uchar *)array.constData(), w, h, QImage::Format_RGB32);
m_frame = m_frame.scaled(640,480);//target size

This helped me to reduce CPU usage, but not sure if it has bad
implication or not (tested using webcam)



--
Reza


More information about the Plasma-devel mailing list