title: FFmpeg converting from video to audio missing duration
body: <p>I'm attempting to load YouTube videos via their direct video URL (retrieved using <a href="https://github.com/fent/node-ytdl-core" rel="nofollow">ytdl-core</a>). I load them using the <code>request</code> library. I then pipe the result to a stream, which is used as the input to ffmpeg (via <a href="https://github.com/fluent-ffmpeg/node-fluent-ffmpeg" rel="nofollow">fluent-ffmpeg</a>). The code looks something like this:</p>
  
  <pre><code>var getAudioStream = function(req, res) {
      var requestUrl = 'http://youtube.com/watch?v=' + req.params.videoId;
      var audioStream = new PassThrough();
      var videoUrl;
  
      ytdl.getInfo(requestUrl, { downloadURL: true }, function(err, info) {
        res.setHeader('Content-Type', 'audio/x-wav');
        res.setHeader('Accept-Ranges', 'bytes');
        videoUrl = info.formats ? info.formats[0].url : '';
        request(videoUrl).pipe(audioStream);
  
        ffmpeg()
          .input(audioStream)
          .outputOptions('-map_metadata 0')
          .format('wav')
          .pipe(res);
      });
    };
  </code></pre>
  
  <p>This actually works just fine, and the frontend successfully receives just the audio in WAV format and is playable. However, the audio is missing any information about its size or duration (and all other metadata). This also makes it unseekable.</p>
  
  <p>I'm assuming this is lost somewhere during the <code>ffmpeg</code> stage, because if I load the video directly via the URL passed to <code>request</code> it loads and plays fine, and has a set duration/is seekable. Any ideas?</p>