title: FFMPEG Image2pipe Producing Broken Video
body: <p>I'm trying to write a program that pipes PNG data into FFMPEG to render it into a video. The program's video output wasn't working so I am using PNG screenshots as debug input. </p>
  
  <p>The screenshots are all valid PNG files that open normally in any image viewer. However when I run the command:</p>
  
  <pre><code>cat 2017*.png | ./ffmpeg -f image2pipe -r 1 -vcodec png -i - -vcodec libx264 out.mp4
  </code></pre>
  
  <p>I do get a video output that has 1 second of video for each screenshot starting with 2017 in the directory. However, the video is entirely black and finishes <strong>instantly</strong> after starting to play the video. (Not one second or frame for each frame).</p>
  
  <p>This is on MSYS on Windows, using a Windows version of FFMPEG, if it makes any difference. </p>
  
  <p>What can I change so it will actually make a video out of the piped input? My first guess is that it might have something to do with either incorrect args or a lack of an appropriate codec. </p>