[FFmpeg-user] Removing parts of a video using the select filter

MacFH - C E Macfarlane - News news at macfh.co.uk
Sun Jan 9 12:43:17 EET 2022

On 08/01/2022 23:43, amindfv--- via ffmpeg-user wrote:
> On Sat, Jan 08, 2022 at 08:20:46PM +0000, MacFH - C E Macfarlane - News wrote:
>> To select parts of a video, I use ...
>> FFMPEG -ss <start-time> -i <input> -codec copy -to <end> <output>
>> ... however it's tedious, because with this method the video will only break
>> at certain points between compression units (can't remember the proper
>> terminology), and it can take some experimentation to find the precise
>> timing of these to get the audio right as well, and often, because of the
>> way the compression works, the first extracted frame is often an unwanted
>> last frame of a previous scene.
>> I have long lamented that FFMPEG doesn't make this both easier and to allow
>> greater resolution, if necessary recreating the start and end compression
>> units to get the exact timing wanted.
> If you get rid of the "-codec copy" you can have any precision you'd like.

But the entire video will be re-encoded, which is undesirable because, 
as the codecs use lossy compression, there will be further degradation 
of the entire video clip just gain some precision at each end.

More information about the ffmpeg-user mailing list