Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [Solved]Media player example not playing .mkv .flv and .mpg files

[Solved]Media player example not playing .mkv .flv and .mpg files

Scheduled Pinned Locked Moved General and Desktop
7 Posts 3 Posters 5.2k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    musimbate
    wrote on 28 Oct 2014, 03:47 last edited by
    #1

    Hello ,
    I am playing with the media player example of Qt5 here :http://qt-project.org/doc/qt-5/qtmultimediawidgets-player-example.html and it is playing .avi and .mp4 files well on my sytem(Windows) .The problem is that it is not playing .mkv ,.flv and .mpg files which I also need to support .

    The doc says

    This example creates a simple multimedia player. We can play audio and or video files using various codecs.

    Am I missing the codecs to play those files ?If so how do I install them and make my Qt application aware of them?

    Thank you for your time .

    Why join the navy if you can be a pirate?-Steve Jobs

    1 Reply Last reply
    0
    • P Offline
      P Offline
      p3c0
      Moderators
      wrote on 28 Oct 2014, 05:40 last edited by
      #2

      Hi,

      AFAIK, Yes you will need codecs to be installed on the system. I used the KLite Mega codec pack.

      157

      1 Reply Last reply
      0
      • M Offline
        M Offline
        musimbate
        wrote on 28 Oct 2014, 08:42 last edited by
        #3

        Thanks for the reply,
        the codec pack you suggested sure installs them .I have "vlc":http://www.videolan.org/vlc/index.html installed on my computer and it can play those files( .mkv ,.flv ,and .mpg) .This means I have the codecs on my computer right? If so why is the media player example picking up .mp4 and .avi codecs and not picking the others?Is there a place I can specify the codecs in Qt media classes?I have been looking in the doc and haven't found a clue.

        Thanks.

        Why join the navy if you can be a pirate?-Steve Jobs

        1 Reply Last reply
        0
        • P Offline
          P Offline
          p3c0
          Moderators
          wrote on 28 Oct 2014, 09:20 last edited by
          #4

          I guess it is not picking up from the vlc. It is because directshow which is used as the backend by multimedia on windows is able to play avi and mp4 files.

          157

          1 Reply Last reply
          0
          • M Offline
            M Offline
            musimbate
            wrote on 28 Oct 2014, 09:54 last edited by
            #5

            I see ,
            I just installed KLite Mega codec pack ,I ran my app hopping the system automatically sets things up but it didn't .It silently doesn't respond when I try to play those unsupported files . How do I make my app know the codecs are there do it can pick them up?

            Thanks.

            Why join the navy if you can be a pirate?-Steve Jobs

            1 Reply Last reply
            0
            • A Offline
              A Offline
              alexRM
              wrote on 31 Oct 2014, 11:41 last edited by
              #6

              With which compiler are you compile?if you use msv the default engine is wmf, if you compile with mingw the engine is directx. Anyway with msvc you can recompile qtmultimedia with directx enabled and sobstitute mediaservice folder in compiler plugins folder

              1 Reply Last reply
              0
              • M Offline
                M Offline
                musimbate
                wrote on 1 Nov 2014, 10:49 last edited by
                #7

                Hi,
                I am working with msvc, I found Qt5's QMediaplayer to be problematic in terms of those codec issues and I found "vlcQt":http://projects.tano.si/vlc-qt to be a better solution for me.

                Thanks.

                Why join the navy if you can be a pirate?-Steve Jobs

                1 Reply Last reply
                0

                1/7

                28 Oct 2014, 03:47

                • Login

                • Login or register to search.
                1 out of 7
                • First post
                  1/7
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • Users
                • Groups
                • Search
                • Get Qt Extensions
                • Unsolved