[FFmpeg-cvslog] examples/encode_video: set the framerate

Anton Khirnov git at videolan.org
Wed Mar 29 15:17:03 EEST 2017


ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Thu Oct 20 11:03:20 2016 +0200| [d0a603a534a0ee4b255e5e72742428a7f7f42b83] | committer: Anton Khirnov

examples/encode_video: set the framerate

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d0a603a534a0ee4b255e5e72742428a7f7f42b83
---

 doc/examples/encode_video.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/doc/examples/encode_video.c b/doc/examples/encode_video.c
index c5f3853f..b955cce 100644
--- a/doc/examples/encode_video.c
+++ b/doc/examples/encode_video.c
@@ -69,7 +69,9 @@ int main(int argc, char **argv)
     c->width = 352;
     c->height = 288;
     /* frames per second */
-    c->time_base= (AVRational){1,25};
+    c->time_base = (AVRational){1, 25};
+    c->framerate = (AVRational){25, 1};
+
     c->gop_size = 10; /* emit one intra frame every ten frames */
     c->max_b_frames=1;
     c->pix_fmt = AV_PIX_FMT_YUV420P;



More information about the ffmpeg-cvslog mailing list