'FFmpeg hstack, vstack and pad hangs on last frame

I am trying to create a non-trivial layout like so:

I am using the following command:

ffmpeg -i in.mp4
-filter_complex [0:v]split=3[s0][s1][s2];
                [s0][s1]hstack=inputs=2:shortest=1[s3];
                [s2]pad=width=1920:x=(ow-iw)/2:y=(oh-ih)/2[s5];
                [s3][s5]vstack=inputs=2:shortest=1[s6]
                -map [s6] -map 0:a out.mp4

The command is running and hangs on the last frame.

  • Original video dimensions: 960x540
  • When removing the hstack filter from the command and adjusting it, using vstack and pad it runs and finishes
  • When I kill the process using Ctrl+C on Windows, I do get the desired output file


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source