comparison apiexample.c @ 1126:77ccf7fe3bd0 libavcodec

per context frame_rate_base, this should finally fix frame_rate related av sync issues
author michaelni
date Wed, 12 Mar 2003 15:16:19 +0000
parents e4762efc3617
children b47a402bbe7f
comparison
equal deleted inserted replaced
1125:0980ae063f4e 1126:77ccf7fe3bd0
190 c->bit_rate = 400000; 190 c->bit_rate = 400000;
191 /* resolution must be a multiple of two */ 191 /* resolution must be a multiple of two */
192 c->width = 352; 192 c->width = 352;
193 c->height = 288; 193 c->height = 288;
194 /* frames per second */ 194 /* frames per second */
195 c->frame_rate = 25 * FRAME_RATE_BASE; 195 c->frame_rate = 25;
196 c->frame_rate_base= 1;
196 c->gop_size = 10; /* emit one intra frame every ten frames */ 197 c->gop_size = 10; /* emit one intra frame every ten frames */
197 198
198 /* open it */ 199 /* open it */
199 if (avcodec_open(c, codec) < 0) { 200 if (avcodec_open(c, codec) < 0) {
200 fprintf(stderr, "could not open codec\n"); 201 fprintf(stderr, "could not open codec\n");