[FFmpeg-user] independent codec settings

Alexander Solonsky alexander.solonsky at castlabs.com
Mon Apr 26 19:50:09 EEST 2021


Dear peers,

I use this command to create 2 streams out of 1 with different gop sizes:

ffmpeg -i $1 -map 0:v:0 -c:v:0 libx264 -x264-params 
"keyint=24:keyint_min=24:bframes=1" -map 0:v:0 -c:v:1 libx264 
-x264-params "keyint=72:keyint_min=72:bframes=3" $2 -y

but the output video streams have only the latest gop structure. Nicolas 
George from the ffmpeg-devel mail list told me that I need to use a 
stream specifier to achieve the desired result. Can you please help me 
to add the stream specifiers to the script above and achieve different 
gop sizes for different streams?

Thanks,
Alexander
///////////


More information about the ffmpeg-user mailing list