[gst-devel] fix for timestamps in audiotestsrc
Jordi Burguet Castell
jordi.burguet.castell at gmail.com
Mon Nov 29 00:38:31 CET 2010
Hello,
The audiotestsrc element sets and reports the timestamps of the
buffers it creates with a small error.
Basically, by using gst_util_uint64_scale_int() in some places, the
timestamp can be off by almost a nanosecond. In our pipeline we are
sensitive to any error in the timestamp, and because of this (small)
problem we can't use audiotestsrc to test it.
Fortunately, the fix is very easy. In audiotestsrc the timestamp (in
"next_time") is computed always from next_sample, so it can be solved
by changing gst_util_uint64_scale_int() to
gst_util_uint64_scale_int_round() (note the extra "_round")
everywhere. Patch attached.
Please let me know if this is ok, or if I should report a bug in some
other way, etc.
Thanks,
Jordi
--
Jordi Burguet-Castell <jordi at gravity.phys.uwm.edu>
UWM Physics Dept. 464
1900 E. Kenwood Blvd. Milwaukee WI 53211 USA
+1 414-229-2590
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-audiotestsrc-compute-timestamps-more-accurately-by-u.patch
Type: text/x-patch
Size: 3281 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20101128/a5214015/attachment.bin>
More information about the gstreamer-devel
mailing list