PDA

View Full Version : Need access to individual video frames



themagician
26th November 2012, 09:59
I'm building an application for taking snapshots of videos. I'm aware of other methods like AvsPmod, FFmpeg and MPlayer to generate snapshots, however, I need a better method of finding good snapshots and then having a frame-by-frame fine control over what frame to take a snapshot of.

The typical usage of the application works by loading a video and generating n snapshots every s seconds starting from some position z, for instance starting with 100 snapshots with a 5 second step from the beginning. The snapshots are shown below the video in a scroll area where the user can find a scene with potential for a great snapshot. Double-clicking the snapshots seeks the video to that exact frame. Next it may be desired to generate more snapshots with a smaller step, for instance 1 second step from that scene. And at last when the user finds a great looking snapshot they can use frame-by-frame seeking to capture the best snapshot from that scene.

So I'm looking for a library that provides:

1) Basic video playback functionality
It should play all the common video formats such as DVD VOB and MP4/MKV/AVI (h264, xvid, divx). It should also be able to deinterlace the video automatically and display it in Display Aspect Ratio.

2) Snapshots
It should have functionality to take snapshots (in memory, e.g. to QImage and QPixmap).

3) Frame-by-frame seeking
So I can do prevFrame(), nextFrame(), seekTo(frame), etc.

I have tried the following with the functionality they provide:

Qt Phonon
1. Yes. Plays all the needed formats and displays them correctly.
2. No. Not implemented (returns empty image).
3. No.

QtFFmpegWrapper
1. Partial. Does not deinterlace DVD VOBs. Does not display DVD VOBs in DAR.
2. Yes.
3. Partial. Broken for MKV (h264).

Qt VLC
1. Yes. Plays all the needed formats and displays them correctly.
2. Yes. Via QPixmap::grabWindow(player->videoWidget()->winId()).
3. No. Provides only seeking by milliseconds.

QVision
Video decoding only works on Linux so it's a no-go. I need Windows support as well.

Can I do this with Qt Mobility/Multimedia? Google tells me "Yes" but there's no examples anywhere and I can't find anything in the documentation that would help me.

If not, then what are my options?

Thanks!

Gokulnathvc
26th November 2012, 12:40
Try to download QVision libraries for Windows.

amleto
26th November 2012, 13:40
Try to download QVision libraries for Windows.
this is your third post (within minutes of each other) where it looks like you have not read the OP.