Hi Víctor Paesa wrote:
Hi,
On Dec 31, 2007 9:04 AM, Vitor Sessak <vitor1001@gmail.com> wrote:
Víctor Paesa wrote:
Hi,
The filter fps seems ignored in the ffmpeg command line.
[...]
The input and output AVI have the same 25 fps. I'm not really sure if the filter is supposed to change this. The filter infrastructure is designed to get pictures+timestamps as input and give pictures+timestamps as output. I'd say setting the output framerate is beyond filtering. For example,
ffmpeg -i input.avi -vfilters fps=1 -r 25 -y output.avi
should give a 25 fps output but with a different frame every 1 second. But indeed I get a crash with your command line and vf_fps.c do not seems to handle a rate greater than the input rate. I'll have a look into it...
I feel the libavfilter framework should support frame rate change as that is listed as part of the wishes/ideas for libavfilter in: http://wiki.multimedia.cx/index.php?title=FFmpeg_Summer_Of_Code_2007
Actually the filter framework does support frame rate change. If you do ffmpeg -i input.avi -vfilters fps=1 output.avi where input.avi has a rate of 25 fps, you'll have Input -> 25 fps Filtered input -> 1 fps Output -> 25 fps The only problem is that the output rate (set in ffmpeg.c) is equal by default to the unfiltered input rate. The filter does its job, but I agree it would be more reasonable to set the default output rate to the filtered input rate. That would unfortunately have a small problem: imagine for example overlaying a 20 fps and a 30 fps movie together. The filter output will not have a fixed frame rate, so creating and setting a frame_rate field in the AVFilterLink structure will not make a lot of sense. A second problem would be to allow broken filters to set frame_rate to a value not coherent with the interval between timestamps. Bobby, Michael, what is your opinion? -Vitor