How to open a video file and just get the first frame to use as a preview? QMediaPlayer not apparent.



  • Is there any way to open a video file and get just the first frame (or preferably just any single frame)?

    QMediaPlayer only has ::play. Yes, in your connected video output (set using setVideoOutput) you could provide knowledge that you just want one frame and you could stop the player there.

    But is there a better way?

    I want to scan a directory full of videos and provide previews or thumbnails of them all in a widget or as treeview icons.



Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.