comparison oggvorbis.c @ 2858:99a5981878a2 libavcodec

fixme note
author michael
date Sun, 04 Sep 2005 09:04:52 +0000
parents 303b270eee3d
children 6f8bcb169256
comparison
equal deleted inserted replaced
2857:303b270eee3d 2858:99a5981878a2
144 ogg_packet *op2= (ogg_packet*)context->buffer; 144 ogg_packet *op2= (ogg_packet*)context->buffer;
145 op2->packet = context->buffer + sizeof(ogg_packet); 145 op2->packet = context->buffer + sizeof(ogg_packet);
146 146
147 l= op2->bytes; 147 l= op2->bytes;
148 avccontext->coded_frame->pts= av_rescale_q(op2->granulepos, (AVRational){1, avccontext->sample_rate}, avccontext->time_base); 148 avccontext->coded_frame->pts= av_rescale_q(op2->granulepos, (AVRational){1, avccontext->sample_rate}, avccontext->time_base);
149 //FIXME we should reorder the user supplied pts and not assume that they are spaced by 1/sample_rate
149 150
150 memcpy(packets, op2->packet, l); 151 memcpy(packets, op2->packet, l);
151 context->buffer_index -= l + sizeof(ogg_packet); 152 context->buffer_index -= l + sizeof(ogg_packet);
152 memcpy(context->buffer, context->buffer + l + sizeof(ogg_packet), context->buffer_index); 153 memcpy(context->buffer, context->buffer + l + sizeof(ogg_packet), context->buffer_index);
153 // av_log(avccontext, AV_LOG_DEBUG, "E%d\n", l); 154 // av_log(avccontext, AV_LOG_DEBUG, "E%d\n", l);