Hi I am using the following ffmpeg command to extract a thumbnail from the beginning of a clip with ffmpeg:
/usr/local/bin/ffmpeg -ss 00:00:1 -i $fileName.flv -s 150x100 -vframes 1 $fileName.jpg
Is it posible to extract a thumbnail from the middle of the clips duration with ffmpeg alone?
Each clip is of a different length.
If ffmpeg does not supply this option, I know it is possible to get the clips duration into this type of format 00:00:01.26 and then I suppose I can divide it in half, but I am not sure if this is the best approach, and I am also (embarrassed to say) not entirely sure how to divide that format in half with PHP.
Example code would be appreciated.
Thank you.
You can get the middle like this:
And then use your command with
$realMinutesand$realSeconds: