title: QMultimedia - Which Video/Audio encodings and containers are supported?
body: <p>I'm trying to make a multimedia database system using Qt. I'm using QMultimedia to play back videos in a QVideoWidget. </p>
  
  <p>The following is the code I am using to play a video file in a QVideo Widget:</p>
  
  <pre><code> mMediaPlayer = new QMediaPlayer();
    mMediaPlaylist = new QMediaPlaylist();
    QMediaContent content(QMediaResource())
    mMediaPlaylist-&gt;addMedia(QUrl::fromLocalFile(QDir(QString("data")).absoluteFilePath(QString("%1.dat").arg(mMedia.GetUID()))));
      mMediaPlayer-&gt;setPlaylist(mMediaPlaylist);
  
  
      mVideoWidget = new QVideoWidget();
      mMediaPlayer-&gt;setVideoOutput(mVideoWidget);
      this-&gt;setCentralWidget(mVideoWidget);
      mVideoWidget-&gt;show();
      mMediaPlayer-&gt;play();
  </code></pre>
  
  <p>Basically, it plays a file called 1.dat for example, which is just a renamed video file (video.mp4 for example). However, playing the video never works, and the following error is produced:</p>
  
  <pre><code>DirectShowPlayerService::doRender: Unresolved error code 80040266
  </code></pre>
  
  <p>With some google searching, I found that this error is because QMultimedia doesn't have the required codecs/filters to play the format of the video. I've tried converting my videos to many different formats using ffmpeg, while trying formats specified at <a href="http://msdn.microsoft.com/en-us/library/windows/desktop/dd407173%28v=vs.85%29.aspx" rel="nofollow">Supported Formats in DirectShow</a> and <a href="http://msdn.microsoft.com/en-us/library/windows/desktop/dd757927%28v=vs.85%29.aspx" rel="nofollow">Supported Media Formats in Media Foundation</a>. I've also tried installing <a href="http://xiph.org/dshow/" rel="nofollow">Directshow Filters for Ogg Vorbis, Speex, Theora, FLAC, and WebM</a>, and converting my video to theora/vorbis in an ogg container. Still no go. </p>
  
  <p>I should note that I did manage to play one mpg file, so I do know QMultimedia is working. But I tried converting another video to mimic the properties of that mpg file, and it didn't seem to work, so it seems QMultimedia is extremely specific in what formats it supports.</p>
  
  <p>What system is QMultimedia using for its backend decoding? How can I find out what types of encodings and containers it supports? Is it possible to write my own decoder in Qt?</p>
  
  <p>Thanks</p>