[Ffmpeg-devel] [PATCH] fix ffplay can't play yuv420 file
Michael Niedermayer
michaelni
Fri Feb 9 14:30:46 CET 2007
Hi
On Fri, Feb 09, 2007 at 09:08:29PM +0800, Limin Wang wrote:
> Hi,
>
> The patch try to fix that ffplay can't play yuv420 file. In addition,
> one extra option is added to control frame rate. Please review it.
> The limitation is yuv420 is supported only, maybe we can add format
> option like mplayer so that we can support other yuv format.
>
>
> Thanks,
> Limin
> Index: ffplay.c
> ===================================================================
> --- ffplay.c (revision 7888)
> +++ ffplay.c (working copy)
> @@ -186,6 +186,8 @@
> static int fs_screen_height;
> static int screen_width = 0;
> static int screen_height = 0;
> +static int frame_rate = 25;
> +static int frame_rate_base = 1;
AVRational
[...]
>
> + printf( "frame_rate: %d \n", frame_rate );
not ok
> err = av_open_input_file(&ic, is->filename, is->iformat, 0, ap);
> if (err < 0) {
> print_error(is->filename, err);
> @@ -2358,6 +2365,15 @@
> }
> }
>
> +void opt_framerate(const char *arg)
> +{
> + frame_rate = atoi(arg);
> + if(frame_rate<=0){
> + fprintf(stderr, "invalid frame_rate\n");
> + exit(1);
> + }
> +}
incorrect, should use parse_frame_rate()
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
It is dangerous to be right in matters on which the established authorities
are wrong. -- Voltaire
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070209/365da94e/attachment.pgp>
More information about the ffmpeg-devel
mailing list