comparison asf-enc.c @ 462:b69898ffc92a libavformat

move time_base (pts_num/pts_den) from AVFormatContext -> AVStream
author michael
date Fri, 21 May 2004 20:43:21 +0000
parents e47d9c8e2054
children 60f897e8dd2d
comparison
equal deleted inserted replaced
461:63540e5504f7 462:b69898ffc92a
283 283
284 bit_rate = 0; 284 bit_rate = 0;
285 for(n=0;n<s->nb_streams;n++) { 285 for(n=0;n<s->nb_streams;n++) {
286 enc = &s->streams[n]->codec; 286 enc = &s->streams[n]->codec;
287 287
288 av_set_pts_info(s->streams[n], 32, 1, 1000); /* 32 bit pts in ms */
289
288 bit_rate += enc->bit_rate; 290 bit_rate += enc->bit_rate;
289 } 291 }
290 292
291 if (asf->is_streamed) { 293 if (asf->is_streamed) {
292 put_chunk(s, 0x4824, 0, 0xc00); /* start of stream (length will be patched later) */ 294 put_chunk(s, 0x4824, 0, 0xc00); /* start of stream (length will be patched later) */
466 } 468 }
467 469
468 static int asf_write_header(AVFormatContext *s) 470 static int asf_write_header(AVFormatContext *s)
469 { 471 {
470 ASFContext *asf = s->priv_data; 472 ASFContext *asf = s->priv_data;
471
472 av_set_pts_info(s, 32, 1, 1000); /* 32 bit pts in ms */
473 473
474 asf->packet_size = PACKET_SIZE; 474 asf->packet_size = PACKET_SIZE;
475 asf->nb_packets = 0; 475 asf->nb_packets = 0;
476 476
477 if (asf_write_header1(s, 0, 50) < 0) { 477 if (asf_write_header1(s, 0, 50) < 0) {