This command line does what I need, but it is a little tricky...
ffmpeg -i left.jpg -i right.jpg -filter_complex "[0]scale=iw:ih*2[grande],[grande][0]overlay=x=0:y=0[base],[base][1]overlay=x=0:y=h" -y top-bottom.jpg
- -i left.jpg Left image
- -i right.jpg Right image
- -filter_complex
- "[0]scale=iw:ih*2[grande],
enlarge vertically image 1 to double its height, and create stream "grande"
(i.e. just create a base image twice high the input image)
- [grande][0]overlay=x=0:y=0[base],
Overlay image 1 to stream "grande", i.e. put left image in upper part of main image;
the results goes into "base" stream
- [base][1]overlay=x=0:y=h"
Overlay image 2 to bottom part of "base" stream, which already contains upper (left) image
Does it exist a more straightforward method? I see they exists "in_stereo" and "out_stereo" options, with "2d" and "tb" (Top-Bottom) options, but I don't understand if they are what I need, and I can't find any documentation.
Sample images:
1:
2: