summaryrefslogtreecommitdiffstats
path: root/gst
diff options
context:
space:
mode:
authorFlavio Oliveira <flavio.oliveira@indt.org.br>2005-10-25 21:09:36 +0000
committerFlavio Oliveira <flavio.oliveira@indt.org.br>2005-10-25 21:09:36 +0000
commit0f4689cdf437526642de47d24ee7e380e42dfa42 (patch)
tree2af6c0b403d4b32d3350a18106384906b13fa2d2 /gst
parentc12772c616d48bd98a5e49507cdd10d894720dfb (diff)
Just removed a couple of lines of weird code used during development/test time.
Original commit message from CVS: Just removed a couple of lines of weird code used during development/test time.
Diffstat (limited to 'gst')
-rw-r--r--gst/rtp/gstrtpg711dec.c12
-rw-r--r--gst/rtp/gstrtpg711depay.c12
2 files changed, 4 insertions, 20 deletions
diff --git a/gst/rtp/gstrtpg711dec.c b/gst/rtp/gstrtpg711dec.c
index 6456f72c..d1feeba4 100644
--- a/gst/rtp/gstrtpg711dec.c
+++ b/gst/rtp/gstrtpg711dec.c
@@ -204,22 +204,14 @@ gst_rtpg711dec_chain (GstPad * pad, GstBuffer * buf)
{
gint payload_len;
guint8 *payload;
- guint32 timestamp;
- static guint32 firstTS = -1;
payload_len = gst_rtpbuffer_get_payload_len (buf);
payload = gst_rtpbuffer_get_payload (buf);
- timestamp = gst_rtpbuffer_get_timestamp (buf);
-
- if (firstTS == -1) {
- firstTS = gst_rtpbuffer_get_timestamp (buf);
- }
- timestamp = gst_rtpbuffer_get_timestamp (buf) - firstTS;
-
outbuf = gst_buffer_new_and_alloc (payload_len);
- GST_BUFFER_TIMESTAMP (outbuf) = timestamp * GST_SECOND / 8000;
+ GST_BUFFER_TIMESTAMP (outbuf) =
+ gst_rtpbuffer_get_timestamp (buf) * GST_SECOND / 8000;
memcpy (GST_BUFFER_DATA (outbuf), payload, payload_len);
diff --git a/gst/rtp/gstrtpg711depay.c b/gst/rtp/gstrtpg711depay.c
index 6456f72c..d1feeba4 100644
--- a/gst/rtp/gstrtpg711depay.c
+++ b/gst/rtp/gstrtpg711depay.c
@@ -204,22 +204,14 @@ gst_rtpg711dec_chain (GstPad * pad, GstBuffer * buf)
{
gint payload_len;
guint8 *payload;
- guint32 timestamp;
- static guint32 firstTS = -1;
payload_len = gst_rtpbuffer_get_payload_len (buf);
payload = gst_rtpbuffer_get_payload (buf);
- timestamp = gst_rtpbuffer_get_timestamp (buf);
-
- if (firstTS == -1) {
- firstTS = gst_rtpbuffer_get_timestamp (buf);
- }
- timestamp = gst_rtpbuffer_get_timestamp (buf) - firstTS;
-
outbuf = gst_buffer_new_and_alloc (payload_len);
- GST_BUFFER_TIMESTAMP (outbuf) = timestamp * GST_SECOND / 8000;
+ GST_BUFFER_TIMESTAMP (outbuf) =
+ gst_rtpbuffer_get_timestamp (buf) * GST_SECOND / 8000;
memcpy (GST_BUFFER_DATA (outbuf), payload, payload_len);