libeplayer3: use av_rescale for pts calulations

This commit is contained in:
martii
2014-04-18 11:16:44 +02:00
parent 9d6397ac35
commit ae1bcb466b
6 changed files with 9 additions and 10 deletions

View File

@@ -326,7 +326,6 @@ bool WriterPCM::Write(int fd, AVFormatContext *avfc, AVStream *stream, AVPacket
fprintf(stderr, "av_samples_alloc: %d\n", -e);
continue;
}
// FIXME. PTS calculation is probably broken.
int64_t next_in_pts = av_rescale(av_frame_get_best_effort_timestamp(decoded_frame),
stream->time_base.num * (int64_t)out_sample_rate * c->sample_rate,
stream->time_base.den);