diff options
author | Wim Taymans <wim.taymans@collabora.co.uk> | 2010-01-20 16:28:31 +0100 |
---|---|---|
committer | Wim Taymans <wim.taymans@collabora.co.uk> | 2010-01-20 16:29:57 +0100 |
commit | 1f6b06ce6674a3a91db7d6b443e2223f93ef3872 (patch) | |
tree | 876c92804407a312e1b5cd4fb9e8c60f95d04b4d | |
parent | 8ca984d5e8b56dddc2241fd5ad76c271c31dfe34 (diff) |
rtph264pay: scale spspps_interval to milliseconds
The spspps_interval is kept in seconds. Convert it to milliseconds before
comparing it to another value in milliseconds.
-rw-r--r-- | gst/rtp/gstrtph264pay.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gst/rtp/gstrtph264pay.c b/gst/rtp/gstrtph264pay.c index 701d6fae8..fbb71328f 100644 --- a/gst/rtp/gstrtph264pay.c +++ b/gst/rtp/gstrtph264pay.c @@ -655,7 +655,7 @@ gst_rtp_h264_pay_payload_nal (GstBaseRTPPayload * basepayload, guint8 * data, GST_DEBUG_OBJECT (rtph264pay, "interval since last SPS/PPS %ums", diff); /* bigger than interval, queue SPS/PPS */ - if (diff >= rtph264pay->spspps_interval) { + if (diff >= (rtph264pay->spspps_interval * GST_MSECOND)) { GST_DEBUG_OBJECT (rtph264pay, "time to send SPS/PPS"); send_spspps = TRUE; } @@ -667,7 +667,8 @@ gst_rtp_h264_pay_payload_nal (GstBaseRTPPayload * basepayload, guint8 * data, } if (send_spspps) { - /* we need to send SPS/PPS now first */ + /* we need to send SPS/PPS now first. FIXME, don't use the timestamp for + * checking when we need to send SPS/PPS but convert to running_time first. */ ret = gst_rtp_h264_pay_send_sps_pps (basepayload, rtph264pay, timestamp); if (ret != GST_FLOW_OK) return ret; |