<p>since there is no loop option on the mapped stream; therefore you need 2 steps</p>
<ol>
<li>ffmpeg -y -stream_loop 2 -i <a href="https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4" rel="nofollow noreferrer">https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4</a> output.wav</li>
<li>ffmpeg -y -i output.wav -i <a href="https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4" rel="nofollow noreferrer">https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4</a> -filter:v &quot;setpts=1.3*PTS&quot; -shortest output.mp4</li>
</ol>
<p>Note: stream_loop number is the ceiling of factor</p>

CC BY-SA 4.0
2020-08-22T08:39:47.103Z
2020-08-22T08:39:47.103Z
xer-rex
<p>I am trying to use ffmpeg to slow down a video speed by 25% (75% speed) without changing the audio speed.</p>
<pre><code>ffmpeg -i input_video.mkv -filter:v &quot;setpts=1.3*PTS&quot; &quot;SlowVideo25.mp4&quot;
</code></pre>
<p>On doing so, the audio finishes first and the video continues to play for some more seconds. I want to use ffmpeg to loop/repeat the audio track in this case. So when the audio finishes, it plays the audio from the beginning for the remainder of the video.</p>
<p>Is this do-able using ffmpeg?</p>

<ffmpeg><encoding><mp4><h.264>
ffmpeg - Slow down video and loop/repeat audio
user1534235
# ffmpeg - Slow down video and loop/repeat audio

(Asked by: username_0 on 2020-08-20)

I am trying to use ffmpeg to slow down a video speed by 25% (75% speed) without changing the audio speed.
ffmpeg -i input_video.mkv -filter:v "setpts=1.3*PTS" "SlowVideo25.mp4"

On doing so, the audio finishes first and the video continues to play for some more seconds. I want to use ffmpeg to loop/repeat the audio track in this case. So when the audio finishes, it plays the audio from the beginning for the remainder of the video.
Is this do-able using ffmpeg?

**Tags:** ffmpeg, encoding, mp4, h.264


---

## 1 answers

### Answer by username_1 on 2020-08-22. Score: 0

since there is no loop option on the mapped stream; therefore you need 2 steps

1. ffmpeg -y -stream\_loop 2 -i <https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4> output.wav
2. ffmpeg -y -i output.wav -i <https://www.learningcontainer.com/wp-content/uploads/2020/05/sample-mp4-file.mp4> -filter:v "setpts=1.3\*PTS" -shortest output.mp4

Note: stream\_loop number is the ceiling of factor


---

