summaryrefslogtreecommitdiff
path: root/ext/speexdsp/speexechoprobe.c
diff options
context:
space:
mode:
authorOlivier Crête <olivier.crete@collabora.co.uk>2008-10-03 21:17:51 (GMT)
committerOlivier Crête <olivier.crete@collabora.co.uk>2008-10-06 23:18:11 (GMT)
commit3af24bb079a190695bffdb71d76c53f7184c9a94 (patch)
treea1e1c6707978f4fa9c62d75e923f816de0dd26de /ext/speexdsp/speexechoprobe.c
parent8679c044c86c5675250a90986863b1138f1782dc (diff)
downloadgst-plugins-farsight-tester-3af24bb079a190695bffdb71d76c53f7184c9a94.tar.gz
gst-plugins-farsight-tester-3af24bb079a190695bffdb71d76c53f7184c9a94.tar.xz
Simplify cross-object interactions
Diffstat (limited to 'ext/speexdsp/speexechoprobe.c')
-rw-r--r--ext/speexdsp/speexechoprobe.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/ext/speexdsp/speexechoprobe.c b/ext/speexdsp/speexechoprobe.c
index 5c17ee7..ea8dce0 100644
--- a/ext/speexdsp/speexechoprobe.c
+++ b/ext/speexdsp/speexechoprobe.c
@@ -238,10 +238,17 @@ gst_speex_echo_probe_chain (GstPad *pad, GstBuffer *buffer)
{
GstSpeexEchoProbe *self = GST_SPEEX_ECHO_PROBE (gst_pad_get_parent (pad));
GstFlowReturn res;
+ GstBuffer *newbuf = NULL;
GST_OBJECT_LOCK (self);
gst_buffer_ref (buffer);
- g_queue_push_head (self->buffers, buffer);
+ newbuf = gst_buffer_create_sub (buffer, 0, GST_BUFFER_SIZE (buffer));
+ /* Moves the buffer timestamp to be in Running time */
+ GST_BUFFER_TIMESTAMP (newbuf) =
+ gst_segment_to_running_time (&self->segment,
+ GST_FORMAT_TIME,
+ GST_BUFFER_TIMESTAMP (newbuf));
+ g_queue_push_head (self->buffers, newbuf);
GST_OBJECT_UNLOCK (self);
res = gst_pad_push (self->srcpad, buffer);