0

The hstack feature works great, but it pads the videos. That is, it puts black space between them. I use a command like this:

ffmpeg -i 1.mp4 -i 2.mp4  -filter_complex "hstack" out.mp4

How do I remove the black space separating the component videos?

Perhaps related, how do I control the size of the output video? If I could change the width of the output video, I imagine that would make the padding go away. But I couldn't find a way to combine the scale= parameter with hstack.

  • 2
    The stack filters don't insert any padding. Your videos probably have empty space in them. You'll need the crop filter. Show the full console output of your command. – Gyan May 10 '17 at 4:56
  • Yes, you're right. I missed that. Dumb of me. If you put your comment as an answer, I'll accept it. Thanks. – Bob Woodley May 10 '17 at 16:46
3

The stack filters don't insert any padding. Your videos probably have empty space in them. You'll need the crop filter to remove the dead space.

The stack filters require the video edge along the join axis to have the same dimensions i.e. height for hstack and width for vstack. So, don't crop those aspects.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.