mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-25 01:54:17 +00:00
ext/alsa/gstalsa.c: cast to GstClockTime to get higher granularity
Original commit message from CVS: * ext/alsa/gstalsa.c: (gst_alsa_samples_to_timestamp): cast to GstClockTime to get higher granularity * ext/alsa/gstalsasink.c: (gst_alsa_sink_check_event): use gst_element_set_time_delay to get the exact time * ext/mad/gstmad.c: (gst_mad_chain): use the negotiated rate instead of the current frame's rate which might be wrong because of bit errors. This avoids emitting totally bogus timestamps and screwing sync. (fixes #143454)
This commit is contained in:
parent
3245b4ee99
commit
81bbf631d5
2 changed files with 14 additions and 3 deletions
12
ChangeLog
12
ChangeLog
|
@ -1,3 +1,15 @@
|
||||||
|
2004-06-07 Benjamin Otte <otte@gnome.org>
|
||||||
|
|
||||||
|
* ext/alsa/gstalsa.c: (gst_alsa_samples_to_timestamp):
|
||||||
|
cast to GstClockTime to get higher granularity
|
||||||
|
* ext/alsa/gstalsasink.c: (gst_alsa_sink_check_event):
|
||||||
|
use gst_element_set_time_delay to get the exact time
|
||||||
|
* ext/mad/gstmad.c: (gst_mad_chain):
|
||||||
|
use the negotiated rate instead of the current frame's rate which
|
||||||
|
might be wrong because of bit errors. This avoids emitting totally
|
||||||
|
bogus timestamps and screwing sync.
|
||||||
|
(fixes #143454)
|
||||||
|
|
||||||
2004-06-07 Tim-Philipp Müller <t.i.m@zen.co.uk>
|
2004-06-07 Tim-Philipp Müller <t.i.m@zen.co.uk>
|
||||||
|
|
||||||
reviewed by Benjamin Otte <otte@gnome.org>
|
reviewed by Benjamin Otte <otte@gnome.org>
|
||||||
|
|
|
@ -1376,9 +1376,8 @@ gst_mad_chain (GstPad * pad, GstData * _data)
|
||||||
&mad->total_samples);
|
&mad->total_samples);
|
||||||
mad->last_ts = GST_CLOCK_TIME_NONE;
|
mad->last_ts = GST_CLOCK_TIME_NONE;
|
||||||
}
|
}
|
||||||
time_offset = mad->total_samples * GST_SECOND
|
time_offset = mad->total_samples * GST_SECOND / mad->rate;
|
||||||
/ mad->frame.header.samplerate;
|
time_duration = (nsamples * GST_SECOND / mad->rate);
|
||||||
time_duration = (nsamples * GST_SECOND / mad->frame.header.samplerate);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mad->index) {
|
if (mad->index) {
|
||||||
|
|
Loading…
Reference in a new issue