PDA

View Full Version : grab images from Phonon video



Kraut~salat
17th January 2009, 22:00
hi,

I'm working on an application that needs to read video files or webcams and then processes the individual video frames. I want to use phonon, because accessing the videos is so simple. But I don't see a way who I can get the imagedata of individual frames.
My algorithems work on QImages, so I need to convert the video frames to QImages.

I tried to use QPixmap::grabWidget(videoWidget) and then transform the QPixmap into a QImage, but I get a lot of graphic errors.

Is there a nicer way to get video frames from Phonon? Phonon seem to be a really abstract API.

muellerp
18th January 2009, 00:00
With Phonon you don't have access to single frames.
There maybe in future support for it, but I haven't seen any commit to it yet.

I don't think you can use Phonon for your purpose.

Kraut~salat
18th January 2009, 09:24
that is sad, although I found something interesting in http://vir.homelinux.org/blog/archives/119-Phonon-+-Quasar.html


Phonon now can give the raw video frames (as RGB, YV12 or YUY2) to an application[...]

This sounds promising, but I could not find any other source confirming that, not even the API docs. The post is from Aug 2008, so maybe this is still beta and not included in my QT4.4.

muellerp
19th January 2009, 09:53
I have read this blog post of Matthias as well.

Let's make it short: Quasar is still in playground of KDE repository - so not even near to release.
As KDE 4.2 is frozen it won't be released till at least 4.3.