<pre><code>ffmpeg -i input.mkv -filter_complex '[0:v]split[l0][r0];[l0]crop=1001:1000:0:0[l1];[r0]crop=999:1000:2001:0[r1];[l1][r1]hstack[out]' -map '[out]' ouput.mkv
</code></pre>

CC BY-SA 4.0
2021-11-25T21:29:24.417Z
It would be better if you could explain a little bit what this command does. This will help future readers and in particular those who don't have much experience with ffmpeg. .
slhck
CC BY-SA 4.0
2021-12-19T11:23:54.553Z
As I understand, every filter takes a number of streams and produces a number of streams. E.g. split takes source video stream 0 [0:v] and clones it to streams [l0] and [r0]. Then crop takes [l0] crops it and produces [l1] ... finally hstack takes [l1] and [r1] and place them side-by-side then produce stream [out]. Then -map maps stream [out] to an output stream.
Chameleon
CC BY-SA 4.0
2021-11-24T13:32:03.900Z
2021-11-24T13:32:03.900Z
stribika
<p>I have a video 3000x1000.</p>
<p>I want the left part of video 1001x1000 and the right part of video 999x1000 to create a video 2000x1000. Center of original frame just dropped.</p>
<p>Is this possible with ffmpeg in one pass? And how?</p>

<ffmpeg>
Crop outer parts of frame and rejoin
Chameleon
# Crop outer parts of frame and rejoin

(Asked by: username_0 on 2021-11-23)

I have a video 3000x1000.

I want the left part of video 1001x1000 and the right part of video 999x1000 to create a video 2000x1000. Center of original frame just dropped.

Is this possible with ffmpeg in one pass? And how?

**Tags:** ffmpeg


---

## 1 answers

### Answer by username_1 on 2021-11-24. Score: 1 | Accepted answer

ffmpeg -i input.mkv -filter_complex '[0:v]split[l0][r0];[l0]crop=1001:1000:0:0[l1];[r0]crop=999:1000:2001:0[r1];[l1][r1]hstack[out]' -map '[out]' ouput.mkv

> **Comments:**
> **username_2**: It would be better if you could explain a little bit what this command does. This will help future readers and in particular those who don't have much experience with ffmpeg. .  
> **username_0**: As I understand, every filter takes a number of streams and produces a number of streams. E.g. split takes source video stream 0 [0:v] and clones it to streams [l0] and [r0]. Then crop takes [l0] crops it and produces [l1] ... finally hstack takes [l1] and [r1] and place them side-by-side then produce stream [out]. Then -map maps stream [out] to an output stream.  

---

