omxaudioenc: Correctly scale nTickCount by OMX_TICKS_PER_SECOND

This commit is contained in:
Sebastian Dröge 2014-05-12 08:56:15 +02:00
parent 14af0f266e
commit 527af797d2

View file

@ -1007,6 +1007,9 @@ gst_omx_audio_enc_handle_frame (GstAudioEncoder * encoder, GstBuffer * inbuf)
if (duration != GST_CLOCK_TIME_NONE) {
buf->omx_buf->nTickCount =
gst_util_uint64_scale (buf->omx_buf->nFilledLen, duration, size);
buf->omx_buf->nTickCount =
gst_util_uint64_scale (buf->omx_buf->nTickCount,
OMX_TICKS_PER_SECOND, GST_SECOND);
self->last_upstream_ts += duration;
}