title: QtMediaPlayer duration is always 0
body: <p>I'm on ubuntu 20.04 using Qt 5.14.
  QtMdeiaPlayer duration always returns 0.
  Documentation states that call to SetMedia is not blocking so duration will be zero right after the call, but I connected a signal as stated in the documentation.</p>
  <pre><code>connect(player, &amp;QMediaPlayer::durationChanged, this, [&amp;](qint64 dur) {
      qDebug() &lt;&lt; &quot;duration = &quot; &lt;&lt; dur;
  });
  </code></pre>
  <p>This lambda is never called. Furthermore audio is playing normally and signal for positionChanged works as expected.
  I tested several audio files of different formats and result is the same.
  Any ideas why it could happen?</p>
  <p>-- edit --
  Minimal code to reproduce</p>
  <pre><code>// somewhere
  static QMediaPlayer *player = new QMediaPlayer;
  
  static void DurationChanged(quint64 duration) {
    qDebug() &lt;&lt; &quot;durration &quot; &lt;&lt; duration;
  }
  
  static void PositionChaned(quint64 position) {
    qDebug() &lt;&lt; &quot;position&quot; &lt;&lt; position &lt;&lt; &quot;duration&quot; &lt;&lt; player-&gt;duration();
  }
  
  // in main
  auto path = QUrl::fromLocalFile(QFileInfo(&quot;sample.mp3&quot;).absoluteFilePath());
  
  QObject::connect(player, &amp;QMediaPlayer::durationChanged, DurationChanged);
  QObject::connect(player, &amp;QMediaPlayer::positionChanged, PositionChaned);
  player-&gt;setMedia(path);
  player-&gt;play();
  
  // my output
  // position 0 duration 0
  // position 1032 duration 0
  // position 2083 duration 0
  </code></pre>