title: Write video to pipe FFMPEG
body: <p>I want to merge some mp4 videos
  My problem is that when I read a file from /mnt/filestorage (remote disk) I get a heavy traffic load. I see 2 solutions to this problem.</p>
  <ol>
  <li>Get FFMPEG to read slower e.g. 100kb/sec (it didn't work for me).</li>
  </ol>
  <p>I tried playing with -blocksize parameter, but no results;</p>
  <ol start="2">
  <li>With java read the file (e.g. by chunks) and send it immediately to FFMPEG input stream.
  The second variant seems feasible to me, but every time I've encountered three kinds of errors</li>
  <li>Broken pipe</li>
  <li>Stream closed</li>
  <li>Invalid data input
  Perhaps I'm doing something wrong, or maybe I'm missing some arguments.</li>
  </ol>
  <p>I would be glad to see your code examples.</p>
  <p>My startup line</p>
  <pre><code>ffmpeg.exe -protocol_whitelist pipe,file -y -i - -f mp4 -c copy out.mp4
  </code></pre>