Answers.Body: <p>Not sure off the top of my head how to do it on the fly (with multiple different video codec settings for different video streams going into the same output container).</p>
  
  <p>However, with 2 input files, this should work to mux all streams from multiple input file into a single output file.  (parallel streams / multiple "programs", NOT concatenated.)</p>
  
  <pre><code>ffmpeg -i in1.mp4 -i in2.mp4 -map 0 -map 1 -codec copy -movflags +faststart out.mp4
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-05-07T16:34:55.890Z
Answers.Text: Use -map 1:v instead of -map 1 to induct only the video stream from the 2nd file.
Answers.UserDisplayName: Gyan
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-03-07T21:21:12.573Z
Answers.LastActivityDate: 2015-03-07T21:21:12.573Z
Answers.UserDisplayName: Peter Cordes
Answers.Body: <p>Answering the question as asked,</p>
  
  <pre><code>ffmpeg -i input.mp4 -map 0:v -map 0:a -map 0:v \
  -c:v:0 copy -c:v:1 libx264 -b:v:1 &lt;lower-bitrate&gt; -c:a copy -movflags +faststart out.mp4
  </code></pre>
  
  <p>The lower-bitrate version of the video is the third stream. Players typically will play the original video which is the first stream in the output.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-03-02T08:12:01.360Z
Answers.LastActivityDate: 2016-03-02T12:36:47.553Z
Answers.LastEditDate: 2016-03-02T12:36:47.553Z
Answers.UserDisplayName: Gyan
Body: <p>Sorry if my question is too noobish, this is my first question.</p>
  
  <h2>What I have is:</h2>
  
  <p>An mp4 movie with a video stream and an audio stream.</p>
  
  <h2>What I want in the output:</h2>
  
  <p>Is an mp4 file containing: the same video stream + the same audio stream + <strong>the same video stream with a lower bit-rate</strong></p>
  
  <p>Can anyone please tell me the appropriate <strong>ffmpeg command?</strong></p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-04-10T15:11:09.480Z
Comments.Text: What are you hoping to accomplish with this?  Generally you would make two separate files for this kind of thing since either the client would still have to download both or the server can simply switch between which file it is streaming.
Comments.UserDisplayName: AJ Henderson
Tags: <ffmpeg>
Title: Putting a Lower bitrate of my video stream in my current mp4 container
UserDisplayName: Behnam
ThreadText: # Putting a Lower bitrate of my video stream in my current mp4 container
  
  (Asked by: username_0 on 2014-04-10)
  
  Sorry if my question is too noobish, this is my first question.
  
  ## What I have is:
  
  An mp4 movie with a video stream and an audio stream.
  
  ## What I want in the output:
  
  Is an mp4 file containing: the same video stream + the same audio stream + **the same video stream with a lower bit-rate**
  
  Can anyone please tell me the appropriate **ffmpeg command?**
  
  **Tags:** ffmpeg
  
  > **Comments:**
  > **username_1**: What are you hoping to accomplish with this?  Generally you would make two separate files for this kind of thing since either the client would still have to download both or the server can simply switch between which file it is streaming.  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_3 on 2016-03-02. Score: 1 | Accepted answer
  
  Answering the question as asked,
  
  ```
  ffmpeg -i input.mp4 -map 0:v -map 0:a -map 0:v \
  -c:v:0 copy -c:v:1 libx264 -b:v:1 <lower-bitrate> -c:a copy -movflags +faststart out.mp4
  
  ```
  
  The lower-bitrate version of the video is the third stream. Players typically will play the original video which is the first stream in the output.
  
  
  ---
  
  ### Answer by username_2 on 2015-03-07. Score: 0
  
  Not sure off the top of my head how to do it on the fly (with multiple different video codec settings for different video streams going into the same output container).
  
  However, with 2 input files, this should work to mux all streams from multiple input file into a single output file. (parallel streams / multiple "programs", NOT concatenated.)
  
  ```
  ffmpeg -i in1.mp4 -i in2.mp4 -map 0 -map 1 -codec copy -movflags +faststart out.mp4
  
  ```
  
  > **Comments:**
  > **username_3**: Use -map 1:v instead of -map 1 to induct only the video stream from the 2nd file.  
  
  ---
  
  