[FFmpeg-user] Scene detection -- numerical output?
lou at lrcd.com
Thu Nov 8 06:12:47 CET 2012
On Wed, 07 Nov 2012 20:04:59 -0800
David Liontooth <lionteeth at cogweb.net> wrote:
> The scene detection feature is a great addition:
> ffmpeg -i video.avi -vf select='gt(scene\,0.4)',scale=160:120,tile -frames:v 1 preview.png
> Set a threshold value between 0 and 1 for detecting a new scene.
> Increase the value to lower the number of detected scenes; sane values
> are typically between 0.3 and 0.5.
> Is it possible to get a numerical output (say, frame numbers) instead of
> the montage?
Do you mean you want an individual image for each output frame? Try this:
ffmpeg -i video.avi -vf select='gt(scene\,0.4)',scale=160:-1 preview-%04d.png
I also changed height to "-1" to automatically select the correct height
to preserve aspect. If you specifically need 120 you can add the pad or
crop filters to deal with that.
But of course maybe I did not understand your quesiton completely.
More information about the ffmpeg-user