[MPlayer-users] RE : Re: RE : Re: Creating animated gif thumbnails of movies

tom wang tomawng at yahoo.fr
Wed Oct 24 01:20:38 CEST 2007


Hi,


I found a way to make it work...

It seems that if I put the framestep in seconds I get
the result I want....

I was expected framestep to take the number of frames
to skip as parameters so it threw me off...

but now that I think about it it's quite logical

As you say gif89a:fps=1.0 mean that if the framerate
is x then every xth frame will be writen in the gif

so if one adds a framestep of 18 as a parameter it is
combined with  gif89a:fps=1.0 and it actually saves a
frame every 15 seconds

since the duration of my movie is 78 seconds and I
want to get five frames, 15 seconds is the correct
value.

Thanks

--- Joey Parrish <joey.parrish at gmail.com> a écrit :

> On 10/23/07, tom wang <tomawng at yahoo.fr> wrote:
> > Thanks,
> >
> > I tried to use framestep and I'm getting good
> result,
> > but there is something still baffling me:
> >
> > I have a video file that when analyzed with
> > mplayer small-DSCF1226.AVI -identify -frames 0 -vc
> > null -vo null -ao null -nosound
> > returns:
> > MPlayer dev-SVN-rUNKNOWN-4.1.2 (C) 2000-2007
> MPlayer
> > Team
> > CPU: Intel(R) Pentium(R) 4 CPU 2.80GHz (Family:
> 15,
> > Model: 2, Stepping: 7)
> > CPUflags:  MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE:
> 1
> > SSE2: 1
> > Compiled for x86 CPU with extensions: MMX MMX2 SSE
> > SSE2
> > mplayer: could not connect to socket
> > mplayer: No such file or directory
> > Failed to open LIRC support. You will not be able
> to
> > use your remote control.
> >
> > Playing small-DSCF1226.AVI.
> > AVI file format detected.
> > ID_VIDEO_ID=0
> > ID_AUDIO_ID=1
> > VIDEO:  [MJPG]  320x240  24bpp  30.000 fps  4618.1
> > kbps (563.7 kbyte/s)
> > ID_FILENAME=small-DSCF1226.AVI
> > ID_DEMUXER=avi
> > ID_VIDEO_FORMAT=MJPG
> > ID_VIDEO_BITRATE=4618088
> > ID_VIDEO_WIDTH=320
> > ID_VIDEO_HEIGHT=240
> > ID_VIDEO_FPS=30.000
> > ID_VIDEO_ASPECT=0.0000
> > ID_AUDIO_FORMAT=1
> > ID_AUDIO_BITRATE=128000
> > ID_AUDIO_RATE=0
> > ID_AUDIO_NCH=0
> > ID_LENGTH=78.00
> >
> >
> > So according to ID_LENGTH and ID_VIDEO_FPS, the
> video
> > has 30 * 78 = 2380 frames
> >
> > So to get a five frames evenly spaced gif
> animation
> > from the video, I should do (if I understood
> > correctly)
> >
> > mplayer small-DSCF1226.AVI -nosound -vo
> > gif89a:output=test.gif:fps=1.0 -vf framestep=595
> >
> > with 595 = 2380/4
> >
> > but if I do that the gif file returned is
> corrupted
> > and does not work...
> >
> > I tried experimenting and this
> >
> > mplayer small-DSCF1226.AVI -nosound -vo
> > gif89a:output=test.gif:fps=1.0 -vf framestep=15
> >
> > worked and outputed a gif animation with 5 frames,
> but
> > I have no idea where the 15 comes from
> >
> > Can anybody explain me what i'm doing wrong?
> 
> The gif output module will use your fps setting to
> reduce the number
> of frames it stores.  It checks the FPS of the
> stream it's getting and
> throws away frames it does not need.
> 
> So, if your video is 30 fps and you use -vo
> gif89a:fps=1.0, then every
> 30th frame will be output into the GIF.  AFAIK,
> framestep should not
> be needed.
> 
> If your output GIF is not as long as it should be,
> then perhaps
> MPlayer is crashing or quitting the stream early. 
> Or perhaps the GIF
> output code is buggy.  But I tend to suspect the
> former, since the
> output module just encodes the frames it gets.
> 
> Perhaps you could post a sample file so that we
> could test with the
> same input as you?
> 
> --Joey
> _______________________________________________
> MPlayer-users mailing list
> MPlayer-users at mplayerhq.hu
>
http://lists.mplayerhq.hu/mailman/listinfo/mplayer-users
> 



      _____________________________________________________________________________ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail 




More information about the MPlayer-users mailing list